Skip to content
Commit b69fb769 authored by David Ahern's avatar David Ahern Committed by David S. Miller
Browse files

sparc64: perf: Add sanity checking on addresses in user stack



Processes are getting killed (sigbus or segv) while walking userspace
callchains when using perf. In some instances I have seen ufp = 0x7ff
which does not seem like a proper stack address.

This patch adds a function to run validity checks against the address
before attempting the copy_from_user. The checks are copied from the
x86 version as a start point with the addition of a 4-byte alignment
check.

Signed-off-by: default avatarDavid Ahern <david.ahern@oracle.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 2bf7c3ef
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment