1. 26 2月, 2009 1 次提交
  2. 31 1月, 2009 1 次提交
    • J
      x86/paravirt: add register-saving thunks to reduce caller register pressure · ecb93d1c
      Jeremy Fitzhardinge 提交于
      Impact: Optimization
      
      One of the problems with inserting a pile of C calls where previously
      there were none is that the register pressure is greatly increased.
      The C calling convention says that the caller must expect a certain
      set of registers may be trashed by the callee, and that the callee can
      use those registers without restriction.  This includes the function
      argument registers, and several others.
      
      This patch seeks to alleviate this pressure by introducing wrapper
      thunks that will do the register saving/restoring, so that the
      callsite doesn't need to worry about it, but the callee function can
      be conventional compiler-generated code.  In many cases (particularly
      performance-sensitive cases) the callee will be in assembler anyway,
      and need not use the compiler's calling convention.
      
      Standard calling convention is:
      	 arguments	    return	scratch
      x86-32	 eax edx ecx	    eax		?
      x86-64	 rdi rsi rdx rcx    rax		r8 r9 r10 r11
      
      The thunk preserves all argument and scratch registers.  The return
      register is not preserved, and is available as a scratch register for
      unwrapped callee code (and of course the return value).
      
      Wrapped function pointers are themselves wrapped in a struct
      paravirt_callee_save structure, in order to get some warning from the
      compiler when functions with mismatched calling conventions are used.
      
      The most common paravirt ops, both statically and dynamically, are
      interrupt enable/disable/save/restore, so handle them first.  This is
      particularly easy since their calls are handled specially anyway.
      
      XXX Deal with VMI.  What's their calling convention?
      Signed-off-by: NH. Peter Anvin <hpa@zytor.com>
      ecb93d1c
  3. 29 10月, 2008 1 次提交
    • H
      x86: two trivial sparse annotations · 9352f569
      Harvey Harrison 提交于
      Impact: fewer sparse warnings, no functional changes
      
      arch/x86/kernel/vsmp_64.c:87:14: warning: incorrect type in argument 1 (different address spaces)
      arch/x86/kernel/vsmp_64.c:87:14:    expected void const volatile [noderef] <asn:2>*addr
      arch/x86/kernel/vsmp_64.c:87:14:    got void *[assigned] address
      arch/x86/kernel/vsmp_64.c:88:22: warning: incorrect type in argument 1 (different address spaces)
      arch/x86/kernel/vsmp_64.c:88:22:    expected void const volatile [noderef] <asn:2>*addr
      arch/x86/kernel/vsmp_64.c:88:22:    got void *
      arch/x86/kernel/vsmp_64.c:100:23: warning: incorrect type in argument 2 (different address spaces)
      arch/x86/kernel/vsmp_64.c:100:23:    expected void volatile [noderef] <asn:2>*addr
      arch/x86/kernel/vsmp_64.c:100:23:    got void *
      arch/x86/kernel/vsmp_64.c:101:23: warning: incorrect type in argument 1 (different address spaces)
      arch/x86/kernel/vsmp_64.c:101:23:    expected void const volatile [noderef] <asn:2>*addr
      arch/x86/kernel/vsmp_64.c:101:23:    got void *
      arch/x86/mm/gup.c:235:6: warning: incorrect type in argument 1 (different base types)
      arch/x86/mm/gup.c:235:6:    expected void const volatile [noderef] <asn:1>*<noident>
      arch/x86/mm/gup.c:235:6:    got unsigned long [unsigned] [assigned] start
      Signed-off-by: NHarvey Harrison <harvey.harrison@gmail.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      9352f569
  4. 23 9月, 2008 1 次提交
    • R
      x86: fix 27-rc crash on vsmp due to paravirt during module load · 05e12e1c
      Ravikiran G Thirumalai 提交于
      27-rc fails to boot up if configured to use modules.
      
      Turns out vsmp_patch was marked __init, and vsmp_patch being the
      pvops 'patch' routine for vsmp, a call to vsmp_patch just turns out
      to execute a code page with series of 0xcc (POISON_FREE_INITMEM -- int3).
      
      vsmp_patch has been marked with __init ever since pvops, however,
      apply_paravirt can be called during module load causing calls to
      freed memory location.
      
      Since apply_paravirt can only be called during init/module load, make
      vsmp_patch with "__init_or_module"
      Signed-off-by: NRavikiran Thirumalai <kiran@scalex86.org>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      05e12e1c
  5. 25 5月, 2008 1 次提交
  6. 29 4月, 2008 1 次提交
  7. 17 4月, 2008 10 次提交
  8. 30 1月, 2008 1 次提交
  9. 11 10月, 2007 2 次提交
  10. 13 10月, 2006 1 次提交
  11. 26 9月, 2006 1 次提交
    • A
      [PATCH] x86: Allow disabling early pci scans with pci=noearly or disallowing conf1 · 0637a70a
      Andi Kleen 提交于
      Some buggy systems can machine check when config space accesses
      happen for some non existent devices.  i386/x86-64 do some early
      device scans that might trigger this. Allow pci=noearly to disable
      this. Also when type 1 is disabling also don't do any early
      accesses which are always type1.
      
      This moves the pci= configuration parsing to be a early parameter.
      I don't think this can break anything because it only changes
      a single global that is only used by PCI.
      
      Cc: gregkh@suse.de
      Cc: Trammell Hudson <hudson@osresearch.net>
      Signed-off-by: NAndi Kleen <ak@suse.de>
      0637a70a
  12. 12 1月, 2006 1 次提交