From: Ingo Molnar Date: Wed, 26 Nov 2008 00:49:37 +0000 (-0800) Subject: sunrpc: fix warning in net/sunrpc/xprtrdma/svc_rdma_transport.c X-Git-Tag: v2.6.29-rc1~581^2~476 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=ed72b9c6e0ec4e66dd16b7ca212845e1eb985d65;p=linux-2.6-omap-h63xx.git sunrpc: fix warning in net/sunrpc/xprtrdma/svc_rdma_transport.c this warning: net/sunrpc/xprtrdma/svc_rdma_transport.c: In function ‘svc_rdma_accept’: net/sunrpc/xprtrdma/svc_rdma_transport.c:830: warning: ‘dma_mr_acc’ may be used uninitialized in this function triggers because GCC does not recognize the (correct) flow connection between need_dma_mr and dma_mr_acc. Annotate it. Signed-off-by: Ingo Molnar Signed-off-by: David S. Miller --- diff --git a/net/sunrpc/xprtrdma/svc_rdma_transport.c b/net/sunrpc/xprtrdma/svc_rdma_transport.c index f8500f018f8..8872914aa4c 100644 --- a/net/sunrpc/xprtrdma/svc_rdma_transport.c +++ b/net/sunrpc/xprtrdma/svc_rdma_transport.c @@ -827,7 +827,7 @@ static struct svc_xprt *svc_rdma_accept(struct svc_xprt *xprt) struct rdma_conn_param conn_param; struct ib_qp_init_attr qp_attr; struct ib_device_attr devattr; - int dma_mr_acc; + int uninitialized_var(dma_mr_acc); int need_dma_mr; int ret; int i;