summaryrefslogtreecommitdiff
path: root/board/tbs
diff options
context:
space:
mode:
authorSoeren Moch <smoch@web.de>2016-02-04 14:41:16 +0100
committerStefano Babic <sbabic@denx.de>2016-02-21 11:31:58 +0100
commita668436051e497da18ab79ad26649e26d8a08433 (patch)
treef5fee5557360724ecfe0485dc450348daf9dda70 /board/tbs
parent1a43dc11a33de29712e5c5a0877d21bd6f6550c1 (diff)
downloadu-boot-a668436051e497da18ab79ad26649e26d8a08433.tar.gz
board: tbs2910: Autoselect environment device when booting from SD
Implement board specific functions to select the environment device and partition when booting from SD/MMC. SD2: mmc 0 0 SD3: mmc 1 0 eMMC: mmc 2 1 Signed-off-by: Soeren Moch <smoch@web.de>
Diffstat (limited to 'board/tbs')
-rw-r--r--board/tbs/tbs2910/tbs2910.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/board/tbs/tbs2910/tbs2910.c b/board/tbs/tbs2910/tbs2910.c
index 0b509b6dd9..d302fc23b6 100644
--- a/board/tbs/tbs2910/tbs2910.c
+++ b/board/tbs/tbs2910/tbs2910.c
@@ -257,6 +257,17 @@ int board_mmc_init(bd_t *bis)
}
return 0;
}
+
+/* set environment device to boot device when booting from SD */
+int board_mmc_get_env_dev(int devno)
+{
+ return devno - 1;
+}
+
+int board_mmc_get_env_part(int devno)
+{
+ return (devno == 3) ? 1 : 0; /* part 0 for SD2 / SD3, part 1 for eMMC */
+}
#endif /* CONFIG_FSL_ESDHC */
#ifdef CONFIG_VIDEO_IPUV3