* Change MINSIGSTKSZ and SIGSTKSIZE
@ 2014-04-12 9:59 Haren Myneni
2014-04-14 6:53 ` Alan Modra
0 siblings, 1 reply; 2+ messages in thread
From: Haren Myneni @ 2014-04-12 9:59 UTC (permalink / raw)
To: amodra, benh; +Cc: linuxppc-dev
Alan,
LTP test (signalstack02) is failing. This test expects -ENOMEM from
kernel when passing less than stack size (passing 4095). MINSIGSTKSZ in
signal.h (glibc) is changed to 4096 to support VSX changes
(https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=f7c399cff5bd04ee9dc117fb6b0f39597dc047c6) We should also change these values in kernel to match with glibc. Any issues?
diff --git a/arch/powerpc/include/uapi/asm/signal.h
b/arch/powerpc/include/uapi/
index 6c69ee9..18f498e 100644
--- a/arch/powerpc/include/uapi/asm/signal.h
+++ b/arch/powerpc/include/uapi/asm/signal.h
@@ -85,8 +85,8 @@ typedef struct {
#define SA_RESTORER 0x04000000U
-#define MINSIGSTKSZ 2048
-#define SIGSTKSZ 8192
+#define MINSIGSTKSZ 4096
+#define SIGSTKSZ 16384
Thanks
Haren
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: Change MINSIGSTKSZ and SIGSTKSIZE
2014-04-12 9:59 Change MINSIGSTKSZ and SIGSTKSIZE Haren Myneni
@ 2014-04-14 6:53 ` Alan Modra
0 siblings, 0 replies; 2+ messages in thread
From: Alan Modra @ 2014-04-14 6:53 UTC (permalink / raw)
To: Haren Myneni; +Cc: linuxppc-dev
On Sat, Apr 12, 2014 at 02:59:55AM -0700, Haren Myneni wrote:
> Alan,
> LTP test (signalstack02) is failing.
Ignore the stupid test. Do *NOT* change the kernel value to match
glibc. The two sets of constants are independent.
The glibc constants are for user code, to allocate correctly sized
signal stacks for all known kernels. These constants are therefore
the maximum values needed for known kernels.
The kernel constants are to check that user code is setting up a large
enough signal stack *for that specific kernel, and user binary*. If
you make the kernel constants match current glibc, then old binaries
that don't use htm or vsx will fail when run on a newer kernel.
Ideally the kernel would detect whether a binary was going to use htm
or vsx and adjust the minimum sizes, but it's a wee bit difficult for
the kernel to know that ahead of time.
> This test expects -ENOMEM from
> kernel when passing less than stack size (passing 4095). MINSIGSTKSZ in
> signal.h (glibc) is changed to 4096 to support VSX changes
> (https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=f7c399cff5bd04ee9dc117fb6b0f39597dc047c6) We should also change these values in kernel to match with glibc. Any issues?
>
> diff --git a/arch/powerpc/include/uapi/asm/signal.h
> b/arch/powerpc/include/uapi/
> index 6c69ee9..18f498e 100644
> --- a/arch/powerpc/include/uapi/asm/signal.h
> +++ b/arch/powerpc/include/uapi/asm/signal.h
> @@ -85,8 +85,8 @@ typedef struct {
>
> #define SA_RESTORER 0x04000000U
>
> -#define MINSIGSTKSZ 2048
> -#define SIGSTKSZ 8192
> +#define MINSIGSTKSZ 4096
> +#define SIGSTKSZ 16384
>
> Thanks
> Haren
--
Alan Modra
Australia Development Lab, IBM
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-04-14 6:53 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-04-12 9:59 Change MINSIGSTKSZ and SIGSTKSIZE Haren Myneni
2014-04-14 6:53 ` Alan Modra
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.