From: Ingo Molnar Date: Tue, 23 Dec 2008 15:27:23 +0000 (+0100) Subject: Merge branches 'x86/apic', 'x86/cleanups', 'x86/cpufeature', 'x86/crashdump', 'x86... X-Git-Tag: v2.6.29-rc1~587^2~4 X-Git-Url: http://www.pilppa.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=fa623d1b0222adbe8f822e53c08003b9679a410c;p=linux-2.6-omap-h63xx.git Merge branches 'x86/apic', 'x86/cleanups', 'x86/cpufeature', 'x86/crashdump', 'x86/debug', 'x86/defconfig', 'x86/detect-hyper', 'x86/doc', 'x86/dumpstack', 'x86/early-printk', 'x86/fpu', 'x86/idle', 'x86/io', 'x86/memory-corruption-check', 'x86/microcode', 'x86/mm', 'x86/mtrr', 'x86/nmi-watchdog', 'x86/pat2', 'x86/pci-ioapic-boot-irq-quirks', 'x86/ptrace', 'x86/quirks', 'x86/reboot', 'x86/setup-memory', 'x86/signal', 'x86/sparse-fixes', 'x86/time', 'x86/uv' and 'x86/xen' into x86/core --- fa623d1b0222adbe8f822e53c08003b9679a410c diff --cc Documentation/kernel-parameters.txt index e0f346d201e,e0f346d201e,e0f346d201e,e0f346d201e,c86c0745971,e0f346d201e,e0f346d201e,dc6b06f67fc,e0f346d201e,53ba7c7d82b,e0f346d201e,e0f346d201e,e0f346d201e,e0f346d201e,e0f346d201e,e0f346d201e,e0f346d201e,343e0f0f84b,6246220ac91,e0f346d201e,63bac584f9c,c86c0745971,e0f346d201e,c86c0745971,e0f346d201e,343e0f0f84b,e0f346d201e,e0f346d201e,e0f346d201e,e0f346d201e..d5418d52891 --- a/Documentation/kernel-parameters.txt +++ b/Documentation/kernel-parameters.txt @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -198,50 -198,50 -198,50 -198,50 -198,67 -198,50 -198,50 -198,67 -198,50 -198,40 -198,50 -198,50 -198,50 -198,50 -198,50 -198,50 -198,50 -198,67 -198,67 -198,50 -198,67 -198,67 -198,50 -198,67 -198,50 -198,67 -198,50 -198,50 -198,50 -198,50 +198,50 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ and is between 256 and 4096 characters that require a timer override, but don't have HPET - - - -- -- - - acpi.debug_layer= [HW,ACPI] - -- - - Format: - -- - - Each bit of the indicates an ACPI debug layer, - -- - - 1: enable, 0: disable. It is useful for boot time - -- - - debugging. After system has booted up, it can be set - -- - - via /sys/module/acpi/parameters/debug_layer. - -- - - CONFIG_ACPI_DEBUG must be enabled for this to produce any output. - -- - - Available bits (add the numbers together) to enable debug output - -- - - for specific parts of the ACPI subsystem: - -- - - 0x01 utilities 0x02 hardware 0x04 events 0x08 tables - -- - - 0x10 namespace 0x20 parser 0x40 dispatcher - -- - - 0x80 executer 0x100 resources 0x200 acpica debugger - -- - - 0x400 os services 0x800 acpica disassembler. - -- - - The number can be in decimal or prefixed with 0x in hex. - -- - - Warning: Many of these options can produce a lot of - -- - - output and make your system unusable. Be very careful. - -- - - - -- - - acpi.debug_level= [HW,ACPI] + + + ++ ++ + + acpi_backlight= [HW,ACPI] + + + ++ ++ + + acpi_backlight=vendor + + + ++ ++ + + acpi_backlight=video + + + ++ ++ + + If set to vendor, prefer vendor specific driver + + + ++ ++ + + (e.g. thinkpad_acpi, sony_acpi, etc.) instead + + + ++ ++ + + of the ACPI video.ko driver. + + + ++ ++ + + + + + ++ ++ + + acpi_display_output= [HW,ACPI] + + + ++ ++ + + acpi_display_output=vendor + + + ++ ++ + + acpi_display_output=video + + + ++ ++ + + See above. + + + ++ ++ + + + + + ++ ++ + + acpi.debug_layer= [HW,ACPI,ACPI_DEBUG] + + + ++ ++ + + acpi.debug_level= [HW,ACPI,ACPI_DEBUG] Format: - - - - Each bit of the indicates an ACPI debug layer, - Each bit of the indicates an ACPI debug level, - - - - - 1: enable, 0: disable. It is useful for boot time - - - - - debugging. After system has booted up, it can be set - - - - via /sys/module/acpi/parameters/debug_layer. - via /sys/module/acpi/parameters/debug_level. - - - - - CONFIG_ACPI_DEBUG must be enabled for this to produce any output. - - - - Available bits (add the numbers together) to enable debug output - - - - for specific parts of the ACPI subsystem: - - - - 0x01 utilities 0x02 hardware 0x04 events 0x08 tables - - - - 0x10 namespace 0x20 parser 0x40 dispatcher - - - - 0x80 executer 0x100 resources 0x200 acpica debugger - - - - 0x400 os services 0x800 acpica disassembler. - Available bits (add the numbers together) to enable different - debug output levels of the ACPI subsystem: - 0x01 error 0x02 warn 0x04 init 0x08 debug object - 0x10 info 0x20 init names 0x40 parse 0x80 load - 0x100 dispatch 0x200 execute 0x400 names 0x800 operation region - 0x1000 bfield 0x2000 tables 0x4000 values 0x8000 objects - 0x10000 resources 0x20000 user requests 0x40000 package. - - - - - The number can be in decimal or prefixed with 0x in hex. - - - - - Warning: Many of these options can produce a lot of - - - - - output and make your system unusable. Be very careful. - - - - - - - - acpi.debug_level= [HW,ACPI] - - - - Format: - - -- -- - - Each bit of the indicates an ACPI debug level, - - -- -- - - which corresponds to the level in an ACPI_DEBUG_PRINT - - -- -- - - statement. After system has booted up, this mask - - -- -- - - can be set via /sys/module/acpi/parameters/debug_level. - - -- -- - - - - -- -- - - CONFIG_ACPI_DEBUG must be enabled for this to produce - - -- -- - - any output. The number can be in decimal or prefixed - - -- -- - - with 0x in hex. Some of these options produce so much - - -- -- - - output that the system is unusable. - - -- -- - - - - -- -- - - The following global components are defined by the - - -- -- - - ACPI CA: - - -- -- - - 0x01 error - - -- -- - - 0x02 warn - - -- -- - - 0x04 init - - -- -- - - 0x08 debug object - - -- -- - - 0x10 info - - -- -- - - 0x20 init names - - -- -- - - 0x40 parse - - -- -- - - 0x80 load - - -- -- - - 0x100 dispatch - - -- -- - - 0x200 execute - - -- -- - - 0x400 names - - -- -- - - 0x800 operation region - - -- -- - - 0x1000 bfield - - -- -- - - 0x2000 tables - - -- -- - - 0x4000 values - - -- -- - - 0x8000 objects - - -- -- - - 0x10000 resources - - -- -- - - 0x20000 user requests - - -- -- - - 0x40000 package - - -- -- - - The number can be in decimal or prefixed with 0x in hex. - - -- -- - - Warning: Many of these options can produce a lot of - - -- -- - - output and make your system unusable. Be very careful. + + + ++ ++ + + CONFIG_ACPI_DEBUG must be enabled to produce any ACPI + + + ++ ++ + + debug output. Bits in debug_layer correspond to a + + + ++ ++ + + _COMPONENT in an ACPI source file, e.g., + + + ++ ++ + + #define _COMPONENT ACPI_PCI_COMPONENT + + + ++ ++ + + 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. + + + ++ ++ + + + + + ++ ++ + + 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 + + + ++ ++ + + + + + ++ ++ + + Some values produce so much output that the system is + + + ++ ++ + + unusable. The "log_buf_len" parameter may be useful + + + ++ ++ + + if you need to capture more output. + + acpi.power_nocheck= [HW,ACPI] + Format: 1/0 enable/disable the check of power state. + On some bogus BIOS the _PSC object/_STA object of + power resource can't return the correct device power + state. In such case it is unneccessary to check its + power state again in power transition. + 1 : disable the power state check acpi_pm_good [X86-32,X86-64] Override the pmtimer bug detection: force the kernel @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -1710,13 -1710,13 -1710,13 -1710,13 -1722,13 -1710,13 -1710,13 -1722,13 -1710,13 -1695,13 -1710,13 -1710,13 -1710,13 -1710,13 -1710,13 -1710,13 -1710,13 -1722,13 -1735,13 -1710,13 -1733,13 -1722,13 -1710,13 -1722,13 -1710,13 -1722,13 -1710,13 -1710,13 -1710,13 -1710,13 +1734,13 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ See arch/parisc/kernel/pdc_chassis.c pf. [PARIDE] - - - -- -- - - See Documentation/paride.txt. + + + ++ ++ + + See Documentation/blockdev/paride.txt. pg. [PARIDE] - - - -- -- - - See Documentation/paride.txt. + + + ++ ++ + + See Documentation/blockdev/paride.txt. pirq= [SMP,APIC] Manual mp-table setup - -- - - See Documentation/i386/IO-APIC.txt. + ++ + + See Documentation/x86/i386/IO-APIC.txt. plip= [PPT,NET] Parallel port network link Format: { parport | timid | 0 } diff --cc arch/x86/Kconfig index ac22bb7719f,ac22bb7719f,d4d4cb7629e,ac22bb7719f,93224b56918,ab98cca84e1,ac22bb7719f,6f20718d315,e795b5ba25b,5b9b12321ad,ac22bb7719f,ac22bb7719f,ac22bb7719f,a7d50f5d118,ac22bb7719f,ac22bb7719f,cb6a58b7712,350bee1d54d,d11d7b51319,ac22bb7719f,f4ed47db79e,4cf0ab13d18,705e72e954b,ebcad15ccf3,ac22bb7719f,350bee1d54d,ac22bb7719f,ac22bb7719f,ac22bb7719f,ac22bb7719f..1cbec0269d3 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -956,11 -956,11 -948,11 -956,11 -953,11 -960,11 -956,11 -953,11 -956,11 -946,11 -956,11 -956,11 -956,11 -958,11 -956,11 -956,11 -956,20 -949,11 -949,11 -956,11 -973,11 -953,11 -952,11 -953,11 -956,11 -949,11 -956,11 -956,11 -956,11 -956,11 +974,20 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ config X86_PA config ARCH_PHYS_ADDR_T_64BIT def_bool X86_64 || X86_PAE ++++++++++++++++ +++++++++++++config DIRECT_GBPAGES ++++++++++++++++ +++++++++++++ bool "Enable 1GB pages for kernel pagetables" if EMBEDDED ++++++++++++++++ +++++++++++++ default y ++++++++++++++++ +++++++++++++ depends on X86_64 ++++++++++++++++ +++++++++++++ help ++++++++++++++++ +++++++++++++ Allow the kernel linear mapping to use 1GB pages on CPUs that ++++++++++++++++ +++++++++++++ support it. This can improve the kernel's performance a tiny bit by ++++++++++++++++ +++++++++++++ reducing TLB pressure. If in doubt, say "Y". ++++++++++++++++ +++++++++++++ # Common NUMA Features config NUMA -------- --------------------- bool "Numa Memory Allocation and Scheduler Support (EXPERIMENTAL)" ++++++++ +++++++++++++++++++++ bool "Numa Memory Allocation and Scheduler Support" depends on SMP - depends on X86_64 || (X86_32 && HIGHMEM64G && (X86_NUMAQ || X86_BIGSMP || X86_SUMMIT && ACPI) && BROKEN) + depends on X86_64 || (X86_32 && HIGHMEM64G && (X86_NUMAQ || X86_BIGSMP || X86_SUMMIT && ACPI) && EXPERIMENTAL) default n if X86_PC default y if (X86_NUMAQ || X86_SUMMIT || X86_BIGSMP) help diff --cc arch/x86/kernel/Makefile index b62a7667828,b62a7667828,b62a7667828,b62a7667828,e489ff9cb3e,943fe6026c6,e489ff9cb3e,e489ff9cb3e,b62a7667828,db3216a9d2b,b62a7667828,b62a7667828,b62a7667828,e489ff9cb3e,b2077d3fe97,b62a7667828,b62a7667828,d7e5a58ee22,e489ff9cb3e,b62a7667828,d7e5a58ee22,e489ff9cb3e,b62a7667828,e489ff9cb3e,b62a7667828,ef28c210ebf,e489ff9cb3e,b62a7667828,b62a7667828,b62a7667828..1f208aaee78 --- a/arch/x86/kernel/Makefile +++ b/arch/x86/kernel/Makefile @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -11,7 -11,7 -11,7 -11,7 -11,7 -11,8 -11,7 -11,7 -11,7 -11,6 -11,7 -11,7 -11,7 -11,7 -11,7 -11,7 -11,7 -11,6 -11,7 -11,7 -11,6 -11,7 -11,7 -11,7 -11,7 -11,6 -11,7 -11,7 -11,7 -11,7 +11,8 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ ifdef CONFIG_FUNCTION_TRACE CFLAGS_REMOVE_tsc.o = -pg CFLAGS_REMOVE_rtc.o = -pg CFLAGS_REMOVE_paravirt-spinlocks.o = -pg + + + + CFLAGS_REMOVE_ftrace.o = -pg +++++ ++++++++++++++++++++++++CFLAGS_REMOVE_early_printk.o = -pg endif # @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -23,9 -23,9 -23,9 -23,9 -23,9 -24,9 -23,9 -23,9 -23,9 -22,9 -23,9 -23,9 -23,9 -23,9 -23,9 -23,9 -23,9 -22,9 -23,9 -23,9 -22,9 -23,9 -23,9 -23,9 -23,9 -22,9 -23,9 -23,9 -23,9 -23,9 +24,9 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ CFLAGS_vsyscall_64.o := $(PROFILING) -g CFLAGS_hpet.o := $(nostackp) CFLAGS_tsc.o := $(nostackp) ------------------------- ----obj-y := process_$(BITS).o signal_$(BITS).o entry_$(BITS).o +++++++++++++++++++++++++ ++++obj-y := process_$(BITS).o signal.o entry_$(BITS).o obj-y += traps.o irq.o irq_$(BITS).o dumpstack_$(BITS).o --------- --------------------obj-y += time_$(BITS).o ioport.o ldt.o +++++++++ ++++++++++++++++++++obj-y += time_$(BITS).o ioport.o ldt.o dumpstack.o obj-y += setup.o i8259.o irqinit_$(BITS).o setup_percpu.o obj-$(CONFIG_X86_VISWS) += visws_quirks.o obj-$(CONFIG_X86_32) += probe_roms_32.o diff --cc arch/x86/kernel/ds.c index a2d1176c38e,a2d1176c38e,a2d1176c38e,a2d1176c38e,2b69994fd3a,d1a121443bd,d1a121443bd,2b69994fd3a,a2d1176c38e,2b69994fd3a,a2d1176c38e,a2d1176c38e,a2d1176c38e,d1a121443bd,d1a121443bd,a2d1176c38e,a2d1176c38e,2b69994fd3a,2b69994fd3a,a2d1176c38e,2b69994fd3a,c570252905a,a2d1176c38e,2b69994fd3a,a2d1176c38e,2b69994fd3a,d1a121443bd,a2d1176c38e,a2d1176c38e,a2d1176c38e..d6938d9351c --- a/arch/x86/kernel/ds.c +++ b/arch/x86/kernel/ds.c @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -231,12 -231,12 -231,12 -231,12 -234,12 -234,16 -234,16 -234,12 -231,12 -234,12 -231,12 -231,12 -231,12 -234,16 -234,16 -231,12 -231,12 -234,12 -234,12 -231,12 -234,12 -234,12 -231,12 -234,12 -231,12 -234,12 -234,16 -231,12 -231,12 -231,12 +231,12 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ static inline struct ds_context *ds_all struct ds_context **p_context = (task ? &task->thread.ds_ctx : &this_system_context); struct ds_context *context = *p_context; ++++ + ++ ++ ++ + ++ unsigned long irq; if (!context) { -- -- - spin_unlock(&ds_lock); -- -- - context = kzalloc(sizeof(*context), GFP_KERNEL); ---- - -- -- -- - -- -- -- - if (!context) { -- -- - spin_lock(&ds_lock); ++ ++ + if (!context) return NULL; -- -- - } context->ds = kzalloc(ds_cfg.sizeof_ds, GFP_KERNEL); if (!context->ds) { @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -244,27 -244,27 -244,27 -244,27 -247,18 -251,30 -251,30 -247,18 -244,27 -247,18 -244,27 -244,27 -244,27 -251,30 -251,30 -244,27 -244,27 -247,18 -247,18 -244,27 -247,18 -247,18 -244,27 -247,18 -244,27 -247,18 -251,30 -244,27 -244,27 -244,27 +244,27 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ return NULL; } - - - -- -- - - *p_context = context; -- -- - spin_lock(&ds_lock); -- -- - /* -- -- - * Check for race - another CPU could have allocated -- -- - * it meanwhile: -- -- - */ ++++ + ++ ++ ++ + ++ spin_lock_irqsave(&ds_lock, irq); ++ ++ + - - - -- -- - - context->this = p_context; - - - -- -- - - context->task = task; + + + ++ ++ + + if (*p_context) { + + + ++ ++ + + kfree(context->ds); + + + ++ ++ + + kfree(context); -- -- - return *p_context; -- -- - } + - - - -- - - - if (task) - - - -- - - - set_tsk_thread_flag(task, TIF_DS_AREA_MSR); -- -- - *p_context = context; ++++ + ++ ++ ++ + ++ context = *p_context; ++++ + ++ ++ ++ + ++ } else { ++++ + ++ ++ ++ + ++ *p_context = context; - - - -- - - - if (!task || (task == current)) - - - -- - - - wrmsr(MSR_IA32_DS_AREA, (unsigned long)context->ds, 0); -- -- - context->this = p_context; -- -- - context->task = task; - if (task) - set_tsk_thread_flag(task, TIF_DS_AREA_MSR); ++++ + ++ ++ ++ + ++ context->this = p_context; ++++ + ++ ++ ++ + ++ context->task = task; - - - -- - - - get_tracer(task); -- -- - if (task) -- -- - set_tsk_thread_flag(task, TIF_DS_AREA_MSR); - if (!task || (task == current)) - wrmsr(MSR_IA32_DS_AREA, (unsigned long)context->ds, 0); ++++ + ++ ++ ++ + ++ if (task) ++++ + ++ ++ ++ + ++ set_tsk_thread_flag(task, TIF_DS_AREA_MSR); + + + ++ + + + -- -- - if (!task || (task == current)) -- -- - wrmsr(MSR_IA32_DS_AREA, (unsigned long)context->ds, 0); -- -- - -- -- - - get_tracer(task); ++++ + ++ ++ ++ + ++ if (!task || (task == current)) ++++ + ++ ++ ++ + ++ wrmsrl(MSR_IA32_DS_AREA, ++++ + ++ ++ ++ + ++ (unsigned long)context->ds); ++++ + ++ ++ ++ + ++ } ++++ + ++ ++ ++ + ++ spin_unlock_irqrestore(&ds_lock, irq); } context->count++; @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -391,27 -391,27 -391,27 -391,27 -382,25 -398,26 -398,26 -382,25 -391,27 -382,25 -391,27 -391,27 -391,27 -398,26 -398,26 -391,27 -391,27 -382,25 -382,25 -391,27 -382,25 -382,25 -391,27 -382,25 -391,27 -382,25 -398,26 -391,27 -391,27 -391,27 +391,27 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ static int ds_request(struct task_struc return -EOPNOTSUPP; ---- - -- -- -- - -- spin_lock(&ds_lock); - - - -- -- - - - - - -- -- - - if (!check_tracer(task)) - - - -- -- - - return -EPERM; ---- - -- -- -- - -- ---- - -- -- -- - -- error = -ENOMEM; context = ds_alloc_context(task); if (!context) -- -- - goto out_unlock; ++++ + ++ ++ ++ + ++ return -ENOMEM; ++++ + ++ ++ ++ + ++ ++++ + ++ ++ ++ + ++ spin_lock_irqsave(&ds_lock, irq); + + + ++ ++ + + + + + ++ ++ + + error = -EPERM; + + + ++ ++ + + if (!check_tracer(task)) goto out_unlock; ++++ + ++ ++ ++ + ++ get_tracer(task); ++++ + ++ ++ ++ + ++ error = -EALREADY; if (context->owner[qual] == current) ---- - -- -- -- - -- goto out_unlock; ++++ + ++ ++ ++ + ++ goto out_put_tracer; error = -EPERM; if (context->owner[qual] != NULL) ---- - -- -- -- - -- goto out_unlock; ++++ + ++ ++ ++ + ++ goto out_put_tracer; context->owner[qual] = current; ---- - -- -- -- - -- spin_unlock(&ds_lock); ++++ + ++ ++ ++ + ++ spin_unlock_irqrestore(&ds_lock, irq); error = -ENOMEM; diff --cc arch/x86/kernel/entry_64.S index b86f332c96a,b86f332c96a,54927784bab,b86f332c96a,b86f332c96a,4a16bf31c78,b86f332c96a,b86f332c96a,b86f332c96a,09e7145484c,b86f332c96a,b86f332c96a,b86f332c96a,b86f332c96a,b86f332c96a,b86f332c96a,b86f332c96a,09e7145484c,b86f332c96a,b86f332c96a,09e7145484c,b86f332c96a,b86f332c96a,b86f332c96a,b86f332c96a,09e7145484c,b86f332c96a,b86f332c96a,b86f332c96a,b86f332c96a..42571baaca3 --- a/arch/x86/kernel/entry_64.S +++ b/arch/x86/kernel/entry_64.S @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -255,8 -255,8 -255,8 -255,8 -255,8 -255,9 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 -255,8 +255,9 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ ENTRY(ret_from_fork call schedule_tail GET_THREAD_INFO(%rcx) testl $(_TIF_SYSCALL_TRACE|_TIF_SYSCALL_AUDIT),TI_flags(%rcx) +++++ ++++++++++++++++++++++++ CFI_REMEMBER_STATE jnz rff_trace -- ---------------------------rff_action: ++ +++++++++++++++++++++++++++rff_action: RESTORE_REST testl $3,CS-ARGOFFSET(%rsp) # from kernel_thread? je int_ret_from_sys_call diff --cc arch/x86/kernel/reboot.c index cc5a2545dd4,cc5a2545dd4,cc5a2545dd4,cc5a2545dd4,c3cd512484e,cc5a2545dd4,cc5a2545dd4,f4c93f1cfc1,cc5a2545dd4,f4c93f1cfc1,cc5a2545dd4,cc5a2545dd4,cc5a2545dd4,cc5a2545dd4,724adfc63cb,cc5a2545dd4,cc5a2545dd4,f4c93f1cfc1,f4c93f1cfc1,cc5a2545dd4,f4c93f1cfc1,724adfc63cb,cc5a2545dd4,bb387ab0eea,cc5a2545dd4,f4c93f1cfc1,cc5a2545dd4,cc5a2545dd4,cc5a2545dd4,cc5a2545dd4..61f718df6ee --- a/arch/x86/kernel/reboot.c +++ b/arch/x86/kernel/reboot.c @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -404,12 -404,12 -404,12 -404,12 -398,12 -404,12 -404,12 -399,12 -404,12 -399,12 -404,12 -404,12 -404,12 -404,12 -395,12 -404,12 -404,12 -399,12 -399,12 -404,12 -399,12 -395,12 -404,12 -400,27 -404,12 -399,12 -404,12 -404,12 -404,12 -404,12 +412,27 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ static void native_machine_emergency_re reboot_type = BOOT_KBD; break; ----------------------- ------ case BOOT_EFI: if (efi_enabled) ----------------------- ------ efi.reset_system(reboot_mode ? EFI_RESET_WARM : EFI_RESET_COLD, +++++++++++++++++++++++ ++++++ efi.reset_system(reboot_mode ? +++++++++++++++++++++++ ++++++ EFI_RESET_WARM : +++++++++++++++++++++++ ++++++ EFI_RESET_COLD, EFI_SUCCESS, 0, NULL); +++++++++++++++++++++++ ++++++ reboot_type = BOOT_KBD; +++++++++++++++++++++++ ++++++ break; + + ++ + + +++++++++++++++++++++++ ++++++ case BOOT_CF9: +++++++++++++++++++++++ ++++++ port_cf9_safe = true; +++++++++++++++++++++++ ++++++ /* fall through */ +++++++ + +++++++ + ++ + ++++ +++++++++++++++++++++++ ++++++ case BOOT_CF9_COND: +++++++++++++++++++++++ ++++++ if (port_cf9_safe) { +++++++++++++++++++++++ ++++++ u8 cf9 = inb(0xcf9) & ~6; +++++++++++++++++++++++ ++++++ outb(cf9|2, 0xcf9); /* Request hard reset */ +++++++++++++++++++++++ ++++++ udelay(50); +++++++++++++++++++++++ ++++++ outb(cf9|6, 0xcf9); /* Actually do the reset */ +++++++++++++++++++++++ ++++++ udelay(50); +++++++++++++++++++++++ ++++++ } reboot_type = BOOT_KBD; break; } diff --cc arch/x86/kernel/setup.c index bdec76e5559,bdec76e5559,81f5d22747a,9d5674f7b6c,0fa6790c1dd,9d5674f7b6c,9d5674f7b6c,f44dadfb32c,9d5674f7b6c,0fa6790c1dd,9d5674f7b6c,bdec76e5559,9d5674f7b6c,9d5674f7b6c,13a5f592ac2,9d5674f7b6c,9d5674f7b6c,0fa6790c1dd,0fa6790c1dd,bdec76e5559,0fa6790c1dd,0fa6790c1dd,f5096a6bf4e,0fa6790c1dd,9d5674f7b6c,0fa6790c1dd,9d5674f7b6c,9d5674f7b6c,9d5674f7b6c,bdec76e5559..a3122382859 --- a/arch/x86/kernel/setup.c +++ b/arch/x86/kernel/setup.c @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ -583,161 -583,161 -584,161 -583,161 -583,161 -583,161 -583,161 -584,161 -583,161 -583,161 -583,161 -583,161 -583,161 -583,161 -583,11 -583,161 -583,161 -583,161 -583,161 -583,161 -583,161 -583,161 -583,174 -583,161 -583,161 -583,161 -583,161 -583,161 -583,161 -583,161 +585,24 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ static int __init setup_elfcorehdr(cha early_param("elfcorehdr", setup_elfcorehdr); #endif ---------------------- -------static struct x86_quirks default_x86_quirks __initdata; -------------- ------- ------- -------------- ------- -------struct x86_quirks *x86_quirks __initdata = &default_x86_quirks; -------------- ------- ------- -------------- ------- -------/* -------------- ------- ------- * Some BIOSes seem to corrupt the low 64k of memory during events -------------- ------- ------- * like suspend/resume and unplugging an HDMI cable. Reserve all -------------- ------- ------- * remaining free memory in that area and fill it with a distinct -------------- ------- ------- * pattern. -------------- ------- ------- */ -------------- ------- -------#ifdef CONFIG_X86_CHECK_BIOS_CORRUPTION -------------- ------- -------#define MAX_SCAN_AREAS 8 -------------- ------- ------- -------------- ------- -------static int __read_mostly memory_corruption_check = -1; -------------- ------- ------- -------------- ------- -------static unsigned __read_mostly corruption_check_size = 64*1024; -------------- ------- -------static unsigned __read_mostly corruption_check_period = 60; /* seconds */ -------------- ------- ------- -------------- ------- -------static struct e820entry scan_areas[MAX_SCAN_AREAS]; -------------- ------- -------static int num_scan_areas; -------------- ------- ------- -------------- ------- ------- -------------- ------- -------static int set_corruption_check(char *arg) ----- --- -- ---- -- ------ { ----- --- -- ---- -- ------ char *end; ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ memory_corruption_check = simple_strtol(arg, &end, 10); ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ return (*end == 0) ? 0 : -EINVAL; ----- --- -- ---- -- ------ } ----- --- -- ---- -- ------ early_param("memory_corruption_check", set_corruption_check); ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ static int set_corruption_check_period(char *arg) ----- --- -- ---- -- ------ { ----- --- -- ---- -- ------ char *end; ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ corruption_check_period = simple_strtoul(arg, &end, 10); ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ return (*end == 0) ? 0 : -EINVAL; ----- --- -- ---- -- ------ } ----- --- -- ---- -- ------ early_param("memory_corruption_check_period", set_corruption_check_period); ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ static int set_corruption_check_size(char *arg) ----- --- -- ---- -- ------ { ----- --- -- ---- -- ------ char *end; ----- --- -- ---- -- ------ unsigned size; ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ size = memparse(arg, &end); ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ if (*end == '\0') ----- --- -- ---- -- ------ corruption_check_size = size; ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ return (size == corruption_check_size) ? 0 : -EINVAL; ----- --- -- ---- -- ------ } ----- --- -- ---- -- ------ early_param("memory_corruption_check_size", set_corruption_check_size); ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ static void __init setup_bios_corruption_check(void) ++++++++++++++++++++++ +++++++static int __init default_update_genapic(void) + { -- - - - - char *end; -- - - - - -- - - - - memory_corruption_check = simple_strtol(arg, &end, 10); -- - - - - -- - - - - return (*end == 0) ? 0 : -EINVAL; -- - - - -} -- - - - -early_param("memory_corruption_check", set_corruption_check); -- - - - - -- - - - -static int set_corruption_check_period(char *arg) -- - - - -{ -- - - - - char *end; -- - - - - -- - - - - corruption_check_period = simple_strtoul(arg, &end, 10); -- - - - - -- - - - - return (*end == 0) ? 0 : -EINVAL; -- - - - -} -- - - - -early_param("memory_corruption_check_period", set_corruption_check_period); -- - - - - -- - - - -static int set_corruption_check_size(char *arg) -- - - - -{ -- - - - - char *end; -- - - - - unsigned size; -- - - - - -- - - - - size = memparse(arg, &end); -- - - - - -- - - - - if (*end == '\0') -- - - - - corruption_check_size = size; -- - - - - -- - - - - return (size == corruption_check_size) ? 0 : -EINVAL; -- - - - -} -- - - - -early_param("memory_corruption_check_size", set_corruption_check_size); -- - - - - -- - - - - -- - - - -static void __init setup_bios_corruption_check(void) -- - - - -{ -------------- ------- ------- u64 addr = PAGE_SIZE; /* assume first page is reserved anyway */ -------------- ------- ------- -------------- ------- ------- if (memory_corruption_check == -1) { -------------- ------- ------- memory_corruption_check = -------------- ------- -------#ifdef CONFIG_X86_BOOTPARAM_MEMORY_CORRUPTION_CHECK -------------- ------- ------- 1 -------------- ------- -------#else -------------- ------- ------- 0 ++++++++++++++++++++++ +++++++#ifdef CONFIG_X86_SMP ++++++++++++++++++++++ +++++++# if defined(CONFIG_X86_GENERICARCH) || defined(CONFIG_X86_64) ++++++++++++++++++++++ +++++++ genapic->wakeup_cpu = wakeup_secondary_cpu_via_init; ++++++++++++++++++++++ +++++++# endif + #endif -------------- ------- ------- ; -------------- ------- ------- } ------- ------ ------- ------- ------- ------ ------- ------- if (corruption_check_size == 0) ------- ------ ------- ------- memory_corruption_check = 0; ------- ------ ------- ------- ------- ------ ------- ------- if (!memory_corruption_check) ------- ------ ------- ------- return; ------- ------ ------- ------- ------- ------ ------- ------- corruption_check_size = round_up(corruption_check_size, PAGE_SIZE); ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ while(addr < corruption_check_size && num_scan_areas < MAX_SCAN_AREAS) { ----- --- -- ---- -- ------ u64 size; ----- --- -- ---- -- ------ addr = find_e820_area_size(addr, &size, PAGE_SIZE); ----- --- -- ---- -- ------ ----- --- -- ---- -- ------ if (addr == 0) ----- --- -- ---- -- ------ break; + - if (corruption_check_size == 0) - memory_corruption_check = 0; - - if (!memory_corruption_check) - return; - - corruption_check_size = round_up(corruption_check_size, PAGE_SIZE); - -- - - - - while(addr < corruption_check_size && num_scan_areas < MAX_SCAN_AREAS) { -- - - - - u64 size; -- - - - - addr = find_e820_area_size(addr, &size, PAGE_SIZE); -- - - - - -- - - - - if (addr == 0) -- - - - - break; -- - - - - -------------- ------- ------- if ((addr + size) > corruption_check_size) -------------- ------- ------- size = corruption_check_size - addr; -------------- ------- ------- -------------- ------- ------- if (size == 0) -------------- ------- ------- break; -------------- ------- ------- -------------- ------- ------- e820_update_range(addr, size, E820_RAM, E820_RESERVED); -------------- ------- ------- scan_areas[num_scan_areas].addr = addr; -------------- ------- ------- scan_areas[num_scan_areas].size = size; -------------- ------- ------- num_scan_areas++; -------------- ------- ------- -------------- ------- ------- /* Assume we've already mapped this early memory */ -------------- ------- ------- memset(__va(addr), 0, size); -------------- ------- ------- -------------- ------- ------- addr += size; -------------- ------- ------- } -------------- ------- ------- -------------- ------- ------- printk(KERN_INFO "Scanning %d areas for low memory corruption\n", -------------- ------- ------- num_scan_areas); -------------- ------- ------- update_e820(); -------------- ------- -------} -------------- ------- ------- -------------- ------- -------static struct timer_list periodic_check_timer; -------------- ------- ------- -------------- ------- -------void check_for_bios_corruption(void) -------------- ------- -------{ -------------- ------- ------- int i; -------------- ------- ------- int corruption = 0; -------------- ------- ------- -------------- ------- ------- if (!memory_corruption_check) -------------- ------- ------- return; -------------- ------- ------- -------------- ------- ------- for(i = 0; i < num_scan_areas; i++) { -------------- ------- ------- unsigned long *addr = __va(scan_areas[i].addr); -------------- ------- ------- unsigned long size = scan_areas[i].size; -------------- ------- ------- -------------- ------- ------- for(; size; addr++, size -= sizeof(unsigned long)) { -------------- ------- ------- if (!*addr) -------------- ------- ------- continue; -------------- ------- ------- printk(KERN_ERR "Corrupted low memory at %p (%lx phys) = %08lx\n", -------------- ------- ------- addr, __pa(addr), *addr); -------------- ------- ------- corruption = 1; -------------- ------- ------- *addr = 0; -------------- ------- ------- } -------------- ------- ------- } -------------- ------- ------- -------------- ------- ------- WARN(corruption, KERN_ERR "Memory corruption detected in low memory\n"); -------------- ------- -------} -------------- ------- ------- -------------- ------- -------static void periodic_check_for_corruption(unsigned long data) -------------- ------- -------{ -------------- ------- ------- check_for_bios_corruption(); -------------- ------- ------- mod_timer(&periodic_check_timer, round_jiffies(jiffies + corruption_check_period*HZ)); ++++++++++++++++++++++ +++++++ return 0; + } + -------------- ------- -------void start_periodic_check_for_corruption(void) -------------- ------- -------{ -------------- ------- ------- if (!memory_corruption_check || corruption_check_period == 0) -------------- ------- ------- return; -------------- ------- ------- -------------- ------- ------- printk(KERN_INFO "Scanning for low memory corruption every %d seconds\n", -------------- ------- ------- corruption_check_period); ++++++++++++++++++++++ +++++++static struct x86_quirks default_x86_quirks __initdata = { ++++++++++++++++++++++ +++++++ .update_genapic = default_update_genapic, ++++++++++++++++++++++ +++++++}; -------------- ------- ------- init_timer(&periodic_check_timer); -------------- ------- ------- periodic_check_timer.function = &periodic_check_for_corruption; -------------- ------- ------- periodic_check_for_corruption(0); -------------- ------- -------} -------------- ------- -------#endif ++++++++++++++ +++++++ +++++++struct x86_quirks *x86_quirks __initdata = &default_x86_quirks; - /* - * Some BIOSes seem to corrupt the low 64k of memory during events - * like suspend/resume and unplugging an HDMI cable. Reserve all - * remaining free memory in that area and fill it with a distinct - * pattern. - */ - #ifdef CONFIG_X86_CHECK_BIOS_CORRUPTION - #define MAX_SCAN_AREAS 8 - - static int __read_mostly memory_corruption_check = -1; - - static unsigned __read_mostly corruption_check_size = 64*1024; - static unsigned __read_mostly corruption_check_period = 60; /* seconds */ - - static struct e820entry scan_areas[MAX_SCAN_AREAS]; - static int num_scan_areas; - - - static int set_corruption_check(char *arg) - { - char *end; - - memory_corruption_check = simple_strtol(arg, &end, 10); - - return (*end == 0) ? 0 : -EINVAL; - } - early_param("memory_corruption_check", set_corruption_check); - - static int set_corruption_check_period(char *arg) - { - char *end; - - corruption_check_period = simple_strtoul(arg, &end, 10); - - return (*end == 0) ? 0 : -EINVAL; - } - early_param("memory_corruption_check_period", set_corruption_check_period); - - static int set_corruption_check_size(char *arg) - { - char *end; - unsigned size; - - size = memparse(arg, &end); - - if (*end == '\0') - corruption_check_size = size; - - return (size == corruption_check_size) ? 0 : -EINVAL; - } - early_param("memory_corruption_check_size", set_corruption_check_size); - - - static void __init setup_bios_corruption_check(void) - { - u64 addr = PAGE_SIZE; /* assume first page is reserved anyway */ - - if (memory_corruption_check == -1) { - memory_corruption_check = - #ifdef CONFIG_X86_BOOTPARAM_MEMORY_CORRUPTION_CHECK - 1 - #else - 0 - #endif - ; - } - - if (corruption_check_size == 0) - memory_corruption_check = 0; - - if (!memory_corruption_check) - return; - - corruption_check_size = round_up(corruption_check_size, PAGE_SIZE); - - while(addr < corruption_check_size && num_scan_areas < MAX_SCAN_AREAS) { - u64 size; - addr = find_e820_area_size(addr, &size, PAGE_SIZE); - - if (addr == 0) - break; - - if ((addr + size) > corruption_check_size) - size = corruption_check_size - addr; - - if (size == 0) - break; - - e820_update_range(addr, size, E820_RAM, E820_RESERVED); - scan_areas[num_scan_areas].addr = addr; - scan_areas[num_scan_areas].size = size; - num_scan_areas++; - - /* Assume we've already mapped this early memory */ - memset(__va(addr), 0, size); - - addr += size; - } - - printk(KERN_INFO "Scanning %d areas for low memory corruption\n", - num_scan_areas); - update_e820(); - } - - static struct timer_list periodic_check_timer; - - void check_for_bios_corruption(void) - { - int i; - int corruption = 0; - - if (!memory_corruption_check) - return; - - for(i = 0; i < num_scan_areas; i++) { - unsigned long *addr = __va(scan_areas[i].addr); - unsigned long size = scan_areas[i].size; - - for(; size; addr++, size -= sizeof(unsigned long)) { - if (!*addr) - continue; - printk(KERN_ERR "Corrupted low memory at %p (%lx phys) = %08lx\n", - addr, __pa(addr), *addr); - corruption = 1; - *addr = 0; - } - } - - WARN(corruption, KERN_ERR "Memory corruption detected in low memory\n"); - } - - static void periodic_check_for_corruption(unsigned long data) - { - check_for_bios_corruption(); - mod_timer(&periodic_check_timer, round_jiffies(jiffies + corruption_check_period*HZ)); - } - - void start_periodic_check_for_corruption(void) - { - if (!memory_corruption_check || corruption_check_period == 0) - return; - - printk(KERN_INFO "Scanning for low memory corruption every %d seconds\n", - corruption_check_period); - - init_timer(&periodic_check_timer); - periodic_check_timer.function = &periodic_check_for_corruption; - periodic_check_for_corruption(0); - } - #endif - ++++++++++++++ +++++++++++++++#ifdef CONFIG_X86_RESERVE_LOW_64K static int __init dmi_low_memory_corruption(const struct dmi_system_id *d) { printk(KERN_NOTICE