]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
SVCRDMA: Fix erroneous BUG_ON in send_write
authorTom Tucker <tom@opengridcomputing.com>
Tue, 11 Mar 2008 18:31:40 +0000 (14:31 -0400)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 12 Mar 2008 19:37:34 +0000 (12:37 -0700)
The assertion that checks for sge context overflow is
incorrectly hard-coded to 32. This causes a kernel bug
check when using big-data mounts. Changed the BUG_ON to
use the computed value RPCSVC_MAXPAGES.

Signed-off-by: Tom Tucker <tom@opengridcomputing.com>
Signed-off-by: J. Bruce Fields <bfields@citi.umich.edu>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
net/sunrpc/xprtrdma/svc_rdma_sendto.c

index 0598b229c11d326720a6c56b9bce66cfaa66e6b7..981f190c1b398278b496300a69b733fe2469c922 100644 (file)
@@ -156,7 +156,7 @@ static int send_write(struct svcxprt_rdma *xprt, struct svc_rqst *rqstp,
        struct svc_rdma_op_ctxt *ctxt;
        int ret = 0;
 
-       BUG_ON(sge_count >= 32);
+       BUG_ON(sge_count > RPCSVC_MAXPAGES);
        dprintk("svcrdma: RDMA_WRITE rmr=%x, to=%llx, xdr_off=%d, "
                "write_len=%d, xdr_sge=%p, sge_count=%d\n",
                rmr, (unsigned long long)to, xdr_off,