summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2011-04-15 13:51:15 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2011-04-15 13:53:31 -0700
commit4325217a76079bf3af605a2414bbe3444d306aed (patch)
tree760ffbdacda067cc610ce2983cdc1930074f4c4f
parent2ba8779ab23fbdca103c6112dac5d712669c72f6 (diff)
Revert "net: fix rds_iovec page count overflow"
This reverts commit bd378dd6df5ca43021a49f72441a6c14d9784bed (originally commit 1b1f693d7ad6d193862dcb1118540a030c5e761f upstream). I messed it up in backporting it to the .32-stable kernel, so revert it for now and try it again the next review cycle. Cc: Thomas Pollet <thomas.pollet@gmail.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andy Grover <andy.grover@oracle.com> Cc: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--net/rds/rdma.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/net/rds/rdma.c b/net/rds/rdma.c
index f7d8c08bd6b2..6b09b941d3a7 100644
--- a/net/rds/rdma.c
+++ b/net/rds/rdma.c
@@ -473,14 +473,6 @@ static struct rds_rdma_op *rds_rdma_prepare(struct rds_sock *rs,
max_pages = max(nr, max_pages);
nr_pages += nr;
-
- /*
- * nr_pages for one entry is limited to (UINT_MAX>>PAGE_SHIFT)+1,
- * so tot_pages cannot overflow without first going negative.
- */
- if ((int)nr_pages < 0)
- ret = -EINVAL;
- goto out;
}
pages = kcalloc(max_pages, sizeof(struct page *), GFP_KERNEL);