On Fri, 2016-12-09 at 06:18:50 UTC, Andrew Donnellan wrote:
> During EEH recovery, we deconfigure all AFUs whilst leaving the
> corresponding vPHB and virtual PCI device in place.
> 
> If something attempts to interact with the AFU's PCI config space (e.g.
> running lspci) after the AFU has been deconfigured and before it's
> reconfigured, cxl_pcie_{read,write}_config() will read invalid values from
> the deconfigured struct cxl_afu and proceed to Oops when they try to
> dereference pointers that have been set to NULL during deconfiguration.
> 
> Add a rwsem to struct cxl_afu so we can prevent interaction with config
> space while the AFU is deconfigured.
> 
> Reported-by: Pradipta Ghosh <pradg...@in.ibm.com>
> Suggested-by: Frederic Barrat <fbar...@linux.vnet.ibm.com>
> Cc: sta...@vger.kernel.org # v4.9+
> Signed-off-by: Andrew Donnellan <andrew.donnel...@au1.ibm.com>
> Signed-off-by: Vaibhav Jain <vaib...@linux.vnet.ibm.com>

Applied to powerpc next, thanks.

https://git.kernel.org/powerpc/c/14a3ae34bfd0bcb1cc12d55b06a858

cheers

Reply via email to