linux_dsm_epyc7002/drivers/net/ethernet
Zhu Yanjun 442866ff97 bnx2x: fix slowpath null crash
When "NETDEV WATCHDOG: em4 (bnx2x): transmit queue 2 timed out" occurs,
BNX2X_SP_RTNL_TX_TIMEOUT is set. In the function bnx2x_sp_rtnl_task,
bnx2x_nic_unload and bnx2x_nic_load are executed to shutdown and open
NIC. In the function bnx2x_nic_load, bnx2x_alloc_mem allocates dma
failure. The message "bnx2x: [bnx2x_alloc_mem:8399(em4)]Can't
allocate memory" pops out. The variable slowpath is set to NULL.
When shutdown the NIC, the function bnx2x_nic_unload is called. In
the function bnx2x_nic_unload, the following functions are executed.
bnx2x_chip_cleanup
    bnx2x_set_storm_rx_mode
        bnx2x_set_q_rx_mode
            bnx2x_set_q_rx_mode
                bnx2x_config_rx_mode
                    bnx2x_set_rx_mode_e2
In the function bnx2x_set_rx_mode_e2, the variable slowpath is operated.
Then the crash occurs.
To fix this crash, the variable slowpath is checked. And in the function
bnx2x_sp_rtnl_task, after dma memory allocation fails, another shutdown
and open NIC is executed.

CC: Joe Jin <joe.jin@oracle.com>
CC: Junxiao Bi <junxiao.bi@oracle.com>
Signed-off-by: Zhu Yanjun <yanjun.zhu@oracle.com>
Acked-by: Ariel Elior <aelior@cavium.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-11-14 16:16:32 +09:00
..
3com net: 3com: 3c574_cs: mark expected switch fall-through 2017-11-11 19:10:06 +09:00
8390 net: 8390: pcnet_cs: mark expected switch fall-through 2017-11-11 19:10:06 +09:00
adaptec
adi
aeroflex
agere
alacritech
allwinner
alteon
altera
amazon
amd
apm
apple
aquantia
arc
atheros
aurora
broadcom bnx2x: fix slowpath null crash 2017-11-14 16:16:32 +09:00
brocade
cadence net: macb: add of_node_put to error paths 2017-11-11 15:27:44 +09:00
calxeda
cavium net: thunderx: fix double free error 2017-11-11 19:22:34 +09:00
chelsio cxgb4: collect SGE queue context dump 2017-11-14 16:14:07 +09:00
cirrus
cisco
davicom
dec
dlink
emulex
ezchip
faraday
freescale fsl/fman_port: mark expected switch fall-throughs 2017-11-11 18:50:33 +09:00
fujitsu
hisilicon net: hns3: cleanup mac auto-negotiation state query in hclge_update_speed_duplex 2017-11-11 15:17:56 +09:00
hp
huawei
i825xx
ibm ibmvnic: Add vnic client data to login buffer 2017-11-11 18:46:11 +09:00
intel
marvell net: mvpp2: fix GOP statistics loop start and stop conditions 2017-11-11 15:21:30 +09:00
mediatek
mellanox net/mlx4: Use Kconfig flag to remove support of old gen2 Mellanox devices 2017-11-13 10:27:51 +09:00
micrel
microchip
moxa
myricom
natsemi
neterion
netronome nfp flower action: Modified to use VLAN helper functions 2017-11-10 15:32:20 +09:00
nuvoton
nvidia forcedeth: remove redudant assignments in xmit 2017-11-13 10:40:19 +09:00
nxp
oki-semi
packetengines
pasemi
qlogic qlge: remove duplicated assignment to mbcp 2017-11-11 19:13:39 +09:00
qualcomm
rdc
realtek net: realtek: r8169: remove redundant assignment to giga_ctrl 2017-11-13 10:02:33 +09:00
renesas
rocker
samsung
seeq
sfc net: sfc: remove redundant variable start 2017-11-11 19:14:14 +09:00
sgi
silan
sis
smsc
stmicro
sun
synopsys
tehuti
ti
tile
toshiba
tundra
via
wiznet
xilinx
xircom
xscale
dnet.c
dnet.h
ec_bhf.c
ethoc.c
fealnx.c
jme.c
jme.h
Kconfig
korina.c
lantiq_etop.c
Makefile
netx-eth.c