Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755057AbYCKSbx (ORCPT ); Tue, 11 Mar 2008 14:31:53 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752397AbYCKSbn (ORCPT ); Tue, 11 Mar 2008 14:31:43 -0400 Received: from mail.fieldses.org ([66.93.2.214]:60199 "EHLO fieldses.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751185AbYCKSbm (ORCPT ); Tue, 11 Mar 2008 14:31:42 -0400 From: "J. Bruce Fields" To: Linus Torvalds Cc: linux-nfs@vger.kernel.org, linux-kernel@vger.kernel.org, Tom Tucker , "J. Bruce Fields" Subject: [PATCH 2/2] SVCRDMA: Fix erroneous BUG_ON in send_write Date: Tue, 11 Mar 2008 14:31:40 -0400 Message-Id: <1205260300-19127-3-git-send-email-bfields@citi.umich.edu> X-Mailer: git-send-email 1.5.4.4 In-Reply-To: <1205260300-19127-2-git-send-email-bfields@citi.umich.edu> References: <1205260300-19127-1-git-send-email-bfields@citi.umich.edu> <1205260300-19127-2-git-send-email-bfields@citi.umich.edu> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1304 Lines: 34 From: Tom Tucker 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 Signed-off-by: J. Bruce Fields --- net/sunrpc/xprtrdma/svc_rdma_sendto.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/net/sunrpc/xprtrdma/svc_rdma_sendto.c b/net/sunrpc/xprtrdma/svc_rdma_sendto.c index 0598b22..981f190 100644 --- a/net/sunrpc/xprtrdma/svc_rdma_sendto.c +++ b/net/sunrpc/xprtrdma/svc_rdma_sendto.c @@ -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, -- 1.5.4.rc2.60.gb2e62 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/