[SUNRPC] rpc_rdma: we need to cast u64 to unsigned long long for printing
authorStephen Rothwell <sfr@canb.auug.org.au>
Tue, 30 Oct 2007 07:44:32 +0000 (00:44 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 30 Oct 2007 07:44:32 +0000 (00:44 -0700)
as some architectures have unsigned long for u64.

net/sunrpc/xprtrdma/rpc_rdma.c: In function 'rpcrdma_create_chunks':
net/sunrpc/xprtrdma/rpc_rdma.c:222: warning: format '%llx' expects type 'long long unsigned int', but argument 4 has type 'u64'
net/sunrpc/xprtrdma/rpc_rdma.c:234: warning: format '%llx' expects type 'long long unsigned int', but argument 5 has type 'u64'
net/sunrpc/xprtrdma/rpc_rdma.c: In function 'rpcrdma_count_chunks':
net/sunrpc/xprtrdma/rpc_rdma.c:577: warning: format '%llx' expects type 'long long unsigned int', but argument 4 has type 'u64

Noticed on PowerPC pseries_defconfig build.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sunrpc/xprtrdma/rpc_rdma.c

index f877b88091ce99423d86bea79bdca2af7d6c750c..9e11ce7159583e092627e863d44a9907f862c061 100644 (file)
@@ -221,8 +221,8 @@ rpcrdma_create_chunks(struct rpc_rqst *rqst, struct xdr_buf *target,
                                        seg->mr_base);
                        dprintk("RPC:       %s: read chunk "
                                "elem %d@0x%llx:0x%x pos %d (%s)\n", __func__,
-                               seg->mr_len, seg->mr_base, seg->mr_rkey, pos,
-                               n < nsegs ? "more" : "last");
+                               seg->mr_len, (unsigned long long)seg->mr_base,
+                               seg->mr_rkey, pos, n < nsegs ? "more" : "last");
                        cur_rchunk++;
                        r_xprt->rx_stats.read_chunk_count++;
                } else {                /* write/reply */
@@ -234,8 +234,8 @@ rpcrdma_create_chunks(struct rpc_rqst *rqst, struct xdr_buf *target,
                        dprintk("RPC:       %s: %s chunk "
                                "elem %d@0x%llx:0x%x (%s)\n", __func__,
                                (type == rpcrdma_replych) ? "reply" : "write",
-                               seg->mr_len, seg->mr_base, seg->mr_rkey,
-                               n < nsegs ? "more" : "last");
+                               seg->mr_len, (unsigned long long)seg->mr_base,
+                               seg->mr_rkey, n < nsegs ? "more" : "last");
                        cur_wchunk++;
                        if (type == rpcrdma_replych)
                                r_xprt->rx_stats.reply_chunk_count++;
@@ -577,7 +577,7 @@ rpcrdma_count_chunks(struct rpcrdma_rep *rep, int max, int wrchunk, __be32 **ipt
                        dprintk("RPC:       %s: chunk %d@0x%llx:0x%x\n",
                                __func__,
                                ntohl(seg->rs_length),
-                               off,
+                               (unsigned long long)off,
                                ntohl(seg->rs_handle));
                }
                total_len += ntohl(seg->rs_length);