]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
mx23_olinuxino: convert MMC to driver model
authorTrevor Woerner <twoerner@gmail.com>
Mon, 22 Mar 2021 15:31:29 +0000 (11:31 -0400)
committerStefano Babic <sbabic@denx.de>
Thu, 8 Apr 2021 21:59:50 +0000 (23:59 +0200)
Convert the Olimex Olinuxino board's support for MMC to driver model following
Fabio Estevam's excellent example from:

commit: 23013aa9619881290dbeb6217f1fab863869050e:
mx23evk: Convert to driver model

Signed-off-by: Trevor Woerner <twoerner@gmail.com>
arch/arm/dts/imx23-olinuxino-u-boot.dtsi [new file with mode: 0644]
board/olimex/mx23_olinuxino/mx23_olinuxino.c
configs/mx23_olinuxino_defconfig

diff --git a/arch/arm/dts/imx23-olinuxino-u-boot.dtsi b/arch/arm/dts/imx23-olinuxino-u-boot.dtsi
new file mode 100644 (file)
index 0000000..dee8433
--- /dev/null
@@ -0,0 +1,5 @@
+// SPDX-License-Identifier: GPL-2.0+
+
+&ssp0 {
+       non-removable;
+};
index d1e189cbb6ebe36bbc0cf582a58005b71e1ea702..bdd5fcd76ae8d77aedf469430d7f733e874a89f1 100644 (file)
@@ -57,18 +57,6 @@ int dram_init(void)
        return mxs_dram_init();
 }
 
-#ifdef CONFIG_CMD_MMC
-static int mx23_olx_mmc_cd(int id)
-{
-       return 1;       /* Card always present */
-}
-
-int board_mmc_init(struct bd_info *bis)
-{
-       return mxsmmc_initialize(bis, 0, NULL, mx23_olx_mmc_cd);
-}
-#endif
-
 int board_init(void)
 {
        /* Adress of boot parameters */
index 2bf6818ee36523bdce92b653624f5bbdf784f927..680611cd01390ff6c6723a894892a9bbe19575bf 100644 (file)
@@ -12,6 +12,7 @@ CONFIG_TARGET_MX23_OLINUXINO=y
 CONFIG_SPL_SERIAL_SUPPORT=y
 CONFIG_SPL=y
 CONFIG_DEFAULT_DEVICE_TREE="imx23-olinuxino"
+# CONFIG_SYS_MALLOC_F is not set
 CONFIG_BOOTDELAY=3
 # CONFIG_DISPLAY_BOARDINFO is not set
 CONFIG_ARCH_MISC_INIT=y
@@ -30,6 +31,7 @@ CONFIG_ENV_OVERWRITE=y
 CONFIG_ENV_IS_IN_MMC=y
 CONFIG_SYS_RELOC_GD_ENV_ADDR=y
 CONFIG_VERSION_VARIABLE=y
+CONFIG_DM=y
 CONFIG_MXS_GPIO=y
 CONFIG_LED_STATUS=y
 CONFIG_LED_STATUS_GPIO=y
@@ -39,10 +41,10 @@ CONFIG_LED_STATUS_STATE=2
 CONFIG_LED_STATUS_BOOT_ENABLE=y
 CONFIG_LED_STATUS_BOOT=0
 CONFIG_LED_STATUS_CMD=y
+CONFIG_DM_MMC=y
 CONFIG_MMC_MXS=y
 CONFIG_CONS_INDEX=0
 CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
-CONFIG_USB_STORAGE=y
 CONFIG_USB_HOST_ETHER=y
 CONFIG_USB_ETHER_SMSC95XX=y