Re: [ftrace] kernel panics during my attempt to use ftrace

From: Namhyung Kim
Date: Mon Jun 27 2016 - 23:45:21 EST


Hello,

On Tue, Jun 21, 2016 at 9:53 PM, Enrico Mioso <mrkiko.rs@xxxxxxxxx> wrote:
> Hello guys.
>
> First of all - thank you for your great work in ftrace, and in general in
> the Linux tracing infrastructure. I am a newbie: so I am not able to use it
> at it's full power, still I find it's capabilities impressive.
>
> I am asking for help, since I am encountering some problems in using ftrace.
> I am trying to come up with a solution to trace a specific workload (a
> program): to understand what are the functions the kernel spends most of his
> time in.
> To do so, I inspired myself to some code I found around (I can mention it if
> needed). I took free inspiration: so my editing may be very very wrong.
> When I run this script, the kernel panics. the output is below. the kernel
> is Ubuntu 16.04 stock, running in a qemu virtual machine (using kvm).

Please check commit 8329e818f149 ("ftrace/x86: Set ftrace_stub to weak
to prevent gcc from using short jumps to it") The ubuntu 16.04 seems to
have binutils 2.26 which is same version that caused trouble in my system.

Thanks,
Namhyung


> Any help would be greatly apreciated. Thank you very much guys.
> Fort any needed infos, contact me.
> Enrico