From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754767AbbCaN0t (ORCPT ); Tue, 31 Mar 2015 09:26:49 -0400 Received: from smtprelay0197.hostedemail.com ([216.40.44.197]:58284 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754144AbbCaN0r (ORCPT ); Tue, 31 Mar 2015 09:26:47 -0400 X-Session-Marker: 726F737465647440676F6F646D69732E6F7267 X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,rostedt@goodmis.org,:::::::::::,RULES_HIT:41:355:379:541:599:800:960:973:988:989:1260:1277:1311:1313:1314:1345:1359:1437:1515:1516:1518:1534:1541:1593:1594:1711:1730:1747:1777:1792:2393:2553:2559:2562:2693:3138:3139:3140:3141:3142:3352:3622:3865:3866:3867:3868:3870:3871:3872:3873:3874:4250:4362:5007:6261:7875:7903:9040:10004:10400:10848:10967:11232:11658:11914:12043:12296:12517:12519:12663:12740:13069:13311:13357:14096:14097:21060:21080,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:none,Custom_rules:0:0:0 X-HE-Tag: table63_3ae6ba7a1e433 X-Filterd-Recvd-Size: 2167 Date: Tue, 31 Mar 2015 09:26:43 -0400 From: Steven Rostedt To: Masami Hiramatsu Cc: linux-kernel@vger.kernel.org, Ingo Molnar , Andrew Morton , Namhyung Kim , Mathieu Desnoyers Subject: Re: [RFC][PATCH 00/10] tracing: Use TRACE_DEFINE_ENUM() to show enum values Message-ID: <20150331092643.47b59505@gandalf.local.home> In-Reply-To: <551A4E93.1030309@hitachi.com> References: <20150327213704.857765144@goodmis.org> <5518C527.7020101@hitachi.com> <20150330100743.0fac7066@gandalf.local.home> <551A4E93.1030309@hitachi.com> X-Mailer: Claws Mail 3.11.1 (GTK+ 2.24.25; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 31 Mar 2015 16:36:51 +0900 Masami Hiramatsu wrote: > > Instead of adding an enum mapping file, I could add a way to look at > > all the events in the system that defined a mapping, and do a > > "s/ENUM_NAME/ENUM_VALUE/g" do the saved print formats? I'm not sure how > > much we want to do that in the kernel though. > > No, it's not what I expected... Actually, I'm going to play with this idea and see how crazy it is or isn't. Converting the ENUMS in TP_printk() might actually be doable. I'll write up some code and we can see if it seems sane or not. OK? > > What I thought was expanding __print_symbolic() macro in TP_printk > with a special hash string(start with #), and when showing it via > event/format, replace the hash string with the strings generated > by the map of symbols. This will introduce a small overhead to show > the format as a side effect. > > Actually I even have not tried, so it's just an idea yet. > If you can figure something out, please let me know! Thanks, -- Steve