linux-stable/drivers/misc/cxl
Vaibhav Jain 4f58f0bf15 cxl: Route eeh events to all drivers in cxl_pci_error_detected()
Fix a boundary condition where in some cases an eeh event that results
in card reset isn't passed on to a driver attached to the virtual PCI
device associated with a slice. This will happen in case when a slice
attached device driver returns a value other than
PCI_ERS_RESULT_NEED_RESET from the eeh error_detected() callback. This
would result in an early return from cxl_pci_error_detected() and
other drivers attached to other AFUs on the card wont be notified.

The patch fixes this by making sure that all slice attached
device-drivers are notified and the return values from
error_detected() callback are aggregated in a scheme where request for
'disconnect' trumps all and 'none' trumps 'need_reset'.

Fixes: 9e8df8a219 ("cxl: EEH support")
Cc: stable@vger.kernel.org # v4.3+
Signed-off-by: Vaibhav Jain <vaibhav@linux.vnet.ibm.com>
Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Acked-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
2017-05-02 22:41:42 +10:00
..
api.c cxl: Keep track of mm struct associated with a context 2017-04-13 23:34:29 +10:00
base.c cxl: Add support for interrupts on the Mellanox CX4 2016-07-14 20:27:08 +10:00
context.c cxl: Add psl9 specific code 2017-04-13 23:34:31 +10:00
cxl.h cxl: Add psl9 specific code 2017-04-13 23:34:31 +10:00
debugfs.c cxl: Add psl9 specific code 2017-04-13 23:34:31 +10:00
fault.c cxl: Add psl9 specific code 2017-04-13 23:34:31 +10:00
file.c cxl: Keep track of mm struct associated with a context 2017-04-13 23:34:29 +10:00
flash.c cxl: static-ify variables to fix sparse warnings 2016-06-16 22:49:27 +10:00
guest.c cxl: Add psl9 specific code 2017-04-13 23:34:31 +10:00
hcalls.c cxl: Remove unused values in bare-metal environment. 2017-04-13 23:34:28 +10:00
hcalls.h cxl: Add guest-specific code 2016-03-09 23:36:52 +11:00
irq.c cxl: Add psl9 specific code 2017-04-13 23:34:31 +10:00
Kconfig cxl: remove dead Kconfig options 2016-07-19 20:12:29 +10:00
main.c cxl: Keep track of mm struct associated with a context 2017-04-13 23:34:29 +10:00
Makefile cxl: Fix build when CONFIG_DEBUG_FS=n 2017-02-03 21:59:26 +11:00
native.c cxl: Add psl9 specific code 2017-04-13 23:34:31 +10:00
of.c cxl: replace loop with for_each_child_of_node(), remove unneeded of_node_put() 2016-10-04 16:19:23 +11:00
pci.c cxl: Route eeh events to all drivers in cxl_pci_error_detected() 2017-05-02 22:41:42 +10:00
phb.c cxl: Fix error handling in _cxl_pci_associate_default_context() 2016-11-18 22:41:08 +11:00
sysfs.c cxl: Prevent adapter reset if an active context exists 2016-10-19 20:35:39 +11:00
trace.c cxl: Add tracepoints 2015-01-22 17:31:51 +11:00
trace.h cxl: Add psl9 specific code 2017-04-13 23:34:31 +10:00
vphb.c cxl: fix nested locking hang during EEH hotplug 2017-02-21 21:32:52 +11:00