diff mbox

[PATCH/RFC] RDMA/nes: Rewrite expression to avoid undefined semantics

Message ID ada630hx0ut.fsf@roland-alpha.cisco.com (mailing list archive)
State Accepted, archived
Headers show

Commit Message

Roland Dreier July 14, 2010, 8:30 p.m. UTC
None
diff mbox

Patch

diff --git a/drivers/infiniband/hw/nes/nes_hw.c b/drivers/infiniband/hw/nes/nes_hw.c
index 57874a1..f41d890 100644
--- a/drivers/infiniband/hw/nes/nes_hw.c
+++ b/drivers/infiniband/hw/nes/nes_hw.c
@@ -1970,7 +1970,7 @@  void nes_destroy_nic_qp(struct nes_vnic *nesvnic)
 			dev_kfree_skb(
 				nesvnic->nic.tx_skb[nesvnic->nic.sq_tail]);
 
-		nesvnic->nic.sq_tail = (++nesvnic->nic.sq_tail)
+		nesvnic->nic.sq_tail = (nesvnic->nic.sq_tail + 1)
 					& (nesvnic->nic.sq_size - 1);
 	}