+ svcrdma-fix-compile-warning-on-32-bit-platforms.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     svcrdma: fix compile warning on 32 bit platforms
has been added to the -mm tree.  Its filename is
     svcrdma-fix-compile-warning-on-32-bit-platforms.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/SubmitChecklist when testing your code ***

See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find
out what to do about this

The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/

------------------------------------------------------
Subject: svcrdma: fix compile warning on 32 bit platforms
From: Tom Tucker <tom@xxxxxxxxxxxxxxxxxxxxx>

The ib_sge is used to store both dma_addr_t and virtual addresses.  This
causes a warning on 32b platforms when casting ptrs to the u64 addr field
of the ib_sge.  There is work underway to reduce the memory footprint of
the WR context in 2.6.27 the time frame that will remove the overloading
of the ib_sge.addr field.

Signed-off-by: Tom Tucker <tom@xxxxxxxxxxxxxxxxxxxxx>
Cc: "J. Bruce Fields" <bfields@xxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 net/sunrpc/xprtrdma/svc_rdma_recvfrom.c |    3 ++-
 net/sunrpc/xprtrdma/svc_rdma_sendto.c   |    4 ++--
 2 files changed, 4 insertions(+), 3 deletions(-)

diff -puN net/sunrpc/xprtrdma/svc_rdma_recvfrom.c~svcrdma-fix-compile-warning-on-32-bit-platforms net/sunrpc/xprtrdma/svc_rdma_recvfrom.c
--- a/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c~svcrdma-fix-compile-warning-on-32-bit-platforms
+++ a/net/sunrpc/xprtrdma/svc_rdma_recvfrom.c
@@ -231,7 +231,8 @@ static void rdma_set_ctxt_sge(struct svc
 		atomic_inc(&xprt->sc_dma_used);
 		ctxt->sge[i].addr = (unsigned long)
 			ib_dma_map_single(xprt->sc_cm_id->device,
-					  (void*)sge[i].addr, sge[i].length,
+					  (void*)(unsigned long)
+					  sge[i].addr, sge[i].length,
 					  DMA_FROM_DEVICE);
 		ctxt->sge[i].length = sge[i].length;
 		ctxt->sge[i].lkey = sge[i].lkey;
diff -puN net/sunrpc/xprtrdma/svc_rdma_sendto.c~svcrdma-fix-compile-warning-on-32-bit-platforms net/sunrpc/xprtrdma/svc_rdma_sendto.c
--- a/net/sunrpc/xprtrdma/svc_rdma_sendto.c~svcrdma-fix-compile-warning-on-32-bit-platforms
+++ a/net/sunrpc/xprtrdma/svc_rdma_sendto.c
@@ -177,7 +177,7 @@ static int send_write(struct svcxprt_rdm
 		atomic_inc(&xprt->sc_dma_used);
 		sge[sge_no].addr =
 			ib_dma_map_single(xprt->sc_cm_id->device,
-					  (void *)
+					  (void *)(unsigned long)
 					  xdr_sge[xdr_sge_no].addr + sge_off,
 					  sge_bytes, DMA_TO_DEVICE);
 		if (dma_mapping_error(sge[sge_no].addr))
@@ -416,7 +416,7 @@ static int send_reply(struct svcxprt_rdm
 		atomic_inc(&rdma->sc_dma_used);
 		ctxt->sge[sge_no].addr =
 			ib_dma_map_single(rdma->sc_cm_id->device,
-					  (void *)
+					  (void *)(unsigned long)
 					  ctxt->sge[sge_no].addr,
 					  sge_bytes, DMA_TO_DEVICE);
 	}
_

Patches currently in -mm which might be from tom@xxxxxxxxxxxxxxxxxxxxx are

linux-next.patch
svcrdma-fix-compile-warning-on-32-bit-platforms.patch

--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux