diff options
| author | Ian Munsie <imunsie@au1.ibm.com> | 2014-12-08 03:17:58 -0500 |
|---|---|---|
| committer | Michael Ellerman <mpe@ellerman.id.au> | 2014-12-28 23:45:43 -0500 |
| commit | 13da704682471669685ccc3fe111fd6c0127b2eb (patch) | |
| tree | f87c02d70f9c52b6439767a9244c9c2393aa5610 /drivers/misc | |
| parent | 456295e284beb7b61a55ead9500d30f94ab06d52 (diff) | |
cxl: Early return from cxl_handle_fault for a shut down context
If a context is being detached and we get a translation fault for it
there is little point getting it's mm and handling the fault, so just
respond with an address error and return earlier.
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/fault.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/misc/cxl/fault.c b/drivers/misc/cxl/fault.c index f8684bca2d79..e010302a192b 100644 --- a/drivers/misc/cxl/fault.c +++ b/drivers/misc/cxl/fault.c | |||
| @@ -180,6 +180,12 @@ void cxl_handle_fault(struct work_struct *fault_work) | |||
| 180 | return; | 180 | return; |
| 181 | } | 181 | } |
| 182 | 182 | ||
| 183 | /* Early return if the context is being / has been detached */ | ||
| 184 | if (ctx->status == CLOSED) { | ||
| 185 | cxl_ack_ae(ctx); | ||
| 186 | return; | ||
| 187 | } | ||
| 188 | |||
| 183 | pr_devel("CXL BOTTOM HALF handling fault for afu pe: %i. " | 189 | pr_devel("CXL BOTTOM HALF handling fault for afu pe: %i. " |
| 184 | "DSISR: %#llx DAR: %#llx\n", ctx->pe, dsisr, dar); | 190 | "DSISR: %#llx DAR: %#llx\n", ctx->pe, dsisr, dar); |
| 185 | 191 | ||
