Messages in this thread | | | Date | Thu, 02 Jul 2009 13:57:01 +0800 | From | Li Zefan <> | Subject | Re: [PATCH] tracing: fix trace_print_seq() |
| |
>> There have a example: >> after reboot: >> # echo kmemtrace > current_tracer >> # echo 0 > options/kmem_minimalistic >> # cat trace >> # tracer: kmemtrace >> # >> # >> Nothing is exported, because the first byte of trace_seq->buffer[ ] >> is KMEMTRACE_USER_ALLOC. >> ( the value of KMEMTRACE_USER_ALLOC is zero, seeing >> kmemtrace_print_alloc_user() in kernel/trace/kmemtrace.c) >> ... > Looks good, thanks. > > Acked-by: Frederic Weisbecker <fweisbec@gmail.com> > > But having a '\0' in a non binary trace looks weird. Why do > we have such plain KMEMTRACE_USER_ALLOC whereas binary tracing > is not set, as your example shows it? >
Because of this commit:
| commit 42af9054c0eeed09ec58d13ec8bf52d225ebcfcc | Author: Eduard - Gabriel Munteanu <eduard.munteanu@linux360.ro> | Date: Mon Mar 23 15:12:26 2009 +0200 | | kmemtrace: restore original tracing data binary format, improve ABI
I think we should change it to use trace_event->binary() interface for binary trace.
| |