[PATCH 3/5] arch/mips, termios: use

2018-10-04 Thread H. Peter Anvin (Intel)
The MIPS definition of termbits.h is almost identical to the generic one, so use the generic one and only redefine a handful of constants. Move TIOCSER_TEMT to ioctls.h where it lives for all other architectures. Signed-off-by: H. Peter Anvin (Intel) Cc: Ralf Baechle Cc: Paul Burton Cc: James

[PATCH 1/5] asm-generic, termios: add alias constants from MIPS

2018-10-04 Thread H. Peter Anvin (Intel)
Some architectures, in this case MIPS, need a couple of legacy alias constants for bits. There really is no reason why we can't define them generically for all architectures. Signed-off-by: H. Peter Anvin (Intel) Cc: Arnd Bergmann Cc: Greg Kroah-Hartman Cc: Jiri Slaby linux-k

[PATCH 5/5] arch/xtensa, termios: use

2018-10-04 Thread H. Peter Anvin (Intel)
The Xtensa definition of termbits.h is identical to the generic one. Signed-off-by: H. Peter Anvin (Intel) Cc: Chris Zankel Cc: Max Filippov Cc: Thomas Gleixner Cc: Greg Kroah-Hartman Cc: Philippe Ombredanne Cc: Kate Stewart Cc: Cc: Greg Kroah-Hartman Cc: Jiri Slaby --- arch/xtensa

[PATCH 0/5] termios: remove arch redundancy in

2018-10-04 Thread H. Peter Anvin (Intel)
changed, 27 insertions(+), 824 deletions(-) Signed-off-by: H. Peter Anvin (Intel) Cc: "James E.J. Bottomley" Cc: Arnd Bergmann Cc: Chris Zankel Cc: Fenghua Yu Cc: Greg Kroah-Hartman Cc: Helge Deller Cc: James Hogan Cc: Jiri Slaby Cc: Kate Stewart Cc: Max Filippov Cc: Paul

[PATCH 2/5] arch/ia64, termios: use

2018-10-04 Thread H. Peter Anvin (Intel)
The IA64 definition of termbits.h is identical to the generic. Signed-off-by: H. Peter Anvin (Intel) Cc: Tony Luck Cc: Fenghua Yu Cc: Kate Stewart Cc: Philippe Ombredanne Cc: Greg Kroah-Hartman Cc: Thomas Gleixner Cc: Cc: Greg Kroah-Hartman CC: Jiri Slaby --- arch/ia64/include/uapi/asm

[PATCH 4/5] arch/parisc, termios: use

2018-10-04 Thread H. Peter Anvin (Intel)
The PARISC definition of termbits.h is almost identical to the generic one, so use the generic one and only redefine a handful of constants. Signed-off-by: H. Peter Anvin (Intel) Cc: "James E.J. Bottomley" Cc: Helge Deller Cc: Kate Stewart Cc: Thomas Gleixner Cc: Philippe Ombr

[PATCH v3 1/7] x86/ldt: refresh %fs and %gs in refresh_ldt_segments()

2018-06-21 Thread H. Peter Anvin, Intel
h. Signed-off-by: H. Peter Anvin (Intel) Cc: Ingo Molnar Cc: Thomas Gleixner Cc: Andy Lutomirski Cc: Chang S. Bae Cc: Markus T. Metzger --- arch/x86/kernel/ldt.c | 70 +++ 1 file changed, 54 insertions(+), 16 deletions(-) diff --git a/arch/x86/ker

[PATCH v3 2/7] x86/ldt: use a common value for read_default_ldt()

2018-06-21 Thread H. Peter Anvin, Intel
which is the larger of the two. Signed-off-by: H. Peter Anvin (Intel) Cc: Ingo Molnar Cc: Thomas Gleixner Cc: Andy Lutomirski Cc: Chang S. Bae Cc: Markus T. Metzger --- arch/x86/kernel/ldt.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/arch/x86/kernel/ldt.c b/a

[PATCH v3 3/7] x86: move fill_user_desc() from tls.c to desc.h and add validity check

2018-06-21 Thread H. Peter Anvin, Intel
From: "H. Peter Anvin" This is generic code which is potentially useful in other contexts. Unfortunately modify_ldt() is kind of stupid in that it returns a descriptor in CPU format but takes a different format, but regsets *have* to operate differently. Signed-off-by: H. Peter An

[PATCH v3 0/7] x86/ptrace: regset access to the GDT and LDT

2018-06-21 Thread H. Peter Anvin, Intel
From: "H. Peter Anvin" Give a debugger access to the visible part of the GDT and LDT. This allows a debugger to find out what a particular segment descriptor corresponds to; e.g. if %cs is 16, 32, or 64 bits. v3: Requalify LDT segments for selectors that have actually changed. v2:

[PATCH v3 7/7] x86/ldt,ptrace: provide regset access to the LDT

2018-06-21 Thread H. Peter Anvin, Intel
From: "H. Peter Anvin" Provide ptrace/regset access to the LDT, if one exists. This interface provides both read and write access. The write code is unified with modify_ldt(); the read code doesn't have enough similarity so it has been kept made separate. Signed-off-by: H. Pet

[PATCH v3 5/7] x86/segment: add #define for the last user-visible GDT slot

2018-06-21 Thread H. Peter Anvin, Intel
From: "H. Peter Anvin" We don't want to advertise to user space how many slots the kernel GDT has, but user space can trivially find out what the last user-accessible GDT slot is. Add a #define for that so we can use that in sizing a regset. Signed-off-by: H. Peter Anvin (I

[PATCH v3 4/7] x86/tls: create an explicit config symbol for the TLS area in the GDT

2018-06-21 Thread H. Peter Anvin, Intel
From: "H. Peter Anvin" Instead of using X86_32 || IA32_EMULATION, which is really rather ugly in the Makefile especially, create a dedicated config symbol for the TLS area. This will be further used in subsequent patches. Signed-off-by: H. Peter Anvin (Intel) Cc: Ingo Molnar

[PATCH v3 6/7] x86/tls,ptrace: provide regset access to the GDT

2018-06-21 Thread H. Peter Anvin, Intel
rea is the only user-modifiable part of the GDT. Signed-off-by: H. Peter Anvin (Intel) Cc: Ingo Molnar Cc: Thomas Gleixner Cc: Andy Lutomirski Cc: Chang S. Bae Cc: Markus T. Metzger --- arch/x86/kernel/ptrace.c | 83 ++-- arch/x86/kernel/tls