Skip to content

Commit 15fd6ee

Browse files
P33Mpelwell
authored andcommitted
mmc: set MMC_QUIRK_KNOWN_WORKING_SD_CQ on Raspberry Pi class A2 cards
These cards have a known-good CQ implementation and are based on a Longsys product. Add the MANFID for Longsys SD, and the particular CID details for the Pi card. Signed-off-by: Jonathan Bell <[email protected]>
1 parent cae52db commit 15fd6ee

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

drivers/mmc/core/card.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@ struct mmc_fixup {
9393
#define CID_MANFID_KINGSTON 0x70
9494
#define CID_MANFID_HYNIX 0x90
9595
#define CID_MANFID_KINGSTON_SD 0x9F
96+
#define CID_MANFID_LONGSYS_SD 0xAD
9697
#define CID_MANFID_NUMONYX 0xFE
9798

9899
#define END_FIXUP { NULL }

drivers/mmc/core/quirks.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,12 @@ static const struct mmc_fixup __maybe_unused mmc_sd_fixups[] = {
6666
0, -1ull, SDIO_ANY_ID, SDIO_ANY_ID, add_quirk_sd,
6767
MMC_QUIRK_BROKEN_SD_CACHE, EXT_CSD_REV_ANY),
6868

69+
/* SD A2 allow-list - only trust CQ on these cards */
70+
/* Raspberry Pi A2 cards */
71+
_FIXUP_EXT(CID_NAME_ANY, CID_MANFID_LONGSYS_SD, 0x4c53, CID_YEAR_ANY, CID_MONTH_ANY,
72+
cid_rev(1, 0, 0, 0), -1ull, SDIO_ANY_ID, SDIO_ANY_ID, add_quirk_sd,
73+
MMC_QUIRK_WORKING_SD_CQ, EXT_CSD_REV_ANY),
74+
6975
END_FIXUP
7076
};
7177

0 commit comments

Comments
 (0)