[PATCH] mci: Fix erase_grp_size extraction for SD with csd_struct v0
Sascha Hauer
s.hauer at pengutronix.de
Tue Oct 1 03:33:43 PDT 2024
On Tue, 01 Oct 2024 11:57:41 +0200, Sascha Hauer wrote:
> In mci_extract_erase_group_size() we test for (IS_SD() && csd_struct_v1)
> which means that for non csd_struct_v1 SD cards we fall into the MMC
> path and evaluate ext_csd. This doesn't exist for SD cards and the
> code crashes with a NULL pointer deref.
>
> Fix this by always falling into the SD case for SD cards. Add the
> missing erase_grp_size extraction for csd_struct v0 cards. The code
> for that is taken from the corresponding Linux code.
>
> [...]
Applied, thanks!
[1/1] mci: Fix erase_grp_size extraction for SD with csd_struct v0
https://git.pengutronix.de/cgit/barebox/commit/?id=98bd0bee79f4 (link may not be stable)
Best regards,
--
Sascha Hauer <s.hauer at pengutronix.de>
More information about the barebox
mailing list