aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/hfi1/ruc.c
diff options
context:
space:
mode:
authorAlex Estrin <alex.estrin@intel.com>2018-02-01 10:43:58 -0800
committerJason Gunthorpe <jgg@mellanox.com>2018-02-01 15:24:32 -0700
commit2b1e7fe16124e86ee9242aeeee859c79a843e3a2 (patch)
tree233de075dfe127bfcdc5faec36f5aa69d221381d /drivers/infiniband/hw/hfi1/ruc.c
parentIB/hfi1: Fix for early release of sdma context (diff)
downloadlinux-dev-2b1e7fe16124e86ee9242aeeee859c79a843e3a2.tar.xz
linux-dev-2b1e7fe16124e86ee9242aeeee859c79a843e3a2.zip
IB/hfi1: Fix for potential refcount leak in hfi1_open_file()
The dd refcount is speculatively incremented prior to allocating the fd memory with kzalloc(). If that kzalloc() failed the dd refcount leaks. Increment refcount on kzalloc success. Fixes: e11ffbd57520 ("IB/hfi1: Do not free hfi1 cdev parent structure early") Reviewed-by: Michael J Ruhl <michael.j.ruhl@intel.com> Signed-off-by: Alex Estrin <alex.estrin@intel.com> Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to 'drivers/infiniband/hw/hfi1/ruc.c')
0 files changed, 0 insertions, 0 deletions