1. 05 9月, 2008 5 次提交
  2. 28 8月, 2008 1 次提交
    • H
      x86: generate names for /proc/cpuinfo from <asm/cpufeature.h> · 7414aa41
      H. Peter Anvin 提交于
      We have had a number of cases where <asm/cpufeature.h> (and its
      predecessors) have diverged substantially from the names list in
      /proc/cpuinfo.  This patch generates the latter from the former.
      
      It retains the option for explicitly overriding the strings, but by
      making that require a separate action it should at least be less
      likely to happen.
      
      It would be good to do a future pass and rename strings that are
      gratuituously different in the kernel (/proc/cpuinfo is a userspace
      interface and must remain constant.)
      Signed-off-by: NH. Peter Anvin <hpa@zytor.com>
      7414aa41
  3. 26 8月, 2008 4 次提交
  4. 25 8月, 2008 2 次提交
  5. 23 8月, 2008 1 次提交
    • R
      x86 MCE: Fix CPU hotplug problem with multiple multicore AMD CPUs · 8735728e
      Rafael J. Wysocki 提交于
      During CPU hot-remove the sysfs directory created by
      threshold_create_bank(), defined in
      arch/x86/kernel/cpu/mcheck/mce_amd_64.c, has to be removed before
      its parent directory, created by mce_create_device(), defined in
      arch/x86/kernel/cpu/mcheck/mce_64.c .  Moreover, when the CPU in
      question is hotplugged again, obviously the latter has to be created
      before the former.  At present, the right ordering is not enforced,
      because all of these operations are carried out by CPU hotplug
      notifiers which are not appropriately ordered with respect to each
      other.  This leads to serious problems on systems with two or more
      multicore AMD CPUs, among other things during suspend and hibernation.
      
      Fix the problem by placing threshold bank CPU hotplug callbacks in
      mce_cpu_callback(), so that they are invoked at the right places,
      if defined.  Additionally, use kobject_del() to remove the sysfs
      directory associated with the kobject created by
      kobject_create_and_add() in threshold_create_bank(), to prevent the
      kernel from crashing during CPU hotplug operations on systems with
      two or more multicore AMD CPUs.
      
      This patch fixes bug #11337.
      Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
      Acked-by: NAndi Kleen <andi@firstfloor.org>
      Tested-by: NMark Langsdorf <mark.langsdorf@amd.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      8735728e
  6. 22 8月, 2008 5 次提交
    • I
      x86: work around MTRR mask setting, v2 · 9754a5b8
      Ingo Molnar 提交于
      improve the debug printout:
      
      - make it actually display something
      - print it only once
      
      would be nice to have a WARN_ONCE() facility, to feed such things to
      kerneloops.org.
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      9754a5b8
    • M
      x86: fix section mismatch warning - uv_cpu_init · c4bd1fda
      Marcin Slusarz 提交于
      WARNING: vmlinux.o(.cpuinit.text+0x3cc4): Section mismatch in reference from the function uv_cpu_init() to the function .init.text:uv_system_init()
      The function __cpuinit uv_cpu_init() references
      a function __init uv_system_init().
      If uv_system_init is only used by uv_cpu_init then
      annotate uv_system_init with a matching annotation.
      
      uv_system_init was ment to be called only once, so do it from codepath
      (native_smp_prepare_cpus) which is called once, right before activation
      of other cpus (smp_init).
      
      Note: old code relied on uv_node_to_blade being initialized to 0,
      but it'a not initialized from anywhere.
      Signed-off-by: NMarcin Slusarz <marcin.slusarz@gmail.com>
      Acked-by: NJack Steiner <steiner@sgi.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      c4bd1fda
    • Y
      x86_64: printout msr -v2 · b05f78f5
      Yinghai Lu 提交于
      commandline show_msr=1 for bsp, show_msr=32 for all 32 cpus.
      
      [ mingo@elte.hu: added documentation ]
      Signed-off-by: NYinghai Lu <yhlu.kernel@gmail.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      b05f78f5
    • A
      x86: fix VMI for early params · 3a6ddd5f
      Alok Kataria 提交于
      while fixing a different bug i moved the call to vmi_init before
      early params could be parsed.
      
      This broke the vmi specific commandline parameters.
      Fix that, by moving vmi initialization after kernel has got a chance to
      parse early parameters.
      Signed-off-by: NAlok N Kataria <akataria@vmware.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      3a6ddd5f
    • Y
      x86: work around MTRR mask setting · 38cc1c3d
      Yinghai Lu 提交于
      Joshua Hoblitt reported that only 3 GB of his 16 GB of RAM is
      usable. Booting with mtrr_show showed us the BIOS-initialized
      MTRR settings - which are all wrong.
      
      So the root cause is that the BIOS has not set the mask correctly:
      
      >               [    0.429971]  MSR00000200: 00000000d0000000
      >               [    0.433305]  MSR00000201: 0000000ff0000800
      > should be ==> [    0.433305]  MSR00000201: 0000003ff0000800
      >
      >               [    0.436638]  MSR00000202: 00000000e0000000
      >               [    0.439971]  MSR00000203: 0000000fe0000800
      > should be ==> [    0.439971]  MSR00000203: 0000003fe0000800
      >
      >               [    0.443304]  MSR00000204: 0000000000000006
      >               [    0.446637]  MSR00000205: 0000000c00000800
      > should be ==> [    0.446637]  MSR00000205: 0000003c00000800
      >
      >               [    0.449970]  MSR00000206: 0000000400000006
      >               [    0.453303]  MSR00000207: 0000000fe0000800
      > should be ==> [    0.453303]  MSR00000207: 0000003fe0000800
      >
      >               [    0.456636]  MSR00000208: 0000000420000006
      >               [    0.459970]  MSR00000209: 0000000ff0000800
      > should be ==> [    0.459970]  MSR00000209: 0000003ff0000800
      
      So detect this borkage and add the prefix 111.
      Signed-off-by: NYinghai Lu <yhlu.kernel@gmail.com>
      Cc: <stable@kernel.org>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      38cc1c3d
  7. 21 8月, 2008 5 次提交
  8. 20 8月, 2008 3 次提交
  9. 19 8月, 2008 3 次提交
  10. 18 8月, 2008 10 次提交
    • T
      x86: configuration options to compile out x86 CPU support code · 8d02c211
      Thomas Petazzoni 提交于
      This patch adds some configuration options that allow to compile out
      CPU vendor-specific code in x86 kernels (in arch/x86/kernel/cpu). The
      new configuration options are only visible when CONFIG_EMBEDDED is
      selected, as they are mostly interesting for space savings reasons.
      
      An example of size saving, on x86 with only Intel CPU support:
      
         text	   data	    bss	    dec	    hex	filename
      1125479	 118760	 212992	1457231	 163c4f	vmlinux.old
      1121355	 116536	 212992	1450883	 162383	vmlinux
        -4124   -2224       0   -6348   -18CC +/-
      
      However, I'm not exactly sure that the Kconfig wording is correct with
      regard to !64BIT / 64BIT.
      
      [ mingo@elte.hu: convert macro to inline ]
      Signed-off-by: NThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      8d02c211
    • T
      x86: move cmpxchg fallbacks to a generic place · 774400a3
      Thomas Petazzoni 提交于
      arch/x86/kernel/cpu/intel.c defines a few fallback functions
      (cmpxchg_*()) that are used when the CPU doesn't support cmpxchg
      and/or cmpxchg64 natively. However, while defined in an Intel-specific
      file, these functions are also used for CPUs from other vendors when
      they don't support cmpxchg and/or cmpxchg64. This breaks the
      compilation when support for Intel CPUs is disabled.
      
      This patch moves these functions to a new
      arch/x86/kernel/cpu/cmpxchg.c file, unconditionally compiled when
      X86_32 is enabled.
      Signed-off-by: NThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Cc: michael@free-electrons.com
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      774400a3
    • T
      x86: make movsl_mask definition non-CPU specific · 8bfcb396
      Thomas Petazzoni 提交于
      movsl_mask is currently defined in arch/x86/kernel/cpu/intel.c, which
      contains code specific to Intel CPUs. However, movsl_mask is used in
      the non-CPU specific code in arch/x86/lib/usercopy_32.c, which breaks
      the compilation when support for Intel CPUs is compiled out.
      
      This patch solves this problem by moving movsl_mask's definition close
      to its users in arch/x86/lib/usercopy_32.c.
      Signed-off-by: NThomas Petazzoni <thomas.petazzoni@free-electrons.com>
      Cc: michael@free-electrons.com
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      8bfcb396
    • M
      x86, calgary: fix section mismatch warning - get_tce_space_from_tar · f7106662
      Marcin Slusarz 提交于
      WARNING: vmlinux.o(.text+0x27032): Section mismatch in reference from the function get_tce_space_from_tar() to the function .init.text:calgary_bus_has_devices()
      The function get_tce_space_from_tar() references
      the function __init calgary_bus_has_devices().
      This is often because get_tce_space_from_tar lacks a __init
      annotation or the annotation of calgary_bus_has_devices is wrong.
      
      get_tce_space_from_tar is called only from __init function (calgary_init)
      and calls __init function (calgary_bus_has_devices).
      So annotate it properly.
      Signed-off-by: NMarcin Slusarz <marcin.slusarz@gmail.com>
      Cc: Chandru Siddalingappa <chandru@in.ibm.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      f7106662
    • M
      x86: silence section mismatch warning - get_local_pda · d19fbfdf
      Marcin Slusarz 提交于
      Take out part of get_local_pda referencing __init function (free_bootmem)
      to new (static) function marked as __ref. It's safe to do because free_bootmem
      is called before __init sections are dropped.
      
      WARNING: vmlinux.o(.cpuinit.text+0x3cd7): Section mismatch in reference from the function get_local_pda() to the function .init.text:free_bootmem()
      The function __cpuinit get_local_pda() references
      a function __init free_bootmem().
      If free_bootmem is only used by get_local_pda then
      annotate free_bootmem with a matching annotation.
      Signed-off-by: NMarcin Slusarz <marcin.slusarz@gmail.com>
      Cc: Mike Travis <travis@sgi.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      d19fbfdf
    • D
      x86: fix i486 suspend to disk CR4 oops · e532c06f
      David Fries 提交于
      arch/x86/power/cpu_32.c __save_processor_state calls read_cr4()
      only a i486 CPU doesn't have the CR4 register.  Trying to read it
      produces an invalid opcode oops during suspend to disk.
      
      Use the safe rc4 reading op instead. If the value to be written is
      zero the write is skipped.
      
      arch/x86/power/hibernate_asm_32.S
      done: swapped the use of %eax and %ecx to use jecxz for
      the zero test and jump over store to %cr4.
      restore_image: s/%ecx/%eax/ to be consistent with done:
      
      In addition to __save_processor_state, acpi_save_state_mem,
      efi_call_phys_prelog, and efi_call_phys_epilog had checks added
      (acpi restore was in assembly and already had a check for
      non-zero).  There were other reads and writes of CR4, but MCE and
      virtualization shouldn't be executed on a i486 anyway.
      Signed-off-by: NDavid Fries <david@fries.net>
      Acked-by: NH. Peter Anvin <hpa@zytor.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      e532c06f
    • M
      x86: mpparse.c: fix section mismatch warning · 39e00fe2
      Marcin Slusarz 提交于
      WARNING: vmlinux.o(.text+0x118f7): Section mismatch in reference from the function construct_ioapic_table() to the function .init.text:MP_bus_info()
      The function construct_ioapic_table() references
      the function __init MP_bus_info().
      This is often because construct_ioapic_table lacks a __init
      annotation or the annotation of MP_bus_info is wrong.
      
      construct_ioapic_table is called only from construct_default_ISA_mptable which is __init
      Signed-off-by: NMarcin Slusarz <marcin.slusarz@gmail.com>
      Signed-off-by: NH. Peter Anvin <hpa@zytor.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      39e00fe2
    • M
      x86: mmconf: fix section mismatch warning · c72a5efe
      Marcin Slusarz 提交于
      WARNING: arch/x86/kernel/built-in.o(.cpuinit.text+0x1591): Section mismatch in reference from the function init_amd() to the function .init.text:check_enable_amd_mmconf_dmi()
      The function __cpuinit init_amd() references
      a function __init check_enable_amd_mmconf_dmi().
      If check_enable_amd_mmconf_dmi is only used by init_amd then
      annotate check_enable_amd_mmconf_dmi with a matching annotation.
      
      check_enable_amd_mmconf_dmi is only called from init_amd which is __cpuinit
      Signed-off-by: NMarcin Slusarz <marcin.slusarz@gmail.com>
      Signed-off-by: NH. Peter Anvin <hpa@zytor.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      c72a5efe
    • M
      x86: fix MP_processor_info section mismatch warning · 67d0c9eb
      Marcin Slusarz 提交于
      WARNING: arch/x86/kernel/built-in.o(.cpuinit.text+0x1fe7): Section mismatch in reference from the function MP_processor_info() to the variable .init.data:x86_quirks
      The function __cpuinit MP_processor_info() references
      a variable __initdata x86_quirks.
      If x86_quirks is only used by MP_processor_info then
      annotate x86_quirks with a matching annotation.
      
      MP_processor_info uses x86_quirks which is __init and is used only from
      smp_read_mpc and construct_default_ISA_mptable which are __init
      Signed-off-by: NMarcin Slusarz <marcin.slusarz@gmail.com>
      Signed-off-by: NH. Peter Anvin <hpa@zytor.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      67d0c9eb
    • M
      x86, tsc: fix section mismatch warning · d554d9a4
      Marcin Slusarz 提交于
      WARNING: vmlinux.o(.text+0x7950): Section mismatch in reference from the function native_calibrate_tsc() to the function .init.text:tsc_read_refs()
      The function native_calibrate_tsc() references
      the function __init tsc_read_refs().
      This is often because native_calibrate_tsc lacks a __init
      annotation or the annotation of tsc_read_refs is wrong.
      
      tsc_read_refs is called from native_calibrate_tsc which is not __init
      and native_calibrate_tsc cannot be marked __init
      Signed-off-by: NMarcin Slusarz <marcin.slusarz@gmail.com>
      Signed-off-by: NH. Peter Anvin <hpa@zytor.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      d554d9a4
  11. 16 8月, 2008 1 次提交