]> git.baikalelectronics.ru Git - kernel.git/commit
cxl: Flush PSL cache before resetting the adapter
authorFrederic Barrat <fbarrat@linux.vnet.ibm.com>
Mon, 3 Oct 2016 19:36:02 +0000 (21:36 +0200)
committerMichael Ellerman <mpe@ellerman.id.au>
Tue, 4 Oct 2016 05:16:42 +0000 (16:16 +1100)
commit2e648d7656f11856dd15c8485e6edb19a43003a0
tree8c330d717ea072f8ec77d35b2304d7d0ea196663
parenteec0b30e7f6f1baa89305e03a68df8b9aabfd673
cxl: Flush PSL cache before resetting the adapter

If the capi link is going down while the PSL owns a dirty cache line,
any access from the host for that data could lead to an Uncorrectable
Error.

So when resetting the capi adapter through sysfs, make sure the PSL
cache is flushed. It won't help if there are any active Process
Elements on the card, as the cache would likely get new dirty cache
lines immediately, but if resetting an idle adapter, it should avoid
any bad surprises from data left over from terminated Process Elements.

Signed-off-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com>
Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Acked-by: Ian Munsie <imunsie@au1.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
drivers/misc/cxl/cxl.h
drivers/misc/cxl/native.c
drivers/misc/cxl/pci.c