Skip to contentSkip to conversation

IB/qib: Drop unnecessary continue

PATCH New Himangi Saraogi 1 participant 1 message Aug 13, 2014 InfiniBand

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 IB/qib: Drop unnecessary continue

Continue is not needed at the bottom of a loop.

The Coccinelle semantic patch implementing this change is:

@@
@@

for (...;...;...) {
...

  if (...) {
    ...

- continue;
}
}

---
 drivers/infiniband/hw/qib/qib_init.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/infiniband/hw/qib/qib_init.c +1 -3
index 8d3c78d..3bee93a4 100644
@@ -705,11 +705,9 @@ int qib_init(struct qib_devdata *dd, int reinit)
 		lastfail = qib_create_rcvhdrq(dd, rcd);
 		if (!lastfail)
 			lastfail = qib_setup_eagerbufs(rcd);
-		if (lastfail) {
+		if (lastfail)
 			qib_dev_err(dd,
 				"failed to allocate kernel ctxt's rcvhdrq and/or egr bufs\n");
-			continue;
-		}
 	}
 
 	for (pidx = 0; pidx < dd->num_pports; ++pidx) {
Signature · 6 lines
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html