2008-01-25 17:02:06

by Myklebust, Trond

[permalink] [raw]
Subject: [PATCH 033/112] SUNRPC: Check a return result

From: Chuck Lever <[email protected]>

Minor: Replace an empty if statement with a debugging dprintk.

Signed-off-by: Chuck Lever <[email protected]>
Cc: Thomas Talpey <[email protected]>
Signed-off-by: Trond Myklebust <[email protected]>
---

net/sunrpc/xprtrdma/verbs.c | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/net/sunrpc/xprtrdma/verbs.c b/net/sunrpc/xprtrdma/verbs.c
index 44b0fb9..ffbf22a 100644
--- a/net/sunrpc/xprtrdma/verbs.c
+++ b/net/sunrpc/xprtrdma/verbs.c
@@ -522,7 +522,7 @@ rpcrdma_ep_create(struct rpcrdma_ep *ep, struct rpcrdma_ia *ia,
struct rpcrdma_create_data_internal *cdata)
{
struct ib_device_attr devattr;
- int rc;
+ int rc, err;

rc = ib_query_device(ia->ri_id->device, &devattr);
if (rc) {
@@ -648,8 +648,10 @@ rpcrdma_ep_create(struct rpcrdma_ep *ep, struct rpcrdma_ia *ia,
return 0;

out2:
- if (ib_destroy_cq(ep->rep_cq))
- ;
+ err = ib_destroy_cq(ep->rep_cq);
+ if (err)
+ dprintk("RPC: %s: ib_destroy_cq returned %i\n",
+ __func__, err);
out1:
return rc;
}