mmc: adjust switching to 4-bit mode for MMC devices

CMD6 is a normal command on MMC, but an application command on SD. And
the parameters and response type are different.

Change-Id: I0583b8a98cf18dc4d77d28066673d0d07229e161
Reviewed-on: https://review.haiku-os.org/c/haiku/+/10934
Reviewed-by: Adrien Destugues <[email protected]>
This commit is contained in:
PulkoMandy
2026-05-07 07:22:21 +00:00
committed by Adrien Destugues
parent 1e9473f97e
commit 5efaab5061
3 changed files with 47 additions and 10 deletions
+2 -1
View File
@@ -46,10 +46,10 @@ enum SD_COMMANDS {
// Basic commands, class 0
GO_IDLE_STATE = 0,
MMC_SEND_OP_COND = 1,
// MMC only,reserved in SD.
ALL_SEND_CID = 2,
SD_SEND_RELATIVE_ADDR = 3,
MMC_SET_RELATIVE_ADDR = 3,
MMC_SWITCH = 6, // Same command number as SD_SET_BUS_WIDTH, but this one is not an ACMD
SELECT_DESELECT_CARD = 7,
SD_SEND_IF_COND = 8,
MMC_SEND_EXT_CSD = 8,
@@ -76,6 +76,7 @@ enum SD_COMMANDS {
};
// Application commands are sent with a prefix CMD55 (SD_APP_CMD)
enum SDHCI_APPLICATION_COMMANDS {
SD_SET_BUS_WIDTH = 6,
SD_SEND_OP_COND = 41,