Lines Matching refs:cmd
66 static int mvebu_mmc_send_cmd(struct mmc *mmc, struct mmc_cmd *cmd, in mvebu_mmc_send_cmd() argument
76 DRIVER_NAME, cmd->cmdidx, cmd->resp_type, cmd->cmdarg); in mvebu_mmc_send_cmd()
79 cmd->cmdidx, mvebu_mmc_read(SDIO_HW_STATE)); in mvebu_mmc_send_cmd()
111 resptype = SDIO_CMD_INDEX(cmd->cmdidx); in mvebu_mmc_send_cmd()
114 if (cmd->resp_type & MMC_RSP_BUSY) in mvebu_mmc_send_cmd()
116 else if (cmd->resp_type & MMC_RSP_136) in mvebu_mmc_send_cmd()
118 else if (cmd->resp_type & MMC_RSP_PRESENT) in mvebu_mmc_send_cmd()
123 if (cmd->resp_type & MMC_RSP_CRC) in mvebu_mmc_send_cmd()
126 if (cmd->resp_type & MMC_RSP_OPCODE) in mvebu_mmc_send_cmd()
129 if (cmd->resp_type & MMC_RSP_PRESENT) { in mvebu_mmc_send_cmd()
156 mvebu_mmc_write(SDIO_ARG_LOW, cmd->cmdarg & 0xffff); in mvebu_mmc_send_cmd()
157 mvebu_mmc_write(SDIO_ARG_HI, cmd->cmdarg >> 16); in mvebu_mmc_send_cmd()
170 DRIVER_NAME, cmd->cmdidx, in mvebu_mmc_send_cmd()
189 if (cmd->resp_type & MMC_RSP_136) { in mvebu_mmc_send_cmd()
196 cmd->response[0] = ((response[0] & 0x03ff) << 22) | in mvebu_mmc_send_cmd()
199 cmd->response[1] = ((response[2] & 0x03ff) << 22) | in mvebu_mmc_send_cmd()
202 cmd->response[2] = ((response[4] & 0x03ff) << 22) | in mvebu_mmc_send_cmd()
205 cmd->response[3] = ((response[6] & 0x03ff) << 22) | in mvebu_mmc_send_cmd()
207 } else if (cmd->resp_type & MMC_RSP_PRESENT) { in mvebu_mmc_send_cmd()
214 cmd->response[0] = ((response[2] & 0x003f) << (8 - 8)) | in mvebu_mmc_send_cmd()
217 cmd->response[1] = ((response[0] & 0xfc00) >> 10); in mvebu_mmc_send_cmd()
218 cmd->response[2] = 0; in mvebu_mmc_send_cmd()
219 cmd->response[3] = 0; in mvebu_mmc_send_cmd()
221 cmd->response[0] = 0; in mvebu_mmc_send_cmd()
222 cmd->response[1] = 0; in mvebu_mmc_send_cmd()
223 cmd->response[2] = 0; in mvebu_mmc_send_cmd()
224 cmd->response[3] = 0; in mvebu_mmc_send_cmd()
227 debug("%s: resp[0x%x] ", DRIVER_NAME, cmd->resp_type); in mvebu_mmc_send_cmd()
228 debug("[0x%x] ", cmd->response[0]); in mvebu_mmc_send_cmd()
229 debug("[0x%x] ", cmd->response[1]); in mvebu_mmc_send_cmd()
230 debug("[0x%x] ", cmd->response[2]); in mvebu_mmc_send_cmd()
231 debug("[0x%x] ", cmd->response[3]); in mvebu_mmc_send_cmd()