Changeset View
Changeset View
Standalone View
Standalone View
sys/cam/mmc/mmc_xpt.c
Context not available. | |||||
PROBE_GET_CID, | PROBE_GET_CID, | ||||
PROBE_GET_CSD, | PROBE_GET_CSD, | ||||
PROBE_SEND_RELATIVE_ADDR, | PROBE_SEND_RELATIVE_ADDR, | ||||
PROBE_SELECT_CARD, | PROBE_MMC_SET_RELATIVE_ADDR, | ||||
PROBE_SELECT_CARD, | |||||
PROBE_DONE, | PROBE_DONE, | ||||
PROBE_INVALID | PROBE_INVALID | ||||
} probe_action; | } probe_action; | ||||
Context not available. | |||||
"PROBE_GET_CID", | "PROBE_GET_CID", | ||||
"PROBE_GET_CSD", | "PROBE_GET_CSD", | ||||
"PROBE_SEND_RELATIVE_ADDR", | "PROBE_SEND_RELATIVE_ADDR", | ||||
"PROBE_MMC_SET_RELATIVE_ADDR", | |||||
"PROBE_SELECT_CARD", | "PROBE_SELECT_CARD", | ||||
"PROBE_DONE", | "PROBE_DONE", | ||||
"PROBE_INVALID" | "PROBE_INVALID" | ||||
Context not available. | |||||
mmcio->cmd.flags = MMC_RSP_R2 | MMC_CMD_BCR; | mmcio->cmd.flags = MMC_RSP_R2 | MMC_CMD_BCR; | ||||
mmcio->stop.opcode = 0; | mmcio->stop.opcode = 0; | ||||
break; | break; | ||||
imp: why remove this?
| |||||
case PROBE_SEND_RELATIVE_ADDR: | case PROBE_SEND_RELATIVE_ADDR: | ||||
init_standard_ccb(start_ccb, XPT_MMC_IO); | init_standard_ccb(start_ccb, XPT_MMC_IO); | ||||
mmcio->cmd.opcode = SD_SEND_RELATIVE_ADDR; | mmcio->cmd.opcode = SD_SEND_RELATIVE_ADDR; | ||||
Context not available. | |||||
mmcio->cmd.flags = MMC_RSP_R6 | MMC_CMD_BCR; | mmcio->cmd.flags = MMC_RSP_R6 | MMC_CMD_BCR; | ||||
mmcio->stop.opcode = 0; | mmcio->stop.opcode = 0; | ||||
break; | break; | ||||
case PROBE_MMC_SET_RELATIVE_ADDR: | |||||
init_standard_ccb(start_ccb, XPT_MMC_IO); | |||||
mmcio->cmd.opcode = MMC_SET_RELATIVE_ADDR; | |||||
mmcio->cmd.arg = MMC_PROPOSED_RCA << 16; | |||||
mmcio->cmd.flags = MMC_RSP_R1 | MMC_CMD_AC; | |||||
mmcio->stop.opcode = 0; | |||||
break; | |||||
case PROBE_SELECT_CARD: | case PROBE_SELECT_CARD: | ||||
Done Inline ActionsBut insert this? imp: But insert this?
| |||||
init_standard_ccb(start_ccb, XPT_MMC_IO); | init_standard_ccb(start_ccb, XPT_MMC_IO); | ||||
mmcio->cmd.opcode = MMC_SELECT_CARD; | mmcio->cmd.opcode = MMC_SELECT_CARD; | ||||
Context not available. | |||||
mmcp->card_cid[1], | mmcp->card_cid[1], | ||||
mmcp->card_cid[2], | mmcp->card_cid[2], | ||||
mmcp->card_cid[3])); | mmcp->card_cid[3])); | ||||
PROBE_SET_ACTION(softc, PROBE_SEND_RELATIVE_ADDR); | if (mmcp->card_features & CARD_FEATURE_MMC) | ||||
PROBE_SET_ACTION(softc, PROBE_MMC_SET_RELATIVE_ADDR); | |||||
else | |||||
PROBE_SET_ACTION(softc, PROBE_SEND_RELATIVE_ADDR); | |||||
break; | break; | ||||
} | } | ||||
case PROBE_SEND_RELATIVE_ADDR: { | case PROBE_SEND_RELATIVE_ADDR: { | ||||
Context not available. | |||||
PROBE_SET_ACTION(softc, PROBE_SELECT_CARD); | PROBE_SET_ACTION(softc, PROBE_SELECT_CARD); | ||||
break; | break; | ||||
} | } | ||||
case PROBE_MMC_SET_RELATIVE_ADDR: | |||||
Done Inline ActionsDon't need these {} imp: Don't need these {} | |||||
mmcio = &done_ccb->mmcio; | |||||
err = mmcio->cmd.error; | |||||
if (err != MMC_ERR_NONE) { | |||||
CAM_DEBUG(done_ccb->ccb_h.path, CAM_DEBUG_PROBE, | |||||
("PROBE_MMC_SET_RELATIVE_ADDR: error %d\n", err)); | |||||
PROBE_SET_ACTION(softc, PROBE_INVALID); | |||||
break; | |||||
} | |||||
path->device->mmc_ident_data.card_rca = MMC_PROPOSED_RCA; | |||||
PROBE_SET_ACTION(softc, PROBE_GET_CSD); | |||||
break; | |||||
case PROBE_GET_CSD: { | case PROBE_GET_CSD: { | ||||
mmcio = &done_ccb->mmcio; | mmcio = &done_ccb->mmcio; | ||||
err = mmcio->cmd.error; | err = mmcio->cmd.error; | ||||
Context not available. |
why remove this?