diff --git a/hdr/BCM2835 b/hdr/BCM2835 index 8fb0570dabd5ee14f8dd4825d501a2c2a78ffff8..ab98c2fa25ddd9ad15dd973fcdc51fb21d452105 100644 --- a/hdr/BCM2835 +++ b/hdr/BCM2835 @@ -391,6 +391,7 @@ GPAFEDE1 * &8c ; GPIO Async falling edge detect enable 1 GPPUPDEN * &94 ; GPIO PullUp PullDown Enable GPPUDCK0 * &98 ; GPIO PullUp PullDown Clock 0 GPPUDCK1 * &9c ; GPIO PullUp PullDown Clock 1 +GPPinMuxSD * &d0 ; Auxio peripherals ; MiniUart uses TXD1 and RXD1 diff --git a/s/SDIO b/s/SDIO index 1f48ef17d461983b01208db80d47e9141946c0fd..76cf533dd92e145bcc7358e184d36c1a187f99b6 100644 --- a/s/SDIO +++ b/s/SDIO @@ -319,6 +319,17 @@ SDHCI HALDeviceField GetWriteProtect ; Init the SDHCI HAL device SDIO_InitDevices ROUT Push "lr" + + CPUDetect a1 + BLS %FT00 + ; Pi 4 setup - select legacy emmc controller for now + LDR a1, PeriBase + MOV a2, #3 + ADD a1, a1, #GPIO_Base + DoMemBarrier lr + STR a2, [a1, #GPPinMuxSD] + DoMemBarrier lr +00 BL MeasureSpeed ADR a1, SDHCIDevice