1. 24 11月, 2008 1 次提交
    • C
      x86: introduce ENTRY(KPROBE_ENTRY)_X86 assembly helpers to catch unbalanced declaration v3 · 3b6c52b5
      Cyrill Gorcunov 提交于
      Impact: make ENTRY()/END() macros more capable
      
      It's usefull to catch unbalanced or messed or mixed declarations of ENTRY and
      KPROBES. These macros would help a bit.
      
      For example the following code would compile without problems
      
              ENTRY_X86(mcount)
                      retq
              END_X86(mcount)
      
      But if you forget and mess the following form
      
              ENTRY_X86(mcount)
                      retq
              END(mcount)
      
              ENTRY_X86(ftrace_caller)
      
      The assembler will issue the following message:
      Error: ENTRY_X86/KPROBE_X86 unbalanced,missed,mixed
      
      Actually the checking is performed at every _X86 macro
      so maybe it's good idea to put ENTRY_KPROBE_FINAL_X86
      at the end of .S file to be sure you didn't miss anything.
      Signed-off-by: NCyrill Gorcunov <gorcunov@gmail.com>
      Cc: Alexander van Heukelum <heukelum@mailshack.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      3b6c52b5
  2. 23 10月, 2008 2 次提交
  3. 23 7月, 2008 1 次提交
    • V
      x86: consolidate header guards · 77ef50a5
      Vegard Nossum 提交于
      This patch is the result of an automatic script that consolidates the
      format of all the headers in include/asm-x86/.
      
      The format:
      
      1. No leading underscore. Names with leading underscores are reserved.
      2. Pathname components are separated by two underscores. So we can
         distinguish between mm_types.h and mm/types.h.
      3. Everything except letters and numbers are turned into single
         underscores.
      Signed-off-by: NVegard Nossum <vegard.nossum@gmail.com>
      77ef50a5
  4. 17 4月, 2008 1 次提交
  5. 11 4月, 2008 2 次提交
    • L
      Add commentary about the new "asmlinkage_protect()" macro · d10d89ec
      Linus Torvalds 提交于
      It's really a pretty ugly thing to need, and some day it will hopefully
      be obviated by teaching gcc about the magic calling conventions for the
      low-level system call code, but in the meantime we can at least add big
      honking comments about why we need these insane and strange macros.
      
      I took my comments from my version of the macro, but I ended up deciding
      to just pick Roland's version of the actual code instead (with his
      prettier syntax that uses vararg macros).  Thus the previous two commits
      that actually implement it.
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      d10d89ec
    • R
      asmlinkage_protect replaces prevent_tail_call · 54a01510
      Roland McGrath 提交于
      The prevent_tail_call() macro works around the problem of the compiler
      clobbering argument words on the stack, which for asmlinkage functions
      is the caller's (user's) struct pt_regs.  The tail/sibling-call
      optimization is not the only way that the compiler can decide to use
      stack argument words as scratch space, which we have to prevent.
      Other optimizations can do it too.
      
      Until we have new compiler support to make "asmlinkage" binding on the
      compiler's own use of the stack argument frame, we have work around all
      the manifestations of this issue that crop up.
      
      More cases seem to be prevented by also keeping the incoming argument
      variables live at the end of the function.  This makes their original
      stack slots attractive places to leave those variables, so the compiler
      tends not clobber them for something else.  It's still no guarantee, but
      it handles some observed cases that prevent_tail_call() did not.
      Signed-off-by: NRoland McGrath <roland@redhat.com>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      54a01510
  6. 30 1月, 2008 2 次提交
  7. 11 10月, 2007 1 次提交