Commit 8aac3b72 authored by Ben Avison's avatar Ben Avison Committed by ROOL
Browse files

Enable SD controller

* Efforts to get the faster EMMC2 controller working are ongoing. In the
  meantime, this enables the backward-compatible EMMC1 controller.
* The method required to control the activity LED appears to have changed,
  yet again. I haven't worked out how yet, so this is currently
parent 068d02ad
......@@ -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
......@@ -319,6 +319,17 @@ SDHCI HALDeviceField GetWriteProtect
; Init the SDHCI HAL device
SDIO_InitDevices ROUT
Push "lr"
CPUDetect a1
; 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
BL MeasureSpeed
ADR a1, SDHCIDevice
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment