Lines Matching refs:command

57 static void SDHC_StartTransfer(SDHC_Type *base, sdhc_command_t *command, sdhc_data_t *data, sdhc_dm…
65 static status_t SDHC_ReceiveCommandResponse(SDHC_Type *base, sdhc_command_t *command);
115 static status_t SDHC_SendCommandBlocking(SDHC_Type *base, sdhc_command_t *command);
233 static void SDHC_StartTransfer(SDHC_Type *base, sdhc_command_t *command, sdhc_data_t *data, sdhc_dm… in SDHC_StartTransfer() argument
239 if (command->responseType == kCARD_ResponseTypeR1) /* Response 1 */ in SDHC_StartTransfer()
244 else if (command->responseType == kCARD_ResponseTypeR1b) /* Response 1 with busy */ in SDHC_StartTransfer()
249 else if (command->responseType == kCARD_ResponseTypeR2) /* Response 2 */ in SDHC_StartTransfer()
253 else if (command->responseType == kCARD_ResponseTypeR3) /* Response 3 */ in SDHC_StartTransfer()
257 else if (command->responseType == kCARD_ResponseTypeR4) /* Response 4 */ in SDHC_StartTransfer()
261 else if (command->responseType == kCARD_ResponseTypeR5) /* Response 5 */ in SDHC_StartTransfer()
266 else if (command->responseType == kCARD_ResponseTypeR5b) /* Response 5 with busy */ in SDHC_StartTransfer()
271 else if (command->responseType == kCARD_ResponseTypeR6) /* Response 6 */ in SDHC_StartTransfer()
276 else if (command->responseType == kCARD_ResponseTypeR7) /* Response 7 */ in SDHC_StartTransfer()
286 if (command->type == kCARD_CommandTypeAbort) in SDHC_StartTransfer()
323 sdhcTransferConfig.commandArgument = command->argument; in SDHC_StartTransfer()
324 sdhcTransferConfig.commandIndex = command->index; in SDHC_StartTransfer()
329 static status_t SDHC_ReceiveCommandResponse(SDHC_Type *base, sdhc_command_t *command) in SDHC_ReceiveCommandResponse() argument
331 assert(command != NULL); in SDHC_ReceiveCommandResponse()
337 if (command->responseType != kCARD_ResponseTypeNone) in SDHC_ReceiveCommandResponse()
339 command->response[0U] = response0; in SDHC_ReceiveCommandResponse()
340 if (command->responseType == kCARD_ResponseTypeR2) in SDHC_ReceiveCommandResponse()
344 command->response[0U] <<= 8U; in SDHC_ReceiveCommandResponse()
345 command->response[1U] = (response1 << 8U) | ((response0 & 0xFF000000U) >> 24U); in SDHC_ReceiveCommandResponse()
346 command->response[2U] = (response2 << 8U) | ((response1 & 0xFF000000U) >> 24U); in SDHC_ReceiveCommandResponse()
347 command->response[3U] = (base->CMDRSP[3] << 8U) | ((response2 & 0xFF000000U) >> 24U); in SDHC_ReceiveCommandResponse()
352 if ((command->responseErrorFlags != 0U) && in SDHC_ReceiveCommandResponse()
353 …((command->responseType == kCARD_ResponseTypeR1) || (command->responseType == kCARD_ResponseTypeR1… in SDHC_ReceiveCommandResponse()
354 …(command->responseType == kCARD_ResponseTypeR6) || (command->responseType == kCARD_ResponseTypeR5)… in SDHC_ReceiveCommandResponse()
356 if (((command->responseErrorFlags) & (command->response[0U])) != 0U) in SDHC_ReceiveCommandResponse()
568 static status_t SDHC_SendCommandBlocking(SDHC_Type *base, sdhc_command_t *command) in SDHC_SendCommandBlocking() argument
585 error = SDHC_ReceiveCommandResponse(base, command); in SDHC_SendCommandBlocking()
701 assert(handle->command != NULL); in SDHC_TransferHandleCommand()
711 if (kStatus_Success != SDHC_ReceiveCommandResponse(base, handle->command)) in SDHC_TransferHandleCommand()
728 handle->command = NULL; in SDHC_TransferHandleCommand()
1389 sdhc_command_t *command = transfer->command; in SDHC_TransferBlocking() local
1393 if ((command == NULL) || ((data != NULL) && (data->blockCount > SDHC_MAX_BLOCK_COUNT))) in SDHC_TransferBlocking()
1431 SDHC_StartTransfer(base, command, data, (sdhc_dma_mode_t)dmaMode); in SDHC_TransferBlocking()
1433 error = SDHC_SendCommandBlocking(base, command); in SDHC_TransferBlocking()
1517 sdhc_command_t *command = transfer->command; in SDHC_TransferNonBlocking() local
1521 if ((command == NULL) || ((data != NULL) && (data->blockCount > SDHC_MAX_BLOCK_COUNT))) in SDHC_TransferNonBlocking()
1548 handle->command = command; in SDHC_TransferNonBlocking()
1568 SDHC_StartTransfer(base, command, data, dmaMode); in SDHC_TransferNonBlocking()