Comment 11 for bug 1439562

Revision history for this message
Jeremy Kerr (jk-ozlabs) wrote :

Sure thing. The patch in my ubuntu-vivid git tree is slightly modified from the upstream commit - just so we don't need to include those prerequisites.

However, if you're after pristine upstream commits, the following will work on top of the vivid tree (as at 83f803a6):

commit 4c3b21686111e0ac6018469dacbc5549f9915cf8
Author: Michael Ellerman <email address hidden>
Date: Fri Dec 5 21:16:59 2014 +1100

    powerpc/kernel: Make syscall_exit a local label

    Currently when we back trace something that is in a syscall we see
    something like this:

    [c000000000000000] [c000000000000000] SyS_read+0x6c/0x110
    [c000000000000000] [c000000000000000] syscall_exit+0x0/0x98

    Although it's entirely correct, seeing syscall_exit at the bottom can be
    confusing - we were exiting from a syscall and then called SyS_read() ?

    If we instead change syscall_exit to be a local label we get something
    more intuitive:

    [c0000001fa46fde0] [c00000000026719c] SyS_read+0x6c/0x110
    [c0000001fa46fe30] [c000000000009264] system_call+0x38/0xd0

    ie. we were handling a system call, and it was SyS_read().

    Signed-off-by: Michael Ellerman <email address hidden>

commit a4bcbe6a41adcaa5e7f1830a7c1da8691d9d2b1d
Author: Michael Ellerman <email address hidden>
Date: Wed Jan 14 14:47:56 2015 +1100

    powerpc: Remove old compile time disabled syscall tracing code

    We have code to do syscall tracing which is disabled at compile time by
    default. It's not been touched since the dawn of time (ie. v2.6.12).

    There are now better ways to do syscall tracing, ie. using the
    raw_syscall, or syscall tracepoints.

    For the specific case of tracing syscalls at boot on a system that
    doesn't get to userspace, you can boot with:

      trace_event=syscalls tp_printk=on

    Which will trace syscalls from boot, and echo all output to the console.

    Signed-off-by: Michael Ellerman <email address hidden>