06 May, 2014

1 commit

  • As requested by Linus, revert adding __visible to asmlinkage.
    Instead we add __visible explicitely to all the symbols
    that need it.

    This reverts commit 128ea04a9885af9629059e631ddf0cab4815b589.

    Link: http://lkml.kernel.org/r/1398984278-29319-2-git-send-email-andi@firstfloor.org
    Signed-off-by: H. Peter Anvin

    Andi Kleen
     

14 Feb, 2014

1 commit


28 Jan, 2014

1 commit


06 May, 2013

1 commit

  • Pull mudule updates from Rusty Russell:
    "We get rid of the general module prefix confusion with a binary config
    option, fix a remove/insert race which Never Happens, and (my
    favorite) handle the case when we have too many modules for a single
    commandline. Seriously, the kernel is full, please go away!"

    * tag 'modules-next-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux:
    modpost: fix unwanted VMLINUX_SYMBOL_STR expansion
    X.509: Support parse long form of length octets in Authority Key Identifier
    module: don't unlink the module until we've removed all exposure.
    kernel: kallsyms: memory override issue, need check destination buffer length
    MODSIGN: do not send garbage to stderr when enabling modules signature
    modpost: handle huge numbers of modules.
    modpost: add -T option to read module names from file/stdin.
    modpost: minor cleanup.
    genksyms: pass symbol-prefix instead of arch
    module: fix symbol versioning with symbol prefixes
    CONFIG_SYMBOL_PREFIX: cleanup.

    Linus Torvalds
     

02 May, 2013

1 commit

  • Al's commit e1b5bb6d1236 ("consolidate cond_syscall and SYSCALL_ALIAS
    declarations") broke the build on blackfin and metag due to the
    following code:

    #ifndef SYMBOL_NAME
    #ifdef CONFIG_SYMBOL_PREFIX
    #define SYMBOL_NAME(x) CONFIG_SYMBOL_PREFIX ## x
    #else
    #define SYMBOL_NAME(x) x
    #endif
    #endif
    #define __SYMBOL_NAME(x) __stringify(SYMBOL_NAME(x))

    __stringify literally stringifies CONFIG_SYMBOL_PREFIX ##x, so you get
    lines like this in kernel/sys_ni.s:

    .weak CONFIG_SYMBOL_PREFIXsys_quotactl
    .set CONFIG_SYMBOL_PREFIXsys_quotactl,CONFIG_SYMBOL_PREFIXsys_ni_syscall

    The patches in Rusty's modules-next tree such as "CONFIG_SYMBOL_PREFIX:
    cleanup." cleans up the whole mess around symbol prefixes, so this patch
    just attempts to fix the build in the meantime.

    The intermediate definition of SYMBOL_NAME above isn't used and is
    incorrect when CONFIG_SYMBOL_PREFIX is defined as CONFIG_SYMBOL_PREFIX
    is a quoted string literal, so define __SYMBOL_NAME directly depending
    on CONFIG_SYMBOL_PREFIX.

    Signed-off-by: James Hogan
    Mea-culpa-by: Al Viro
    Cc: Rusty Russell
    Cc: Mike Frysinger
    Cc: uclinux-dist-devel@blackfin.uclinux.org
    Signed-off-by: Linus Torvalds

    James Hogan
     

04 Mar, 2013

1 commit


13 Jan, 2012

3 commits


24 May, 2011

1 commit

  • As UML does no longer need asmregparm we can remove it.

    Signed-off-by: Richard Weinberger
    Cc: namhyung@gmail.com
    Cc: davem@davemloft.net
    Cc: fweisbec@gmail.com
    Cc: dhowells@redhat.com
    Link: http://lkml.kernel.org/r/%3C1306189085-29896-1-git-send-email-richard%40nod.at%3E
    Signed-off-by: Thomas Gleixner

    Richard Weinberger
     

03 Mar, 2010

2 commits


21 Sep, 2009

