Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 326f0dc4 authored by Isaac J. Manjarres's avatar Isaac J. Manjarres
Browse files

qcom: minidump: Fix stack pointer arithmetic to avoid underflow



Currently, the stack pointer value that is being passed in
might be 0, or might be some value that is not a kernel
address, but it would still be useful to attempt to dump
the process' stack. Add check to use current stack pointer
if given value is not a kernel address. Also, the PAGE_ALIGN
macro up-aligns a value that is passed into it, which is not
correct, so use correct arithmetic to obtain aligned stack
pointer value, and add sanity check to ensure that the stack
pointer is within the process stack to avoid underflow errors
that may lead to registering a large amount of minidump
entries.

Change-Id: I211464cbff669a5dd4ffa0919ffea4f79fe55db1
Signed-off-by: default avatarIsaac J. Manjarres <isaacm@codeaurora.org>
parent ac121119
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment