Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756691AbZGCAfy (ORCPT ); Thu, 2 Jul 2009 20:35:54 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753420AbZGCAfq (ORCPT ); Thu, 2 Jul 2009 20:35:46 -0400 Received: from cn.fujitsu.com ([222.73.24.84]:65427 "EHLO song.cn.fujitsu.com" rhost-flags-OK-FAIL-OK-OK) by vger.kernel.org with ESMTP id S1753121AbZGCAfq (ORCPT ); Thu, 2 Jul 2009 20:35:46 -0400 Message-ID: <4A4D529A.3090706@cn.fujitsu.com> Date: Fri, 03 Jul 2009 08:36:42 +0800 From: Li Zefan User-Agent: Thunderbird 2.0.0.9 (X11/20071115) MIME-Version: 1.0 To: Steven Rostedt CC: Ingo Molnar , Frederic Weisbecker , Pekka Enberg , Eduard - Gabriel Munteanu , LKML Subject: Re: [PATCH] kmemtrace: print binary output only if 'bin' option is set References: <4A4C4FEA.6010109@cn.fujitsu.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1561 Lines: 41 Steven Rostedt wrote: > On Thu, 2 Jul 2009, Li Zefan wrote: >> --- >> kernel/trace/kmemtrace.c | 119 ++++++++++++++++++++++++++++++++++------------ >> 1 files changed, 89 insertions(+), 30 deletions(-) >> >> diff --git a/kernel/trace/kmemtrace.c b/kernel/trace/kmemtrace.c >> index 1edaa95..9a58f37 100644 >> --- a/kernel/trace/kmemtrace.c >> +++ b/kernel/trace/kmemtrace.c >> @@ -239,12 +239,51 @@ struct kmemtrace_user_event_alloc { >> }; >> >> static enum print_line_t >> -kmemtrace_print_alloc_user(struct trace_iterator *iter, >> - struct kmemtrace_alloc_entry *entry) >> +kmemtrace_print_alloc_user(struct trace_iterator *iter, int flags) >> +{ >> + struct trace_seq *s = &iter->seq; >> + struct kmemtrace_alloc_entry *entry; >> + int ret; >> + >> + trace_assign_type(entry, iter->ent); >> + >> + ret = trace_seq_printf(s, "type_id %d call_site %lu ptr %lu " >> + "bytes_req %lu bytes_alloc %lu gfp_flags %lu node %d\n", >> + entry->type_id, entry->call_site, (unsigned long)entry->ptr, >> + (unsigned long)entry->bytes_req, (unsigned long)entry->bytes_alloc, >> + (unsigned long)entry->gfp_flags, entry->node); > > Could we make the call_site %pF ? That way we can see the name of the > function and not just the address. > Sure, I'll fix it. I just restored the old format. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/