1 commit

  • Adding a reference to to x86's causes
    the x86 linker script to have syntax errors, because the ALIGN and
    ENTRY keywords get redefined to the assembly implementations of those.
    One could fix this by adjusting the include structure, but I think any
    solution based on that approach would be fragile.

    Currently, it is impossible when writing a header to do something
    different for assembly files and linker scripts, even though there are
    clearly cases where one wants them to define macros differently for
    the two (ENTRY being an excellent example).
    So I think the right solution here is to introduce a new preprocessor
    definition, called LINKER_SCRIPT that is set along with __ASSEMBLY__
    for linker scripts, and to use that to not define ALIGN and ENTRY in
    linker scripts.
    I suspect we'll find other uses for this mechanism in
    the future.

    Signed-off-by: Tim Abbott
    Signed-off-by: Sam Ravnborg

    Tim Abbott
     

27 Jun, 2009

1 commit

  • This patch is preparation for replacing most uses of
    ".bss.page_aligned" and ".data.page_aligned" in the kernel with
    macros, so that the section name can later be changed without having
    to touch a lot of the kernel.

    The long-term goal here is to be able to change the kernel's magic
    section names to those that are compatible with -ffunction-sections
    -fdata-sections. This requires renaming all magic sections with names
    of the form ".data.foo".

    Signed-off-by: Tim Abbott
    Acked-by: David Howells
    Signed-off-by: Sam Ravnborg

    Tim Abbott
     

27 Nov, 2008

1 commit

  • entry_32.S is now the only user of KPROBE_ENTRY / KPROBE_END,
    treewide. This patch reorders entry_64.S and explicitly generates
    a separate section for functions that need the protection. The
    generated code before and after the patch is equal.

    The KPROBE_ENTRY and KPROBE_END macro's are removed too.

    Signed-off-by: Alexander van Heukelum
    Signed-off-by: Ingo Molnar

    Alexander van Heukelum
     

14 Oct, 2008

1 commit


14 Jul, 2008

1 commit


08 Jul, 2008

1 commit

  • Making a variable page-aligned by using
    __attribute__((section(".data.page_aligned"))) is fragile because if
    sizeof(variable) is not also a multiple of page size, it leaves
    variables in the remainder of the section unaligned.

    This patch introduces two new qualifiers, __page_aligned_data and
    __page_aligned_bss to set the section *and* the alignment of
    variables. This makes page-aligned variables more robust because the
    linker will make sure they're aligned properly. Unfortunately it
    requires *all* page-aligned data to use these macros...

    Signed-off-by: Ingo Molnar

    Jeremy Fitzhardinge
     

24 May, 2008

1 commit

  • notrace signals that a function should not be traced. Most of the
    time this is used by tracers to annotate code that cannot be
    traced - it's in a volatile state (such as in user vdso context
    or NMI context) or it's in the tracer internals.

    Signed-off-by: Ingo Molnar
    Signed-off-by: Thomas Gleixner

    Ingo Molnar
     

11 Apr, 2008

