Hello,
You have already find most information, just missing to set in OTP5-6 the definition of new pins to be used during boot.
In order to use eMMC on SDMMC1 and using (for example) SDMMC1_CK = PC12, SDMMC1_D0 = PC8, SDMMC1_CMD = PD2 pins (only 3 pins used during BootROM first stage of boot), you need to program the following:
- OTP3 = 0x00080002 disable SD boot, select eMMC_if_id = SDMMC1
- OTP5 = 0x38C43CC1
- SDMMC1_CK = PC12 (bits[15:0]: port0=3=GPIOC, pin0=12, afmux0=12, mode0=0=AF;no pull;medium-speed)
- SDMMC1_D0 = PC8 (bits[31:16]: port1=3=GPIOC, pin1=8, afmux1=12, mode1=4=AF;pull-up;medium-speed)
- OTP6 = 0x000042C4
- SDMMC1_CMD = PD2 (bits[15:0]: port2=4=GPIOD, pin2=2, afmux2=12, mode2=4=AF;pull-up;medium-speed)
You should also update devicetree and rebuild all subsequent level of boot to use SDMMC1 interface and pins (including all eMMC data lines pins , as later stages use 8-bit data mode).
Currently only Toshiba eMMC references presents on STM32MP157x_EV1 boards (THGBMNG5D1LBAIL or THGBMDG5D1LBAIL) are validated with STM32MP1 series.
Some links to complete this post:
wiki/STM32MP15_ROM_code_overview#Boot_from_e-E2-80-A2MMC-E2-84-A2
wiki/How_to_cross-compile_with_the_Developer_Package