Page MenuHomeFreeBSD

dwmmc: Add HS200 support
Needs ReviewPublic

Authored by manu on Tue, Oct 20, 9:03 AM.
Tags
None
Referenced Files
F176700025: D60888.diff
Tue, Oct 20, 9:26 PM
F176646638: D60888.id190363.diff
Tue, Oct 20, 1:05 PM
F176646471: D60888.id190374.diff
Tue, Oct 20, 1:02 PM
F176646426: D60888.diff
Tue, Oct 20, 1:02 PM
Subscribers

Details

Reviewers
andrew
mmel
Group Reviewers
arm64
Summary

Add the tuning procedure (CMD21 with the standard JEDEC tuning block
patterns), the 1.2V/1.8V/3.3V signaling voltage switch using voltage
bands, a watchdog for stuck requests, controller recovery and DMA fixes
needed to run HS200 reliably.

For the Rockchip glue, implement the tuning hook by sweeping the sample
clock phase over 360 degrees, picking the middle of the widest good window
and restoring the previous phase on failure. The drive phase is set to
180 degrees.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 78401
Build 75284: arc lint + arc unit

Event Timeline

manu requested review of this revision.Tue, Oct 20, 9:03 AM
sys/dev/mmc/host/dwmmc.c
1028

How can we recover from this BUSDMA error? Imho, this is always a programming error rather than an operational failure, so panic is more appropriate.

1173

Does this work even if the cttrl + card are switched to a lower voltage??

1197

Please put these defines at the top

1368

It must be panic. This is not recoverable.

sys/dev/mmc/host/dwmmc.c
1028

I'll restore the panic

1173

Yes, I needed it for tuning on rock64 which happens at 1.8V, just the voltage is never touch.
Now if the question is "will it work on every condition ?" I'm pretty sure that the answer is no :)

1197

will do

1368

Mhm yes but before it was a hang as the loop never stopped, now it's better and honestly not sure if this will be recoverable or not depending on the conditions.

sys/dev/mmc/host/dwmmc.c
1368

It hangs on the next command, which makes debugging much more difficult. Previously, the endless loop was visible in GDB.