diff options
author | David S. Miller <davem@davemloft.net> | 2010-02-09 19:18:40 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-02-09 19:18:40 -0500 |
commit | f036d9f3985a529a81e582f68aa984eb7b20d54d (patch) | |
tree | eaf58cc5d2c81e3ca08e23b5cda76eacd515d166 /arch/sparc/kernel/process_64.c | |
parent | 6abce7711fcbd72b42f0c9632c1beccf4e674663 (diff) |
sparc: Align clone and signal stacks to 16 bytes.
This is mandatory for 64-bit processes, and doing it also for 32-bit
processes saves a conditional in the compat case.
This fixes the glibc/nptl/tst-stdio1 test case, as well
as many others, on 64-bit.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc/kernel/process_64.c')
-rw-r--r-- | arch/sparc/kernel/process_64.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/sparc/kernel/process_64.c b/arch/sparc/kernel/process_64.c index 18d67854a1b8..6679eebfd2e8 100644 --- a/arch/sparc/kernel/process_64.c +++ b/arch/sparc/kernel/process_64.c | |||
@@ -406,11 +406,11 @@ static unsigned long clone_stackframe(unsigned long csp, unsigned long psp) | |||
406 | } else | 406 | } else |
407 | __get_user(fp, &(((struct reg_window32 __user *)psp)->ins[6])); | 407 | __get_user(fp, &(((struct reg_window32 __user *)psp)->ins[6])); |
408 | 408 | ||
409 | /* Now 8-byte align the stack as this is mandatory in the | 409 | /* Now align the stack as this is mandatory in the Sparc ABI |
410 | * Sparc ABI due to how register windows work. This hides | 410 | * due to how register windows work. This hides the |
411 | * the restriction from thread libraries etc. -DaveM | 411 | * restriction from thread libraries etc. |
412 | */ | 412 | */ |
413 | csp &= ~7UL; | 413 | csp &= ~15UL; |
414 | 414 | ||
415 | distance = fp - psp; | 415 | distance = fp - psp; |
416 | rval = (csp - distance); | 416 | rval = (csp - distance); |