[Crash-utility] (no subject)
Karlsson, Jan
Jan.Karlsson at sonymobile.com
Tue Dec 2 08:57:56 UTC 2014
Hi Dave,
I have been looking at the trace extension that you deliver together with crash. In the kernel I look at the trace_array is defined as:
struct trace_array {
struct list_head list;
char *name;
struct trace_buffer trace_buffer;
#ifdef CONFIG_TRACER_MAX_TRACE
/*
*/
struct trace_buffer max_buffer;
bool allocated_snapshot;
#endif
....
However trace.c assumes that if the trace_buffer field exists then the max_buffer field also exists, which is not true. So if CONFIG_TRACER_MAX_TRACE is not defined in the kernel then the trace extension will fail when it is loaded with a message that the max_buffer field does not exist.
To fix this then the statements:
init_offset(trace_array, max_buffer);
in the function init_offsets and
ftrace_int_max_tr_trace();
in function ftrace_init should not be executed if the max_buffer field is not present. I have tested this and it works for me.
Jan
Jan Karlsson
Senior Software Engineer
System Assurance
Sony Mobile Communications
Tel: +46 703 062 174
jan.karlsson at sonymobile.com<mailto:Firstname.Lastname at sonymobile.com>
sonymobile.com<http://sonymobile.com/>
[cid:image001.gif at 01D00E16.22AD0C60]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/crash-utility/attachments/20141202/35b791ed/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.gif
Type: image/gif
Size: 1749 bytes
Desc: image001.gif
URL: <http://listman.redhat.com/archives/crash-utility/attachments/20141202/35b791ed/attachment.gif>
More information about the Crash-utility
mailing list