]> git.baikalelectronics.ru Git - uboot.git/commit
stm32mp: use device sequence number in boot_instance variable
authorPatrick Delaunay <patrick.delaunay@foss.st.com>
Tue, 6 Jul 2021 15:19:45 +0000 (17:19 +0200)
committerPatrick Delaunay <patrick.delaunay@foss.st.com>
Fri, 16 Jul 2021 07:28:46 +0000 (09:28 +0200)
commit7093bcd791e60d1c6f349983409f93ae778db2f0
treee5f9c4f6022231ba054e009a010452a6955a8a6e
parentbb0fe122ca28752780160ef522641bdd916d50cc
stm32mp: use device sequence number in boot_instance variable

Use the device sequence number in boot_instance variable
and no more the SDMMC instance provided by ROM code/TF-A.

After this patch we don't need to define the mmc alias in
device tree, for example:
  mmc0 = &sdmmc1;
  mmc1 = &sdmmc2;
  mmc2 = &sdmmc3;
to have a correct mapping between the ROM code boot device =
"${boot_device}${boot_instance}" and the MMC device in U-Boot.

With this patch the 'mmc0' device (used in mmc commands) is
always used when only one instance sdmmc is activated in device
tree, even if it is only the sdmmc2 or sdmmc3.

Signed-off-by: Patrick Delaunay <patrick.delaunay@foss.st.com>
Reviewed-by: Patrice Chotard <patrice.chotard@foss.st.com>
arch/arm/mach-stm32mp/cpu.c
arch/arm/mach-stm32mp/include/mach/stm32.h
board/st/stm32mp1/stm32mp1.c