]> git.baikalelectronics.ru Git - kernel.git/commit
i40iw: Receive netdev events post INET_NOTIFIER state
authorShiraz Saleem <shiraz.saleem@intel.com>
Fri, 17 Mar 2017 23:30:07 +0000 (18:30 -0500)
committerDoug Ledford <dledford@redhat.com>
Fri, 24 Mar 2017 20:23:29 +0000 (16:23 -0400)
commit96e6dc36afd0d36f4023bcfb0deef6433658db7b
tree1e3c93fad72ab0f836a785903c7733680fe9c8f8
parent972bf42af2e0540797254b6ac6cecd7495749afd
i40iw: Receive netdev events post INET_NOTIFIER state

Netdev notification events are de-registered only when all
client iwdev instances are removed. If a single client is closed
and re-opened, netdev events could arrive even before the Control
Queue-Pair (CQP) is created, causing a NULL pointer dereference crash
in i40iw_get_cqp_request. Fix this by allowing netdev event
notification only after we have reached the INET_NOTIFIER state with
respect to device initialization.

Reported-by: Stefan Assmann <sassmann@redhat.com>
Signed-off-by: Shiraz Saleem <shiraz.saleem@intel.com>
Reviewed-by: Yuval Shaia <yuval.shaia@oracle.com>
Signed-off-by: Doug Ledford <dledford@redhat.com>
drivers/infiniband/hw/i40iw/i40iw_utils.c