diff options
author | Will Deacon <[email protected]> | 2020-06-18 11:16:45 +0100 |
---|---|---|
committer | Russell King <[email protected]> | 2020-07-21 16:32:54 +0100 |
commit | eec13b42d41b0f3339dcf0c4da43734427c68620 (patch) | |
tree | 36f0cd8798f26a08319d8b35b5ab877a26ade01c /lib/mpi/mpi-add.c | |
parent | dcb7fd82c75ee2d6e6f9d8cc71c52519ed52e258 (diff) |
ARM: 8986/1: hw_breakpoint: Don't invoke overflow handler on uaccess watchpoints
Unprivileged memory accesses generated by the so-called "translated"
instructions (e.g. LDRT) in kernel mode can cause user watchpoints to fire
unexpectedly. In such cases, the hw_breakpoint logic will invoke the user
overflow handler which will typically raise a SIGTRAP back to the current
task. This is futile when returning back to the kernel because (a) the
signal won't have been delivered and (b) userspace can't handle the thing
anyway.
Avoid invoking the user overflow handler for watchpoints triggered by
kernel uaccess routines, and instead single-step over the faulting
instruction as we would if no overflow handler had been installed.
Cc: <[email protected]>
Fixes: f81ef4a920c8 ("ARM: 6356/1: hw-breakpoint: add ARM backend for the hw-breakpoint framework")
Reported-by: Luis Machado <[email protected]>
Tested-by: Luis Machado <[email protected]>
Signed-off-by: Will Deacon <[email protected]>
Signed-off-by: Russell King <[email protected]>
Diffstat (limited to 'lib/mpi/mpi-add.c')
0 files changed, 0 insertions, 0 deletions