summaryrefslogtreecommitdiffstats
path: root/drivers/misc
diff options
context:
space:
mode:
authorIan Munsie <imunsie@au1.ibm.com>2014-12-08 19:18:00 +1100
committerMichael Ellerman <mpe@ellerman.id.au>2014-12-29 15:45:44 +1100
commitdb7933f392ac4d9719d41d3f203a5f6a1c40f300 (patch)
tree9be0bfb179762babcba298c5b6b0854f3de54ee5 /drivers/misc
parentd6a6af2c181400aade59417e698c7cd9bec8804e (diff)
downloadop-kernel-dev-db7933f392ac4d9719d41d3f203a5f6a1c40f300.zip
op-kernel-dev-db7933f392ac4d9719d41d3f203a5f6a1c40f300.tar.gz
cxl: Disable SPAP register when freeing SPA
When we deactivate the AFU directed mode we free the scheduled process area, but did not clear the register in the hardware that has a pointer to it. This should be fine since we will have already cleared out every context and we won't do anything that would cause the hardware to access it until after we have allocated a new one, but just to be safe this patch clears out the register when we free the page. Signed-off-by: Ian Munsie <imunsie@au1.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/cxl/native.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/misc/cxl/native.c b/drivers/misc/cxl/native.c
index f2b37b4..0f24fa5 100644
--- a/drivers/misc/cxl/native.c
+++ b/drivers/misc/cxl/native.c
@@ -185,6 +185,7 @@ static int alloc_spa(struct cxl_afu *afu)
static void release_spa(struct cxl_afu *afu)
{
+ cxl_p1n_write(afu, CXL_PSL_SPAP_An, 0);
free_pages((unsigned long) afu->spa, afu->spa_order);
}
OpenPOWER on IntegriCloud