Changeset 3cbc138 in mainline
- Timestamp:
- 2017-10-25T13:45:53Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 47ab89e
- Parents:
- 2b35478
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/xhci/commands.c
r2b35478 r3cbc138 262 262 } 263 263 264 /* Semantics of NO_OP_CMD is that success is marked as a TRB error. */ 265 if (command->_header.cmd == XHCI_CMD_NO_OP && code == XHCI_TRBC_TRB_ERROR) 266 code = XHCI_TRBC_SUCCESS; 267 264 268 command->status = code; 265 269 command->slot_id = TRB_GET_SLOT(*trb); 266 270 267 271 usb_log_debug2("Completed command trb: %s", xhci_trb_str_type(TRB_TYPE(command->_header.trb))); 268 if (TRB_TYPE(command->_header.trb) != XHCI_TRB_TYPE_NO_OP_CMD) { 269 if (code != XHCI_TRBC_SUCCESS) { 270 report_error(code); 271 xhci_dump_trb(&command->_header.trb); 272 } 272 273 if (code != XHCI_TRBC_SUCCESS) { 274 report_error(code); 275 xhci_dump_trb(&command->_header.trb); 273 276 } 274 277 275 278 switch (TRB_TYPE(command->_header.trb)) { 276 279 case XHCI_TRB_TYPE_NO_OP_CMD: 277 assert(code == XHCI_TRBC_TRB_ERROR);278 280 break; 279 281 case XHCI_TRB_TYPE_ENABLE_SLOT_CMD: … … 585 587 } 586 588 587 return EOK;589 return cmd->status == XHCI_TRBC_SUCCESS ? EOK : EINVAL; 588 590 } 589 591
Note:
See TracChangeset
for help on using the changeset viewer.