|
@@ -111,7 +111,7 @@ void arch_unregister_hw_breakpoint(struct perf_event *bp)
|
|
* and the single_step_dabr_instruction(), then cleanup the breakpoint
|
|
* and the single_step_dabr_instruction(), then cleanup the breakpoint
|
|
* restoration variables to prevent dangling pointers.
|
|
* restoration variables to prevent dangling pointers.
|
|
*/
|
|
*/
|
|
- if (bp->ctx->task)
|
|
|
|
|
|
+ if (bp->ctx && bp->ctx->task)
|
|
bp->ctx->task->thread.last_hit_ubp = NULL;
|
|
bp->ctx->task->thread.last_hit_ubp = NULL;
|
|
}
|
|
}
|
|
|
|
|