RDMA/i40iw: Handle workqueue allocation failure
authorKangjie Lu <kjlu@umn.edu>
Fri, 15 Mar 2019 06:57:14 +0000 (01:57 -0500)
committerJason Gunthorpe <jgg@mellanox.com>
Wed, 27 Mar 2019 13:19:07 +0000 (10:19 -0300)
commite2a438bd7116889af36304903b92e56d0f347228
tree3812c8dde555c3fc50189e742969c40fcdf671c4
parent4ae27444100f54e6db3a046f086ba4e70e1ac22b
RDMA/i40iw: Handle workqueue allocation failure

alloc_ordered_workqueue may fail and return NULL.  The fix captures the
failure and handles it properly to avoid potential NULL pointer
dereferences.

Signed-off-by: Kangjie Lu <kjlu@umn.edu>
Reviewed-by: Shiraz, Saleem <shiraz.saleem@intel.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/hw/i40iw/i40iw.h
drivers/infiniband/hw/i40iw/i40iw_cm.c
drivers/infiniband/hw/i40iw/i40iw_main.c