Merge "msm: camera: ife: pagefault_ops access protected with mutex_lock" into camera-kernel.lnx.4.0

This commit is contained in:
Camera Software Integration 2021-04-22 09:38:12 -07:00 • committed by Gerrit - the friendly Code Review server
commit 1eccc13e1e

View file

@ -297,6 +297,7 @@ int cam_context_dump_pf_info(struct cam_context *ctx,
return -EINVAL;
}
mutex_lock(&ctx->ctx_mutex);
if ((ctx->state > CAM_CTX_AVAILABLE) &&
(ctx->state < CAM_CTX_STATE_MAX)) {
if (ctx->state_machine[ctx->state].pagefault_ops) {
@ -307,6 +308,7 @@ int cam_context_dump_pf_info(struct cam_context *ctx,
ctx->dev_hdl, ctx->state);
}
}
mutex_unlock(&ctx->ctx_mutex);
return rc;
}