diff options
author | Helge Deller <deller@gmx.de> | 2014-11-10 21:46:18 +0100 |
---|---|---|
committer | Helge Deller <deller@gmx.de> | 2014-11-10 22:23:47 +0100 |
commit | 2fe749f50b0bec07650ef135b29b1f55bf543869 (patch) | |
tree | 14e9710de27abed444b6b04eecf21249ee72f4a0 /arch/parisc/include/uapi | |
parent | 8dd95c68f32b821ec02e89c42a4e500d6aebbd84 (diff) | |
download | op-kernel-dev-2fe749f50b0bec07650ef135b29b1f55bf543869.zip op-kernel-dev-2fe749f50b0bec07650ef135b29b1f55bf543869.tar.gz |
parisc: Use compat layer for msgctl, shmat, shmctl and semtimedop syscalls
Switch over the msgctl, shmat, shmctl and semtimedop syscalls to use the compat
layer. The problem was found with the debian procenv package, which called
shmctl(0, SHM_INFO, &info);
in which the shmctl syscall then overwrote parts of the surrounding areas on
the stack on which the info variable was stored and thus lead to a segfault
later on.
Additionally fix the definition of struct shminfo64 to use unsigned longs like
the other architectures. This has no impact on userspace since we only have a
32bit userspace up to now.
Signed-off-by: Helge Deller <deller@gmx.de>
Cc: John David Anglin <dave.anglin@bell.net>
Cc: <stable@vger.kernel.org> # v3.10+
Diffstat (limited to 'arch/parisc/include/uapi')
-rw-r--r-- | arch/parisc/include/uapi/asm/shmbuf.h | 25 |
1 files changed, 9 insertions, 16 deletions
diff --git a/arch/parisc/include/uapi/asm/shmbuf.h b/arch/parisc/include/uapi/asm/shmbuf.h index 0a3eada..f395cde 100644 --- a/arch/parisc/include/uapi/asm/shmbuf.h +++ b/arch/parisc/include/uapi/asm/shmbuf.h @@ -36,23 +36,16 @@ struct shmid64_ds { unsigned int __unused2; }; -#ifdef CONFIG_64BIT -/* The 'unsigned int' (formerly 'unsigned long') data types below will - * ensure that a 32-bit app calling shmctl(*,IPC_INFO,*) will work on - * a wide kernel, but if some of these values are meant to contain pointers - * they may need to be 'long long' instead. -PB XXX FIXME - */ -#endif struct shminfo64 { - unsigned int shmmax; - unsigned int shmmin; - unsigned int shmmni; - unsigned int shmseg; - unsigned int shmall; - unsigned int __unused1; - unsigned int __unused2; - unsigned int __unused3; - unsigned int __unused4; + unsigned long shmmax; + unsigned long shmmin; + unsigned long shmmni; + unsigned long shmseg; + unsigned long shmall; + unsigned long __unused1; + unsigned long __unused2; + unsigned long __unused3; + unsigned long __unused4; }; #endif /* _PARISC_SHMBUF_H */ |