[PATCH 2/2] powerpc/64: Increase stack redzone for 64-bit kernel to 512 bytes

Bin Meng bmeng.cn at gmail.com
Mon Oct 1 11:11:04 AEST 2018


Hi Nick,

On Mon, Oct 1, 2018 at 7:27 AM Nicholas Piggin <npiggin at gmail.com> wrote:
>
> On Sat, 29 Sep 2018 23:25:20 -0700
> Bin Meng <bmeng.cn at gmail.com> wrote:
>
> > commit 573ebfa6601f ("powerpc: Increase stack redzone for 64-bit
> > userspace to 512 bytes") only changes stack userspace redzone size.
> > We need increase the kernel one to 512 bytes too per ABIv2 spec.
>
> You're right we need 512 to be compatible with ABIv2, but as the
> comment says, gcc limits this to 288 bytes so that's what is used
> to save stack space. We can use a compiler version test to change
> this if llvm or a new version of gcc does something different.
>

I believe what the comment says is for ABIv1. At the time when commit
573ebfa6601f was submitted, kernel had not switched to ABIv2 build
yet.

Regards,
Bin


More information about the Linuxppc-dev mailing list