]> git.baikalelectronics.ru Git - kernel.git/commit
IB/hfi1: Correct oversized ring allocation
authorMike Marciniszyn <mike.marciniszyn@cornelisnetworks.com>
Mon, 29 Mar 2021 13:54:09 +0000 (09:54 -0400)
committerJason Gunthorpe <jgg@nvidia.com>
Wed, 7 Apr 2021 23:19:00 +0000 (20:19 -0300)
commitfba238e7fc121a840ed3d2fec9ba3f134ab3cd1c
treecc6d3cb8a1661825ce00dc12b5fcfe47f6a95bec
parentacd86d3921321260d4d1b65a8296ee7c96f0bf73
IB/hfi1: Correct oversized ring allocation

The completion ring for tx is using the wrong size to size the ring,
oversizing the ring by two orders of magniture.

Correct the allocation size and use kcalloc_node() to allocate the ring.
Fix mistaken GFP defines in similar allocations.

Link: https://lore.kernel.org/r/1617026056-50483-4-git-send-email-dennis.dalessandro@cornelisnetworks.com
Reviewed-by: Kaike Wan <kaike.wan@intel.com>
Signed-off-by: Mike Marciniszyn <mike.marciniszyn@cornelisnetworks.com>
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@cornelisnetworks.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
drivers/infiniband/hw/hfi1/ipoib.h
drivers/infiniband/hw/hfi1/ipoib_tx.c