summaryrefslogtreecommitdiffstats
path: root/drivers/usb
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2013-10-07 11:58:34 -0700
committerSarah Sharp <sarah.a.sharp@linux.intel.com>2013-10-16 15:48:31 -0700
commit4e341818ee9ee8d435977131cc7ce9e89c053fa6 (patch)
tree9009af35f1fc28135ac548fab3e29f89e5632fc3 /drivers/usb
parentfd1ac4cf524018198373c5eb90ca0e7968c5bbb8 (diff)
usb: xhci: kill a conditional when toggling cycle
Perform an unconditional toggle of the cycle bit with 'xor'. Signed-off-by: Dan Williams <dan.j.williams@intel.com> Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/host/xhci-ring.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c
index e57163f952e..1e2f3f49584 100644
--- a/drivers/usb/host/xhci-ring.c
+++ b/drivers/usb/host/xhci-ring.c
@@ -178,7 +178,7 @@ static void inc_deq(struct xhci_hcd *xhci, struct xhci_ring *ring)
if (ring->type == TYPE_EVENT &&
last_trb_on_last_seg(xhci, ring,
ring->deq_seg, ring->dequeue)) {
- ring->cycle_state = (ring->cycle_state ? 0 : 1);
+ ring->cycle_state ^= 1;
}
ring->deq_seg = ring->deq_seg->next;
ring->dequeue = ring->deq_seg->trbs;