Implement set block count (CMD23) for x1000 target.

I have a 1TB SD card that gets filesystem corruption when writing large
amounts of data when using Rockbox in USB storage mode. The card doesn't show
this behaviour when using the original firmware or when using an external SD
card writer.

This is on an Aigo Eros Q device. Same brand 512GB card does not exhibit this
behaviour.

Whether this specific SD card explicitly requires CMD23 or if there's a
problem with the controller's timing of auto-CMD12 in combination with this
card is currently unknown, but implementing it does solve the problem.

This change request implements CMD23 by first probing if SBC is supported by
the SD card and then using it instead of AUTO_CMD12.

Change-Id: Ib2dc8e179b0fab98ca59c348061cb7d5850884dd
This commit is contained in:
Ingmar Steen 2026-02-08 00:05:31 +01:00 committed by Solomon Peachy
parent ea5b0fb33a
commit 7327d9fb6c
3 changed files with 46 additions and 7 deletions

View file

@ -754,6 +754,7 @@ Melissa Autumn
Sho Tanimoto
Nyx Guan
Arin Kim
Ingmar Steen
The libmad team
The wavpack team