summaryrefslogtreecommitdiff
path: root/include/configs/grapeboard.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/configs/grapeboard.h')
-rw-r--r--include/configs/grapeboard.h68
1 files changed, 50 insertions, 18 deletions
diff --git a/include/configs/grapeboard.h b/include/configs/grapeboard.h
index ebfa2dc..0d5c21e 100644
--- a/include/configs/grapeboard.h
+++ b/include/configs/grapeboard.h
@@ -22,7 +22,7 @@
#define CONFIG_DISPLAY_BOARDINFO_LATE
-/* Match the following u-boot offsets with the value in the PBI instructions */
+/* Match the following u-boot offsets with the value in the PBI instructions! */
#define CONFIG_U_BOOT_PAD_TO 0x1000
#define CONFIG_SYS_TEXT_BASE 0x40001000
@@ -70,8 +70,9 @@
#define CONFIG_FSL_QSPI
#define QSPI0_AMBA_BASE 0x40000000
#define CONFIG_SPI_FLASH_SPANSION
+/* Standard flash */
#define FSL_QSPI_FLASH_SIZE SZ_64M
-#define FSL_QSPI_FLASH_NUM 1 /* Other flash is not accessible by default */
+#define FSL_QSPI_FLASH_NUM 1
/* QSPI Environment */
#if CONFIG_RESCUE_UBOOT_CONFIG
@@ -85,6 +86,19 @@
#endif
#endif /* CONFIG_QSPI_BOOT */
+/* SPI */
+#define CONFIG_FSL_DSPI1
+#define CONFIG_DEFAULT_SPI_BUS 0
+#define CONFIG_CMD_SPI
+#define MMAP_DSPI DSPI1_BASE_ADDR
+#define CONFIG_SYS_DSPI_CTAR0 1
+#define CONFIG_SYS_DSPI_CTAR1 1
+
+#define CONFIG_SF_DEFAULT_SPEED 10000000
+#define CONFIG_SF_DEFAULT_MODE SPI_MODE_0
+#define CONFIG_SF_DEFAULT_BUS 0
+#define CONFIG_SF_DEFAULT_CS 0
+
/* I2C */
#define CONFIG_SYS_I2C
#define CONFIG_SYS_I2C_MXC
@@ -105,6 +119,9 @@
#define CONFIG_HWCONFIG
#define HWCONFIG_BUFFER_SIZE 128
+#include <config_distro_defaults.h>
+#include <config_distro_bootcmd.h>
+
/* Monitor Command Prompt */
#define CONFIG_SYS_CBSIZE 512 /* Console I/O Buffer Size */
#define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + sizeof(CONFIG_SYS_PROMPT) + 16)
@@ -122,10 +139,15 @@
#define EMAC2_PHY_ADDR 0x2
#endif
-/* USB */
+/* USB XHCI */
+/* todo: fix hx3 hub configuration errors */
#define CONFIG_HAS_FSL_XHCI_USB
+
+#ifdef CONFIG_HAS_FSL_XHCI_USB
#define CONFIG_USB_XHCI_FSL
+#define CONFIG_USB_XHCI_PCI
#define CONFIG_USB_MAX_CONTROLLER_COUNT 1
+#endif
/* MMC */
#ifdef CONFIG_MMC
@@ -150,6 +172,7 @@
#define CONFIG_PCI_SCAN_SHOW
#define CONFIG_CMD_PCI
+#if 0 /* todo */
/* Mtdparts configuration */
#define CONFIG_MTD_DEVICE
#define CONFIG_MTD_PARTITIONS
@@ -169,6 +192,7 @@
"mtdparts=spi40000000.0:" \
MTDPART_DEFAULT_PARTITIONS \
"-(rootfs)"
+#endif
/* Default environment variables */
#define COMMON_UBOOT_CONFIG \
@@ -191,8 +215,10 @@
"ethprime=pfe_eth0\0" \
"ethaddr=02:00:00:ba:be:01\0" \
"eth1addr=02:00:00:ba:be:02\0" \
- "tftp_path=\0" \
- "autoload=no\0"
+ "tftp_path=.\0" \
+ "autoload=no\0" \
+ "hwconfig=" \
+ "usb0:dr_mode=host\0"
/* Default flash specific environment variables */
#if CONFIG_RESCUE_UBOOT_CONFIG
@@ -208,30 +234,36 @@
#else /* if CONFIG_STANDARD_UBOOT_CONFIG */
#define CONFIG_EXTRA_ENV_SETTINGS \
COMMON_UBOOT_CONFIG \
- "update_pbl_uboot_qspi_nor_nw=" \
+ "tftp_update_pbl_uboot_qspi_nor=" \
"dhcp;" \
"tftp $load_addr $tftp_path/u-boot-pbl.bin;" \
"if test $? = \"0\"; then " \
- "sf probe 0:0;" \
- "sf erase 0 200000;" \
- "sf write $load_addr 0 $filesize;" \
+ "run update_pbl_uboot_qspi_nor;" \
"fi\0" \
- "update_ppa_qspi_nor_nw=" \
+ "tftp_update_ppa_qspi_nor=" \
"dhcp;" \
"tftp $load_addr $tftp_path/ppa.itb;" \
"if test $? = \"0\"; then " \
- "sf probe 0:0;" \
- "sf erase 240000 40000;" \
- "sf write $load_addr 240000 $filesize;" \
+ "run update_ppa_qspi_nor;" \
"fi\0" \
- "update_pfe_qspi_nor_nw=" \
+ "tftp_update_pfe_qspi_nor=" \
"dhcp;" \
"tftp $load_addr $tftp_path/pfe_fw_sbl.itb;" \
"if test $? = \"0\"; then " \
- "sf probe 0:0;" \
- "sf erase 280000 40000;" \
- "sf write $load_addr 280000 $filesize;" \
+ "run update_pfe_qspi_nor;" \
"fi\0" \
+ "update_pbl_uboot_qspi_nor=" \
+ "sf probe 0:0;" \
+ "sf erase 0 200000;" \
+ "sf write $load_addr 0 $filesize\0" \
+ "update_ppa_qspi_nor=" \
+ "sf probe 0:0;" \
+ "sf erase 240000 40000;" \
+ "sf write $load_addr 240000 $filesize\0" \
+ "update_pfe_qspi_nor=" \
+ "sf probe 0:0;" \
+ "sf erase 280000 40000;" \
+ "sf write $load_addr 280000 $filesize\0" \
"mmcboot=" \
"ext4load mmc 0:1 $fdt_addr_r /boot/grapeboard.dtb;" \
"ext4load mmc 0:1 $kernel_addr_r /boot/uImage;" \
@@ -239,7 +271,7 @@
"pfe stop;" \
"bootm $kernel_addr_r - $fdt_addr_r;" \
"fi\0" \
- "tftpboot=" \
+ "netboot=" \
"dhcp;" \
"tftp $fdt_addr_r $tftp_path/grapeboard.dtb;" \
"tftp $kernel_addr_r $tftp_path/uImage;" \