drivers/infiniband/sw/rdmavt/qp.c: use kmalloc_array_node()
Subsystems (2)
PATCH 24/131 drivers/infiniband/sw/rdmavt/qp.c: use kmalloc_array_node()
From: Johannes Thumshirn <[email protected]>
Subject: drivers/infiniband/sw/rdmavt/qp.c: use kmalloc_array_node()
Now that we have a NUMA-aware version of kmalloc_array() we can use it instead of kmalloc_node() without an overflow check in the size calculation.
Signed-off-by Johannes Thumshirn <[email protected]>
Reviewed-by Christoph Lameter <[email protected]>
Cc Christoph Hellwig <[email protected]>
Cc Damien Le Moal <[email protected]>
Cc David Rientjes <[email protected]>
Cc "David S. Miller" <[email protected]>
Cc Doug Ledford <[email protected]>
Cc Hal Rosenstock <[email protected]>
Cc Jens Axboe <[email protected]>
Cc Joonsoo Kim <[email protected]>
Cc Mike Marciniszyn <[email protected]>
Cc Pekka Enberg <[email protected]>
Cc Santosh Shilimkar <[email protected]>
Cc Sean Hefty <[email protected]>
Cc Vlastimil Babka <[email protected]>
Signed-off-by Andrew Morton <[email protected]>
---
drivers/infiniband/sw/rdmavt/qp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/infiniband/sw/rdmavt/qp.c renamed from drivers/infiniband/sw/rdmavt/qp.c~ib-rdmavt-use-kmalloc_array_node +1 -1
@@ -238,7 +238,7 @@ int rvt_driver_qp_init(struct rvt_dev_in rdi->qp_dev->qp_table_size = rdi->dparms.qp_table_size; rdi->qp_dev->qp_table_bits =ilog2 (rdi->dparms.qp_table_size); rdi->qp_dev->qp_table = -kmalloc_node (rdi->qp_dev->qp_table_size * +kmalloc_array_node (rdi->qp_dev->qp_table_size,sizeof (*rdi->qp_dev->qp_table),GFP_KERNEL , rdi->dparms.node);if (!rdi->qp_dev->qp_table)
_