Merge branches 'x86/pat2' and 'x86/fpu'; commit 'v2.6.28' into x86/core
authorIngo Molnar <mingo@elte.hu>
Thu, 25 Dec 2008 10:50:41 +0000 (11:50 +0100)
committerIngo Molnar <mingo@elte.hu>
Thu, 25 Dec 2008 10:50:41 +0000 (11:50 +0100)
1  2  3  4 
Documentation/kernel-parameters.txt
arch/x86/kernel/traps.c

@@@@@ -220,14 -220,14 -220,14 -220,17 +220,17 @@@@@ and is between 256 and 4096 characters
                        Bits in debug_level correspond to a level in
                        ACPI_DEBUG_PRINT statements, e.g.,
                            ACPI_DEBUG_PRINT((ACPI_DB_INFO, ...
---                     See Documentation/acpi/debug.txt for more information
---                     about debug layers and levels.
+++                     The debug_level mask defaults to "info".  See
+++                     Documentation/acpi/debug.txt for more information about
+++                     debug layers and levels.
    
+++                     Enable processor driver info messages:
+++                         acpi.debug_layer=0x20000000
+++                     Enable PCI/PCI interrupt routing info messages:
+++                         acpi.debug_layer=0x400000
                        Enable AML "Debug" output, i.e., stores to the Debug
                        object while interpreting AML:
                            acpi.debug_layer=0xffffffff acpi.debug_level=0x2
---                     Enable PCI/PCI interrupt routing info messages:
---                         acpi.debug_layer=0x400000 acpi.debug_level=0x4
                        Enable all messages related to ACPI hardware:
                            acpi.debug_layer=0x2 acpi.debug_level=0xffffffff
    
                        when a NMI is triggered.
                        Format: [state][,regs][,debounce][,die]
    
 ---    nmi_watchdog=   [KNL,BUGS=X86-32] Debugging features for SMP kernels
 +++    nmi_watchdog=   [KNL,BUGS=X86-32,X86-64] Debugging features for SMP kernels
 +++                    Format: [panic,][num]
 +++                    Valid num: 0,1,2
 +++                    0 - turn nmi_watchdog off
 +++                    1 - use the IO-APIC timer for the NMI watchdog
 +++                    2 - use the local APIC for the NMI watchdog using
 +++                    a performance counter. Note: This will use one performance
 +++                    counter and the local APIC's performance vector.
 +++                    When panic is specified panic when an NMI watchdog timeout occurs.
 +++                    This is useful when you use a panic=... timeout and need the box
 +++                    quickly up again.
 +++                    Instead of 1 and 2 it is possible to use the following
 +++                    symbolic names: lapic and ioapic
 +++                    Example: nmi_watchdog=2 or nmi_watchdog=panic,lapic
    
        no387           [BUGS=X86-32] Tells the kernel to use the 387 maths
                        emulation library even if a 387 maths coprocessor
                nomsi           [MSI] If the PCI_MSI kernel config parameter is
                                enabled, this kernel boot option can be used to
                                disable the use of MSI interrupts system-wide.
 +++            noioapicquirk   [APIC] Disable all boot interrupt quirks.
 +++                            Safety option to keep boot IRQs enabled. This
 +++                            should never be necessary.
 +++            ioapicreroute   [APIC] Enable rerouting of boot IRQs to the
 +++                            primary IO-APIC for bridges that cannot disable
 +++                            boot IRQs. This fixes a source of spurious IRQs
 +++                            when the system masks IRQs.
 +++            noioapicreroute [APIC] Disable workaround that uses the
 +++                            boot IRQ equivalent of an IRQ that connects to
 +++                            a chipset where boot IRQs cannot be disabled.
 +++                            The opposite of ioapicreroute.
                biosirq         [X86-32] Use PCI BIOS calls to get the interrupt
                                routing table. These calls are known to be buggy
                                on several machines and they hang the machine
                        Format:
                        <io>,<irq>,<dma>,<dma2>,<sb_io>,<sb_irq>,<sb_dma>,<mpu_io>,<mpu_irq>
    
 +++    tsc=            Disable clocksource-must-verify flag for TSC.
 +++                    Format: <string>
 +++                    [x86] reliable: mark tsc clocksource as reliable, this
 +++                    disables clocksource verification at runtime.
 +++                    Used to enable high-resolution timer mode on older
 +++                    hardware, and in virtualized environment.
 +++
        turbografx.map[2|3]=    [HW,JOY]
                        TurboGraFX parallel port interface
                        Format:
diff --combined arch/x86/kernel/traps.c
@@@@@ -481,7 -481,11 -481,11 -481,11 +481,7 @@@@@ do_nmi(struct pt_regs *regs, long error
    {
        nmi_enter();
    
 ---#ifdef CONFIG_X86_32
 ---    { int cpu; cpu = smp_processor_id(); ++nmi_count(cpu); }
 ---#else
 ---    add_pda(__nmi_count, 1);
 ---#endif
 +++    inc_irq_stat(__nmi_count);
    
        if (!ignore_nmis)
                default_do_nmi(regs);
@@@@@ -660,7 -664,7 -664,7 -664,7 +660,7 @@@@@ void math_error(void __user *ip
    {
        struct task_struct *task;
        siginfo_t info;
 - -    unsigned short cwd, swd;
 + +    unsigned short cwd, swd, err;
    
        /*
         * Save the info for the exception handler and clear the error.
        task->thread.error_code = 0;
        info.si_signo = SIGFPE;
        info.si_errno = 0;
 - -    info.si_code = __SI_FAULT;
        info.si_addr = ip;
        /*
         * (~cwd & swd) will mask out exceptions that are not set to unmasked
         */
        cwd = get_fpu_cwd(task);
        swd = get_fpu_swd(task);
 - -    switch (swd & ~cwd & 0x3f) {
 - -    case 0x000: /* No unmasked exception */
 + +
 + +    err = swd & ~cwd & 0x3f;
 + +
-   #if CONFIG_X86_32
+   #ifdef CONFIG_X86_32
 + +    if (!err)
                return;
    #endif
 - -    default: /* Multiple exceptions */
 - -            break;
 - -    case 0x001: /* Invalid Op */
 + +
 + +    if (err & 0x001) {      /* Invalid op */
                /*
                 * swd & 0x240 == 0x040: Stack Underflow
                 * swd & 0x240 == 0x240: Stack Overflow
                 * User must clear the SF bit (0x40) if set
                 */
                info.si_code = FPE_FLTINV;
 - -            break;
 - -    case 0x002: /* Denormalize */
 - -    case 0x010: /* Underflow */
 - -            info.si_code = FPE_FLTUND;
 - -            break;
 - -    case 0x004: /* Zero Divide */
 + +    } else if (err & 0x004) { /* Divide by Zero */
                info.si_code = FPE_FLTDIV;
 - -            break;
 - -    case 0x008: /* Overflow */
 + +    } else if (err & 0x008) { /* Overflow */
                info.si_code = FPE_FLTOVF;
 - -            break;
 - -    case 0x020: /* Precision */
 + +    } else if (err & 0x012) { /* Denormal, Underflow */
 + +            info.si_code = FPE_FLTUND;
 + +    } else if (err & 0x020) { /* Precision */
                info.si_code = FPE_FLTRES;
 - -            break;
 + +    } else {
 + +            info.si_code = __SI_FAULT|SI_KERNEL; /* WTF? */
        }
        force_sig_info(SIGFPE, &info, task);
    }