]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
net: ena: fix NULL dereference due to untimely napi initialization
authorArthur Kiyanovski <akiyano@amazon.com>
Tue, 9 Oct 2018 08:21:29 +0000 (11:21 +0300)
committerThadeu Lima de Souza Cascardo <cascardo@canonical.com>
Fri, 9 Nov 2018 19:00:42 +0000 (17:00 -0200)
commitc81bd2ba971abc8664ccfe8fa66eab6dd89d8d9c
tree6aaa99cb82641915acb23371dac2bad0bbdaeea7
parent3d3e0658e34cbab78c8c3d9935eba317de9635c2
net: ena: fix NULL dereference due to untimely napi initialization

BugLink: http://bugs.launchpad.net/bugs/1798182
napi poll functions should be initialized before running request_irq(),
to handle a rare condition where there is a pending interrupt, causing
the ISR to fire immediately while the poll function wasn't set yet,
causing a NULL dereference.

Fixes: 1738cd3ed342 ("net: ena: Add a driver for Amazon Elastic Network Adapters (ENA)")
Signed-off-by: Arthur Kiyanovski <akiyano@amazon.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
(cherry picked from commit 78a55d05def95144ca5fa9a64c49b2a0636a9866)
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Acked-by: Khalid Elmously <khalid.elmously@canonical.com>
Acked-by: Seth Forshee <seth.forshee@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
drivers/net/ethernet/amazon/ena/ena_netdev.c