3 commits

  • git commit 54a015104136974262afa4b8ddd943ea70dec8a2 ("asmlinkage_protect
    replaces prevent_tail_call") causes this build failure on s390:

    AS arch/s390/kernel/entry64.o
    In file included from arch/s390/kernel/entry64.S:14:
    include/linux/linkage.h:34: error: syntax error in macro parameter list
    make[1]: *** [arch/s390/kernel/entry64.o] Error 1
    make: *** [arch/s390/kernel] Error 2

    and some other architectures. The reason is that some architectures add
    the "-traditional" flag to the invocation of $(AS), which disables
    variadic macro argument support.

    So just surround the new define with an #ifndef __ASSEMBLY__ to prevent
    any side effects on asm code.

    Cc: Roland McGrath
    Cc: Martin Schwidefsky
    Signed-off-by: Heiko Carstens
    Signed-off-by: Linus Torvalds

    Heiko Carstens
     
  • 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: Linus Torvalds

    Linus Torvalds
     
  • 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: Roland McGrath
    Signed-off-by: Linus Torvalds

    Roland McGrath
     

14 Feb, 2008

1 commit


30 Jan, 2008

2 commits

  • The ENDPROCs() were not used everywhere. Some code used just END() instead,
    while other code used nothing. um/sys-i386/checksum.S didn't #include
    . I also got confused because gcc puts the
    .type near the ENTRY, while ENDPROC puts it on the opposite end.

    Signed off by: John Reiser
    Signed-off-by: Ingo Molnar
    Signed-off-by: Thomas Gleixner

    John Reiser
     
  • introduce the "asmregparm" calling convention: for functions
    implemented in assembly with a fixed regparm input parameters
    calling convention.

    mark the semaphore and rwsem slowpath functions with that.

    Signed-off-by: Ingo Molnar
    Signed-off-by: Miklos Szeredi
    Signed-off-by: Thomas Gleixner

    Ingo Molnar
     

22 Oct, 2007

1 commit


26 Sep, 2006

1 commit

  • This patch moves the entry.S:error_entry to .kprobes.text section,
    since code marked unsafe for kprobes jumps directly to entry.S::error_entry,
    that must be marked unsafe as well.
    This patch also moves all the ".previous.text" asm directives to ".previous"
    for kprobes section.

    AK: Following a similar i386 patch from Chuck Ebbert
    AK: Also merged Jeremy's fix in.

    +From: Jeremy Fitzhardinge

    KPROBE_ENTRY does a .section .kprobes.text, and expects its users to
    do a .previous at the end of the function.

    Unfortunately, if any code within the function switches sections, for
    example .fixup, then the .previous ends up putting all subsequent code
    into .fixup. Worse, any subsequent .fixup code gets intermingled with
    the code its supposed to be fixing (which is also in .fixup). It's
    surprising this didn't cause more havok.

    The fix is to use .pushsection/.popsection, so this stuff nests
    properly. A further cleanup would be to get rid of all
    .section/.previous pairs, since they're inherently fragile.

    +From: Chuck Ebbert

    Because code marked unsafe for kprobes jumps directly to
    entry.S::error_code, that must be marked unsafe as well.
    The easiest way to do that is to move the page fault entry
    point to just before error_code and let it inherit the same
    section.

    Also moved all the ".previous" asm directives for kprobes
    sections to column 1 and removed ".text" from them.

    Signed-off-by: Chuck Ebbert
    Signed-off-by: Andi Kleen

    Prasanna S.P
     

26 Apr, 2006

1 commit


24 Mar, 2006

1 commit

  • Provide abstraction for generating type and size information of assembly
    routines and data, while permitting architectures to override these
    defaults.

    Signed-off-by: Jan Beulich
    Cc: "Russell King"
    Cc: Ralf Baechle
    Cc: "Andi Kleen"
    Cc: "Luck, Tony"
    Cc: Miles Bader
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jan Beulich
     

08 Sep, 2005

1 commit

  • There are possible race conditions if probes are placed on routines within the
    kprobes files and routines used by the kprobes. For example if you put probe
    on get_kprobe() routines, the system can hang while inserting probes on any
    routine such as do_fork(). Because while inserting probes on do_fork(),
    register_kprobes() routine grabs the kprobes spin lock and executes
    get_kprobe() routine and to handle probe of get_kprobe(), kprobes_handler()
    gets executed and tries to grab kprobes spin lock, and spins forever. This
    patch avoids such possible race conditions by preventing probes on routines
    within the kprobes file and routines used by kprobes.

    I have modified the patches as per Andi Kleen's suggestion to move kprobes
    routines and other routines used by kprobes to a seperate section
    .kprobes.text.

    Also moved page fault and exception handlers, general protection fault to
    .kprobes.text section.

    These patches have been tested on i386, x86_64 and ppc64 architectures, also
    compiled on ia64 and sparc64 architectures.

    Signed-off-by: Prasanna S Panchamukhi
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Prasanna S Panchamukhi
     

17 Apr, 2005

1 commit

  • Initial git repository build. I'm not bothering with the full history,
    even though we have it. We can create a separate "historical" git
    archive of that later if we want to, and in the meantime it's about
    3.2GB when imported into git - space that would just make the early
    git days unnecessarily complicated, when we don't have a lot of good
    infrastructure for it.

    Let it rip!

    Linus Torvalds