mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 03:01:39 -04:00
Sanitize the type of struct user.u_ar0
struct user.u_ar0 is defined to contain a pointer offset on all architectures in which it is defined (all architectures which define an a.out format except SPARC.) However, it has a pointer type in the headers, which is pointless -- <asm/user.h> is not exported to userspace, and it just makes the code messy. Redefine the field as "unsigned long" (which is the same size as a pointer on all Linux architectures) and change the setting code to user offsetof() instead of hand-coded arithmetic. Cc: Linux Arch Mailing List <[email protected]> Cc: Bryan Wu <[email protected]> Cc: Roman Zippel <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Richard Henderson <[email protected]> Cc: Ivan Kokshaysky <[email protected]> Cc: Russell King <[email protected]> Cc: Lennert Buytenhek <[email protected]> Cc: Håvard Skinnemoen <[email protected]> Cc: Mikael Starvik <[email protected]> Cc: Yoshinori Sato <[email protected]> Cc: Tony Luck <[email protected]> Cc: Hirokazu Takata <[email protected]> Cc: Ralf Baechle <[email protected]> Cc: Paul Mackerras <[email protected]> Cc: Martin Schwidefsky <[email protected]> Cc: Heiko Carstens <[email protected]> Cc: Paul Mundt <[email protected]> Signed-off-by: H. Peter Anvin <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
ed7b1889da
commit
6e16d89bcd
18 changed files with 18 additions and 22 deletions
|
|
@ -44,7 +44,7 @@ struct user {
|
|||
unsigned long start_data; /* data starting address */
|
||||
unsigned long start_stack; /* stack starting address */
|
||||
long int signal; /* signal causing core dump */
|
||||
struct regs * u_ar0; /* help gdb find registers */
|
||||
unsigned long u_ar0; /* help gdb find registers */
|
||||
unsigned long magic; /* identifies a core file */
|
||||
char u_comm[32]; /* user command name */
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in a new issue