1. 12 2月, 2009 5 次提交
  2. 11 2月, 2009 9 次提交
    • R
      x86: cleanup, rename CONFIG_X86_NON_STANDARD to CONFIG_X86_EXTENDED_PLATFORM · c5c606d9
      Ravikiran G Thirumalai 提交于
      Patch to rename the CONFIG_X86_NON_STANDARD to CONFIG_X86_EXTENDED_PLATFORM.
      
      The new name represents the subarches better. Also, default this to 'y'
      so that many of the sub architectures that were not easily visible now
      become visible.
      
      Also re-organize the extended architecture platform and non standard
      platform list alphabetically as suggested by Ingo.
      Signed-off-by: NRavikiran Thirumalai <kiran@scalex86.org>
      Signed-off-by: NShai Fultheim <shai@scalex86.org>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      c5c606d9
    • B
      x86: drop -fno-stack-protector annotations after pt_regs fixes · 9c8bb6b5
      Brian Gerst 提交于
      Now that no functions rely on struct pt_regs being passed by value,
      various "no stack protector" annotations can be dropped.
      Signed-off-by: NBrian Gerst <brgerst@gmail.com>
      Acked-by: NTejun Heo <tj@kernel.org>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      9c8bb6b5
    • B
      x86: pass in pt_regs pointer for syscalls that need it · 253f29a4
      Brian Gerst 提交于
      Some syscalls need to access the pt_regs structure, either to copy
      user register state or to modifiy it.  This patch adds stubs to load
      the address of the pt_regs struct into the %eax register, and changes
      the syscalls to regparm(1) to receive the pt_regs pointer as the
      first argument.
      Signed-off-by: NBrian Gerst <brgerst@gmail.com>
      Acked-by: NTejun Heo <tj@kernel.org>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      253f29a4
    • B
      x86: use pt_regs pointer in do_device_not_available() · aa78bcfa
      Brian Gerst 提交于
      The generic exception handler (error_code) passes in the pt_regs
      pointer and the error code (unused in this case).  The commit
      "x86: fix math_emu register frame access" changed this to pass by
      value, which doesn't work correctly with stack protector enabled.
      Change it back to use the pt_regs pointer.
      Signed-off-by: NBrian Gerst <brgerst@gmail.com>
      Acked-by: NTejun Heo <tj@kernel.org>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      aa78bcfa
    • T
      x86: fix x86_32 stack protector bugs · 5c79d2a5
      Tejun Heo 提交于
      Impact: fix x86_32 stack protector
      
      Brian Gerst found out that %gs was being initialized to stack_canary
      instead of stack_canary - 20, which basically gave the same canary
      value for all threads.  Fixing this also exposed the following bugs.
      
      * cpu_idle() didn't call boot_init_stack_canary()
      
      * stack canary switching in switch_to() was being done too late making
        the initial run of a new thread use the old stack canary value.
      
      Fix all of them and while at it update comment in cpu_idle() about
      calling boot_init_stack_canary().
      Reported-by: NBrian Gerst <brgerst@gmail.com>
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      5c79d2a5
    • I
      x86, apic: make generic_apic_probe() generally available · 160d8dac
      Ingo Molnar 提交于
      Impact: build fix
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      160d8dac
    • A
      x86, apic: fix initialization of wakeup_cpu · 0e81cb59
      Alok Kataria 提交于
      With refactoring of wake_cpu macros the 32bit code in tip doesn't
      execute generic_apic_probe if CONFIG_X86_32_NON_STANDARD is not set.
      
      Even on a x86 STANDARD cpu we need to execute the generic_apic_probe
      function, as we rely on this function to execute the update_genapic
      quirk which initilizes apic->wakeup_cpu.
      
      Failing to do so results in we making a call to a null function in do_boot_cpu.
      
      The stack trace without the patch goes like this.
      
      Booting processor 1 APIC 0x1 ip 0x6000
      BUG: unable to handle kernel NULL pointer dereference at (null)
      IP: [<(null)>] (null)
      *pdpt = 0000000000839001 *pde = 0000000000c97067 *pte = 0000000000000163
      Oops: 0000 [#1] SMP
      last sysfs file:
      Modules linked in:
      
      Pid: 1, comm: swapper Not tainted (2.6.29-rc4-tip #18) VMware Virtual Platform
      EIP: 0062:[<00000000>] EFLAGS: 00010293 CPU: 0
      EIP is at 0x0
      EAX: 00000001 EBX: 00006000 ECX: c077ed00 EDX: 00006000
      ESI: 00000001 EDI: 00000001 EBP: ef04cf40 ESP: ef04cf1c
       DS: 007b ES: 007b FS: 00d8 GS: 0000 SS: 006a
      Process swapper (pid: 1, ti=ef04c000 task=ef050000 task.ti=ef04c000)
      Stack:
       c0644e52 00000000 ef04cf24 ef04cf24 c064468d c0886dc0 00000000 c0702aea
       ef055480 00000001 00000101 dead4ead ffffffff ffffffff c08af530 00000000
       c0709715 ef04cf60 ef04cf60 00000001 00000000 00000000 dead4ead ffffffff
      Call Trace:
       [<c0644e52>] ? native_cpu_up+0x2de/0x45b
       [<c064468d>] ? do_fork_idle+0x0/0x19
       [<c0645c5e>] ? _cpu_up+0x88/0xe8
       [<c0645d20>] ? cpu_up+0x42/0x4e
       [<c07e7462>] ? kernel_init+0x99/0x14b
       [<c07e73c9>] ? kernel_init+0x0/0x14b
       [<c040375f>] ? kernel_thread_helper+0x7/0x10
      Code:  Bad EIP value.
      EIP: [<00000000>] 0x0 SS:ESP 006a:ef04cf1c
      
      I think we should call generic_apic_probe unconditionally for 32 bit now.
      Signed-off-by: NAlok N Kataria <akataria@vmware.com>
      Acked-by: NYinghai Lu <yinghai@kernel.org>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      0e81cb59
    • S
      tracing, x86: fix constraint for parent variable · f47a454d
      Steven Rostedt 提交于
      The constraint used for retrieving and restoring the parent function
      pointer is incorrect. The parent variable is a pointer, and the
      address of the pointer is modified by the asm statement and not
      the pointer itself. It is incorrect to pass it in as an output
      constraint since the asm will never update the pointer.
      Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      f47a454d
    • S
      tracing, x86: fix fixup section to return to original code · e3944bfa
      Steven Rostedt 提交于
      Impact: fix to prevent a kernel crash on fault
      
      If for some reason the pointer to the parent function on the
      stack takes a fault, the fix up code will not return back to
      the original faulting code. This can lead to unpredictable
      results and perhaps even a kernel panic.
      
      A fault should not happen, but if it does, we should simply
      disable the tracer, warn, and continue running the kernel.
      It should not lead to a kernel crash.
      Signed-off-by: NSteven Rostedt <srostedt@redhat.com>
      e3944bfa
  3. 10 2月, 2009 15 次提交
  4. 09 2月, 2009 11 次提交