Skip to content
Commit 5f74f820 authored by Helge Deller's avatar Helge Deller Committed by Andrew Morton
Browse files

parisc: fix mmap_base calculation when stack grows upwards

Matoro reported various userspace crashes on the parisc platform with kernel
6.6 and bisected it to commit 3033cd43 ("parisc: Use generic mmap top-down
layout and brk randomization").

That commit switched parisc to use the common infrastructure to calculate
mmap_base, but missed that the mmap_base() function takes care for
architectures where the stack grows downwards only.

Fix the mmap_base() calculation to include the stack-grows-upwards case
and thus fix the userspace crashes on parisc.

Link: https://lkml.kernel.org/r/ZVH2qeS1bG7/1J/l@p100
Fixes: 3033cd43

 ("parisc: Use generic mmap top-down layout and brk randomization")
Signed-off-by: default avatarHelge Deller <deller@gmx.de>
Reported-by: default avatarmatoro <matoro_mailinglist_kernel@matoro.tk>
Tested-by: default avatarmatoro <matoro_mailinglist_kernel@matoro.tk>
Cc: <stable@vger.kernel.org>	[6.6+]
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent 13b2a4b2
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