Re: [PATCH] guard page for stacks that grow upwards

From: Linus Torvalds
Date: Tue Aug 24 2010 - 12:54:22 EST


On Tue, Aug 24, 2010 at 9:31 AM, Luck, Tony <tony.luck@xxxxxxxxx> wrote:
>
> Updated to match the new code - still not tested on pa-risc.

But the ia64 grows-up case is tested?

> The #ifdefs are ugly - suggestions welcome on how to make
> the code prettier.

One thing I've considered is to get rid of the CONFIG_STACK_GROWSUP
crap entirely in code, and instead just make the VM_GROWSUP #define be
0 for architectures that don't want it. The compiler should then just
automatically remove all the code that says

if (vma->vm_flags & VM_GROWSUP) {
...

and the code would look more straightforward. Hmm?

Linus
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/