Commit 6b02e974 authored by Mathias Nyman's avatar Mathias Nyman Committed by Greg Kroah-Hartman

xhci: remove unnecessary check for pending timer

Checking if the command timeout timer is pending when queueing the
first command to the command ring is not really useful, remove it.
Suggested-by: default avatarLu Baolu <baolu.lu@linux.intel.com>
Signed-off-by: default avatarMathias Nyman <mathias.nyman@linux.intel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent f9926596
...@@ -3815,8 +3815,7 @@ static int queue_command(struct xhci_hcd *xhci, struct xhci_command *cmd, ...@@ -3815,8 +3815,7 @@ static int queue_command(struct xhci_hcd *xhci, struct xhci_command *cmd,
list_add_tail(&cmd->cmd_list, &xhci->cmd_list); list_add_tail(&cmd->cmd_list, &xhci->cmd_list);
/* if there are no other commands queued we start the timeout timer */ /* if there are no other commands queued we start the timeout timer */
if (xhci->cmd_list.next == &cmd->cmd_list && if (xhci->cmd_list.next == &cmd->cmd_list) {
!delayed_work_pending(&xhci->cmd_timer)) {
xhci->current_cmd = cmd; xhci->current_cmd = cmd;
xhci_mod_cmd_timer(xhci, XHCI_CMD_DEFAULT_TIMEOUT); xhci_mod_cmd_timer(xhci, XHCI_CMD_DEFAULT_TIMEOUT);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment