]> git.baikalelectronics.ru Git - kernel.git/commit
net/qlge: Avoids recursive EEH error
authorGavin Shan <gwshan@linux.vnet.ibm.com>
Mon, 23 May 2016 01:58:28 +0000 (11:58 +1000)
committerDavid S. Miller <davem@davemloft.net>
Tue, 24 May 2016 21:47:19 +0000 (14:47 -0700)
commit863bfe79a84539546e36ff6739fabcb5a39ae949
treed0f1a33bcf739e4cd444b30b73b5dd53dcd77541
parent75a819105bef58f8d9be33d4973c79deccbef0e3
net/qlge: Avoids recursive EEH error

One timer, whose handler keeps reading on MMIO register for EEH
core to detect error in time, is started when the PCI device driver
is loaded. MMIO register can't be accessed during PE reset in EEH
recovery. Otherwise, the unexpected recursive error is triggered.
The timer isn't closed that time if the interface isn't brought
up. So the unexpected recursive error is seen during EEH recovery
when the interface is down.

This avoids the unexpected recursive EEH error by closing the timer
in qlge_io_error_detected() before EEH PE reset unconditionally. The
timer is started unconditionally after EEH PE reset in qlge_io_resume().
Also, the timer should be closed unconditionally when the device is
removed from the system permanently in qlge_io_error_detected().

Reported-by: Shriya R. Kulkarni <shriyakul@in.ibm.com>
Signed-off-by: Gavin Shan <gwshan@linux.vnet.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qlge/qlge_main.c