summaryrefslogtreecommitdiffstats
path: root/kernel/hw_breakpoint.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/hw_breakpoint.c')
-rw-r--r--kernel/hw_breakpoint.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/hw_breakpoint.c b/kernel/hw_breakpoint.c
index 06d372fc026d..dd3fb4a999d3 100644
--- a/kernel/hw_breakpoint.c
+++ b/kernel/hw_breakpoint.c
@@ -442,7 +442,7 @@ register_wide_hw_breakpoint(unsigned long addr,
*pevent = bp;
- if (IS_ERR(bp) || !bp) {
+ if (IS_ERR(bp)) {
err = PTR_ERR(bp);
goto fail;
}
@@ -453,7 +453,7 @@ register_wide_hw_breakpoint(unsigned long addr,
fail:
for_each_possible_cpu(cpu) {
pevent = per_cpu_ptr(cpu_events, cpu);
- if (IS_ERR(*pevent) || !*pevent)
+ if (IS_ERR(*pevent))
break;
unregister_hw_breakpoint(*pevent);
}