summaryrefslogtreecommitdiffstats
path: root/drivers/misc/cxl/vphb.c
diff options
context:
space:
mode:
authorDaniel Axtens <dja@axtens.net>2015-08-14 09:41:26 +0200
committerMichael Ellerman <mpe@ellerman.id.au>2015-08-14 13:32:08 +0200
commit9e8df8a219635c5af36a49d78c1f69009b780339 (patch)
tree047bc03af4becb5e3c767f0346242b42ff6a1597 /drivers/misc/cxl/vphb.c
parentcxl: Allow the kernel to trust that an image won't change on PERST. (diff)
downloadlinux-9e8df8a219635c5af36a49d78c1f69009b780339.tar.xz
linux-9e8df8a219635c5af36a49d78c1f69009b780339.zip
cxl: EEH support
EEH (Enhanced Error Handling) allows a driver to recover from the temporary failure of an attached PCI card. Enable basic CXL support for EEH. Signed-off-by: Daniel Axtens <dja@axtens.net> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'drivers/misc/cxl/vphb.c')
-rw-r--r--drivers/misc/cxl/vphb.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/misc/cxl/vphb.c b/drivers/misc/cxl/vphb.c
index 2930911c1e42..6dd16a6d153f 100644
--- a/drivers/misc/cxl/vphb.c
+++ b/drivers/misc/cxl/vphb.c
@@ -266,6 +266,14 @@ int cxl_pci_vphb_add(struct cxl_afu *afu)
return 0;
}
+void cxl_pci_vphb_reconfigure(struct cxl_afu *afu)
+{
+ /* When we are reconfigured, the AFU's MMIO space is unmapped
+ * and remapped. We need to reflect this in the PHB's view of
+ * the world.
+ */
+ afu->phb->cfg_addr = afu->afu_desc_mmio + afu->crs_offset;
+}
void cxl_pci_vphb_remove(struct cxl_afu *afu)
{