07 Sep, 2013

2 commits


15 May, 2013

1 commit

  • Tony Jones reported that the ftrace self tests on s390 do not work:

    Testing dynamic ftrace ops #1: (0 0 0 0 0) FAILED!
    Testing tracer irqsoff:
    failed to start irqsoff tracer
    .. no entries found ..FAILED!
    Testing tracer wakeup:
    failed to start wakeup tracer
    .. no entries found ..FAILED!
    Testing tracer function_graph:
    Failed to init function_graph tracer, init returned -19
    FAILED!

    This happens because we forgot to adjust the instruction pointer that gets
    passed to the ftrace trace function by MCOUNT_INSN_SIZE.

    In addition change MCOUNT_INSN_SIZE to the correct value on 31 bit.
    It only worked so far because the to be patched instruction was identical.

    Reported-by: Tony Jones
    Signed-off-by: Heiko Carstens
    Signed-off-by: Martin Schwidefsky

    Heiko Carstens
     

05 Jan, 2011

1 commit


01 Mar, 2010

1 commit

  • …el/git/tip/linux-2.6-tip

    * 'tracing-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: (28 commits)
    ftrace: Add function names to dangling } in function graph tracer
    tracing: Simplify memory recycle of trace_define_field
    tracing: Remove unnecessary variable in print_graph_return
    tracing: Fix typo of info text in trace_kprobe.c
    tracing: Fix typo in prof_sysexit_enable()
    tracing: Remove CONFIG_TRACE_POWER from kernel config
    tracing: Fix ftrace_event_call alignment for use with gcc 4.5
    ftrace: Remove memory barriers from NMI code when not needed
    tracing/kprobes: Add short documentation for HAVE_REGS_AND_STACK_ACCESS_API
    s390: Add pt_regs register and stack access API
    tracing/kprobes: Make Kconfig dependencies generic
    tracing: Unify arch_syscall_addr() implementations
    tracing: Add notrace to TRACE_EVENT implementation functions
    ftrace: Allow to remove a single function from function graph filter
    tracing: Add correct/incorrect to sort keys for branch annotation output
    tracing: Simplify test for function_graph tracing start point
    tracing: Drop the tr check from the graph tracing path
    tracing: Add stack dump to trace_printk if stacktrace option is set
    tracing: Use appropriate perl constructs in recordmcount.pl
    tracing: optimize recordmcount.pl for offsets-handling
    ...

    Linus Torvalds
     

27 Feb, 2010

1 commit

  • Use asm offsets to make sure the offset defines to struct _lowcore and
    its layout don't get out of sync.
    Also add a BUILD_BUG_ON() which checks that the size of the structure
    is sane.
    And while being at it change those sites which use odd casts to access
    the current lowcore. These should use S390_lowcore instead.

    Signed-off-by: Heiko Carstens
    Signed-off-by: Martin Schwidefsky

    Heiko Carstens
     

17 Feb, 2010

1 commit

  • Most implementations of arch_syscall_addr() are the same, so create a
    default version in common code and move the one piece that differs (the
    syscall table) to asm/syscall.h. New arch ports don't have to waste
    time copying & pasting this simple function.

    The s390/sparc versions need to be different, so document why.

    Signed-off-by: Mike Frysinger
    Acked-by: David S. Miller
    Acked-by: Paul Mundt
    Acked-by: Heiko Carstens
    Cc: Steven Rostedt
    LKML-Reference:
    Signed-off-by: Frederic Weisbecker

    Mike Frysinger
     

29 Oct, 2009

1 commit


14 Oct, 2009

1 commit

  • Most of the syscalls metadata processing is done from arch.
    But these operations are mostly generic accross archs. Especially now
    that we have a common variable name that expresses the number of
    syscalls supported by an arch: NR_syscalls, the only remaining bits
    that need to reside in arch is the syscall nr to addr translation.

    v2: Compare syscalls symbols only after the "sys" prefix so that we
    avoid spurious mismatches with archs that have syscalls wrappers,
    in which case syscalls symbols have "SyS" prefixed aliases.
    (Reported by: Heiko Carstens)

    Signed-off-by: Frederic Weisbecker
    Acked-by: Heiko Carstens
    Cc: Ingo Molnar
    Cc: Steven Rostedt
    Cc: Li Zefan
    Cc: Masami Hiramatsu
    Cc: Jason Baron
    Cc: Lai Jiangshan
    Cc: Martin Schwidefsky
    Cc: Paul Mundt

    Frederic Weisbecker
     

06 Oct, 2009

1 commit

  • The function graph tracer used to have a protection against NMI
    while entering a function entry tracing. But this is useless now,
    the tracer is reentrant and the ring buffer supports NMI tracing.

    Same as 07868b086cca784f4b532fc2ab574ec3a73b468a for x86.

    Signed-off-by: Heiko Carstens
    Signed-off-by: Martin Schwidefsky

    Heiko Carstens
     

27 Aug, 2009

1 commit

  • This patch includes s390 arch updates to synchronize with latest
    core changes in the syscalls tracing area.

    - tracing: Map syscall name to number (syscall_name_to_nr())
    - tracing: Call arch_init_ftrace_syscalls at boot
    - tracing: add support tracepoint ids (set_syscall_{enter,exit}_id())

    Signed-off-by: Hendrik Brueckner
    Cc: Jason Baron
    Cc: Frederic Weisbecker
    Cc: Ingo Molnar
    Cc: Lai Jiangshan
    Cc: Steven Rostedt
    Cc: Peter Zijlstra
    Cc: Mathieu Desnoyers
    Cc: Jiaying Zhang
    Cc: Martin Bligh
    Cc: Li Zefan
    Cc: Martin Schwidefsky
    Cc: Paul Mundt
    LKML-Reference:
    Signed-off-by: Frederic Weisbecker

    Hendrik Brueckner
     

19 Jun, 2009

1 commit

  • In case gcc does something funny with the stack frames, or the return
    from function code, we would like to detect that.

    An arch may implement passing of a variable that is unique to the
    function and can be saved on entering a function and can be tested
    when exiting the function. Usually the frame pointer can be used for
    this purpose.

    This patch also implements this for x86. Where it passes in the stack
    frame of the parent function, and will test that frame on exit.

    There was a case in x86_32 with optimize for size (-Os) where, for a
    few functions, gcc would align the stack frame and place a copy of the
    return address into it. The function graph tracer modified the copy and
    not the actual return address. On return from the funtion, it did not go
    to the tracer hook, but returned to the parent. This broke the function
    graph tracer, because the return of the parent (where gcc did not do
    this funky manipulation) returned to the location that the child function
    was suppose to. This caused strange kernel crashes.

    This test detected the problem and pointed out where the issue was.

    This modifies the parameters of one of the functions that the arch
    specific code calls, so it includes changes to arch code to accommodate
    the new prototype.

    Note, I notice that the parsic arch implements its own push_return_trace.
    This is now a generic function and the ftrace_push_return_trace should be
    used instead. This patch does not touch that code.

    Cc: Benjamin Herrenschmidt
    Cc: Paul Mackerras
    Cc: Heiko Carstens
    Cc: Martin Schwidefsky
    Cc: Frederic Weisbecker
    Cc: Helge Deller
    Cc: Kyle McMartin
    Signed-off-by: Steven Rostedt

    Steven Rostedt
     

12 Jun, 2009

3 commits