x86/dumpstack: Rename thread_struct::sig_on_uaccess_error to sig_on_uaccess_err
authorIngo Molnar <mingo@kernel.org>
Fri, 15 Jul 2016 08:21:11 +0000 (10:21 +0200)
committerIngo Molnar <mingo@kernel.org>
Fri, 15 Jul 2016 08:26:29 +0000 (10:26 +0200)
Rename it to match the thread_struct::uaccess_err pattern and also
because it was too long.

Cc: Andy Lutomirski <luto@kernel.org>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Brian Gerst <brgerst@gmail.com>
Cc: Denys Vlasenko <dvlasenk@redhat.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Josh Poimboeuf <jpoimboe@redhat.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
arch/x86/entry/vsyscall/vsyscall_64.c
arch/x86/include/asm/processor.h
arch/x86/mm/fault.c

index 3aba2b0..75fc719 100644 (file)
@@ -96,7 +96,7 @@ static bool write_ok_or_segv(unsigned long ptr, size_t size)
 {
        /*
         * XXX: if access_ok, get_user, and put_user handled
-        * sig_on_uaccess_error, this could go away.
+        * sig_on_uaccess_err, this could go away.
         */
 
        if (!access_ok(VERIFY_WRITE, (void __user *)ptr, size)) {
@@ -125,7 +125,7 @@ bool emulate_vsyscall(struct pt_regs *regs, unsigned long address)
        struct task_struct *tsk;
        unsigned long caller;
        int vsyscall_nr, syscall_nr, tmp;
-       int prev_sig_on_uaccess_error;
+       int prev_sig_on_uaccess_err;
        long ret;
 
        /*
@@ -221,8 +221,8 @@ bool emulate_vsyscall(struct pt_regs *regs, unsigned long address)
         * With a real vsyscall, page faults cause SIGSEGV.  We want to
         * preserve that behavior to make writing exploits harder.
         */
-       prev_sig_on_uaccess_error = current->thread.sig_on_uaccess_error;
-       current->thread.sig_on_uaccess_error = 1;
+       prev_sig_on_uaccess_err = current->thread.sig_on_uaccess_err;
+       current->thread.sig_on_uaccess_err = 1;
 
        ret = -EFAULT;
        switch (vsyscall_nr) {
@@ -243,7 +243,7 @@ bool emulate_vsyscall(struct pt_regs *regs, unsigned long address)
                break;
        }
 
-       current->thread.sig_on_uaccess_error = prev_sig_on_uaccess_error;
+       current->thread.sig_on_uaccess_err = prev_sig_on_uaccess_err;
 
 check_fault:
        if (ret == -EFAULT) {
index f53ae57..cbdfe5f 100644 (file)
@@ -419,7 +419,7 @@ struct thread_struct {
        /* Max allowed port in the bitmap, in bytes: */
        unsigned                io_bitmap_max;
 
-       unsigned int            sig_on_uaccess_error:1;
+       unsigned int            sig_on_uaccess_err:1;
        unsigned int            uaccess_err:1;  /* uaccess failed */
 
        /* Floating point and extended processor state */
index 69be03d..d22161a 100644 (file)
@@ -737,7 +737,7 @@ no_context(struct pt_regs *regs, unsigned long error_code,
                 * In this case we need to make sure we're not recursively
                 * faulting through the emulate_vsyscall() logic.
                 */
-               if (current->thread.sig_on_uaccess_error && signal) {
+               if (current->thread.sig_on_uaccess_err && signal) {
                        tsk->thread.trap_nr = X86_TRAP_PF;
                        tsk->thread.error_code = error_code | PF_USER;
                        tsk->thread.cr2 = address;