From cdf3eec481bc889feed3356a7d3a2f0be62c18a7 Mon Sep 17 00:00:00 2001 From: Eric Lee Date: Mon, 2 Apr 2018 19:20:40 +0800 Subject: [PATCH] Fixed SPI Boot will stop problem. --- arch/arm/dts/am437x-smarct437x.dts | 20 ++++++++++---------- arch/arm/mach-omap2/am33xx/board.c | 11 ++++------- board/embedian/smarct437x/board.c | 4 ++-- configs/smarct437x_evm_spi_uart0_defconfig | 1 - configs/smarct437x_evm_spi_uart1_defconfig | 1 - configs/smarct437x_evm_spi_uart2_defconfig | 1 - configs/smarct437x_evm_spi_uart3_defconfig | 1 - include/configs/smarct437x_evm.h | 2 +- 8 files changed, 17 insertions(+), 24 deletions(-) diff --git a/arch/arm/dts/am437x-smarct437x.dts b/arch/arm/dts/am437x-smarct437x.dts index 860abf5..aa9f074 100644 --- a/arch/arm/dts/am437x-smarct437x.dts +++ b/arch/arm/dts/am437x-smarct437x.dts @@ -646,7 +646,7 @@ }; &i2c2 { - status = "okay"; + status = "disabled"; pinctrl-names = "default"; pinctrl-0 = <&i2c2_pins>; clock-frequency = <100000>; @@ -662,8 +662,8 @@ &epwmss0 { status = "okay"; - ehrpwm0: ehrpwm@48300200 { - status = "okay"; + ehrpwm@48300200 { + status = "disabled"; pinctrl-names = "default"; pinctrl-0 = <&ehrpwm0b_pins>; }; @@ -715,7 +715,7 @@ /*If carrier board eMMC (or 2nd SD slot) is present and used, un-comment out the following nodes. SD card will be emulated /dev/mmcblk2 instead of /dev/mmcblk1*/ &mmc3 { - status = "okay"; + status = "disabled"; dmas = <&edma 30 &edma 31>; dma-names = "tx", "rx"; @@ -810,7 +810,7 @@ &spi2 { ti,spi-num-cs = <2>; - status = "okay"; + status = "disabled"; pinctrl-names = "default"; pinctrl-0 = <&spi2_pins>; dmas = <&edma 18 @@ -838,7 +838,7 @@ &spi4 { ti,spi-num-cs = <2>; - status = "okay"; + status = "disabled"; pinctrl-names = "default"; pinctrl-0 = <&spi4_pins>; dmas = <&edma 26 @@ -899,13 +899,13 @@ &dcan0 { pinctrl-names = "default"; pinctrl-0 = <&dcan0_default>; - status = "okay"; + status = "disabled"; }; &dcan1 { pinctrl-names = "default"; pinctrl-0 = <&dcan1_default>; - status = "okay"; + status = "disabled"; }; &mac { @@ -945,7 +945,7 @@ pinctrl-0 = <&mcasp1_pins>; pinctrl-1 = <&mcasp1_sleep_pins>; - status = "okay"; + status = "disabled"; op-mode = <0>; /* MCASP_IIS_MODE */ tdm-slots = <2>; @@ -959,7 +959,7 @@ }; &dss { - status = "okay"; + status = "disabled"; pinctrl-names = "default"; pinctrl-0 = <&dss_pins>; diff --git a/arch/arm/mach-omap2/am33xx/board.c b/arch/arm/mach-omap2/am33xx/board.c index d0208ad..22ff5e2 100644 --- a/arch/arm/mach-omap2/am33xx/board.c +++ b/arch/arm/mach-omap2/am33xx/board.c @@ -114,13 +114,10 @@ const struct gpio_bank *const omap_gpio_bank = gpio_bank_am33xx; #if defined(CONFIG_OMAP_HSMMC) int cpu_mmc_init(bd_t *bis) { - int ret; - - ret = omap_mmc_init(0, 0, 0, -1, -1); - if (ret) - return ret; - - return omap_mmc_init(2, 0, 0, -1, -1); + omap_mmc_init(0, 0, 0, -1, -1); + omap_mmc_init(1, 0, 0, -1, -1); + omap_mmc_init(2, 0, 0, -1, -1); + return 0; } #endif diff --git a/board/embedian/smarct437x/board.c b/board/embedian/smarct437x/board.c index 01cfb18..8eb1194 100644 --- a/board/embedian/smarct437x/board.c +++ b/board/embedian/smarct437x/board.c @@ -1133,9 +1133,9 @@ int board_fit_config_name_match(const char *name) return 0; else if (board_is_idk() && !strcmp(name, "am437x-idk-evm")) return 0; - else if (board_is_smarc_t437x_800() && !strcmp(name, "am437x-smarct437x")) + else if (board_is_smarc_t437x_800() && !strcmp(name, "SMCT4X80")) return 0; - else if (board_is_smarc_t437x_01g() && !strcmp(name, "am437x-smarct437xSMCT4X1G")) + else if (board_is_smarc_t437x_01g() && !strcmp(name, "SMCT4X1G")) return 0; else return -1; diff --git a/configs/smarct437x_evm_spi_uart0_defconfig b/configs/smarct437x_evm_spi_uart0_defconfig index 96772f9..348ebb5 100644 --- a/configs/smarct437x_evm_spi_uart0_defconfig +++ b/configs/smarct437x_evm_spi_uart0_defconfig @@ -11,7 +11,6 @@ CONFIG_SPL_SEPARATE_BSS=y CONFIG_SPL_RTC_ONLY_SUPPORT=y CONFIG_DEFAULT_DEVICE_TREE="am437x-smarct437x" CONFIG_SYS_EXTRA_OPTIONS="CONS_INDEX=1,SPI_BOOT" -#CONFIG_QSPI_BOOT=y CONFIG_SYS_CONSOLE_INFO_QUIET=y CONFIG_VERSION_VARIABLE=y CONFIG_HUSH_PARSER=y diff --git a/configs/smarct437x_evm_spi_uart1_defconfig b/configs/smarct437x_evm_spi_uart1_defconfig index c5d87c0..4c2cfb6 100644 --- a/configs/smarct437x_evm_spi_uart1_defconfig +++ b/configs/smarct437x_evm_spi_uart1_defconfig @@ -11,7 +11,6 @@ CONFIG_SPL_SEPARATE_BSS=y CONFIG_SPL_RTC_ONLY_SUPPORT=y CONFIG_DEFAULT_DEVICE_TREE="am437x-smarct437x" CONFIG_SYS_EXTRA_OPTIONS="CONS_INDEX=4,SPI_BOOT" -#CONFIG_QSPI_BOOT=y CONFIG_SYS_CONSOLE_INFO_QUIET=y CONFIG_VERSION_VARIABLE=y CONFIG_HUSH_PARSER=y diff --git a/configs/smarct437x_evm_spi_uart2_defconfig b/configs/smarct437x_evm_spi_uart2_defconfig index 0502c73..b4ef277 100644 --- a/configs/smarct437x_evm_spi_uart2_defconfig +++ b/configs/smarct437x_evm_spi_uart2_defconfig @@ -11,7 +11,6 @@ CONFIG_SPL_SEPARATE_BSS=y CONFIG_SPL_RTC_ONLY_SUPPORT=y CONFIG_DEFAULT_DEVICE_TREE="am437x-smarct437x" CONFIG_SYS_EXTRA_OPTIONS="CONS_INDEX=3,SPI_BOOT" -#CONFIG_QSPI_BOOT=y CONFIG_SYS_CONSOLE_INFO_QUIET=y CONFIG_VERSION_VARIABLE=y CONFIG_HUSH_PARSER=y diff --git a/configs/smarct437x_evm_spi_uart3_defconfig b/configs/smarct437x_evm_spi_uart3_defconfig index 3006a55..c2a2295 100644 --- a/configs/smarct437x_evm_spi_uart3_defconfig +++ b/configs/smarct437x_evm_spi_uart3_defconfig @@ -11,7 +11,6 @@ CONFIG_SPL_SEPARATE_BSS=y CONFIG_SPL_RTC_ONLY_SUPPORT=y CONFIG_DEFAULT_DEVICE_TREE="am437x-smarct437x" CONFIG_SYS_EXTRA_OPTIONS="CONS_INDEX=5,SPI_BOOT" -#CONFIG_QSPI_BOOT=y CONFIG_SYS_CONSOLE_INFO_QUIET=y CONFIG_VERSION_VARIABLE=y CONFIG_HUSH_PARSER=y diff --git a/include/configs/smarct437x_evm.h b/include/configs/smarct437x_evm.h index e5395ef..d2f9a72 100644 --- a/include/configs/smarct437x_evm.h +++ b/include/configs/smarct437x_evm.h @@ -50,7 +50,7 @@ * Since SPL did pll and ddr initialization for us, * we don't need to do it twice. */ -#if !defined(CONFIG_SPL_BUILD) && !defined(CONFIG_SPI_BOOT) +#if !defined(CONFIG_SPL_BUILD) /*&& !defined(CONFIG_SPI_BOOT)*/ #define CONFIG_SKIP_LOWLEVEL_INIT #endif -- 1.9.1