From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754963Ab1LFPaz (ORCPT ); Tue, 6 Dec 2011 10:30:55 -0500 Received: from 173-166-109-252-newengland.hfc.comcastbusiness.net ([173.166.109.252]:40547 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754187Ab1LFPay (ORCPT ); Tue, 6 Dec 2011 10:30:54 -0500 Date: Tue, 6 Dec 2011 10:30:25 -0500 From: Christoph Hellwig To: Wu Fengguang Cc: Andrew Morton , Andi Kleen , Ingo Molnar , Jens Axboe , Steven Rostedt , Peter Zijlstra , Rik van Riel , Linux Memory Management List , linux-fsdevel@vger.kernel.org, LKML Subject: Re: [PATCH 7/9] readahead: add vfs/readahead tracing event Message-ID: <20111206153025.GA18974@infradead.org> References: <20111129130900.628549879@intel.com> <20111129131456.797240894@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20111129131456.797240894@intel.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > + TP_printk("readahead-%s(dev=%d:%d, ino=%lu, " please don't duplicate the tracepoint name in the output string. Also don't use braces, as it jsut complicates parsing. > + "req=%lu+%lu, ra=%lu+%d-%d, async=%d) = %d", > + ra_pattern_names[__entry->pattern], Instead of doing a manual array lookup please use __print_symbolic so that users of the binary interface (like trace-cmd) also get the right output. > --- linux-next.orig/mm/readahead.c 2011-11-29 20:58:53.000000000 +0800 > +++ linux-next/mm/readahead.c 2011-11-29 20:59:20.000000000 +0800 > @@ -29,6 +29,9 @@ static const char * const ra_pattern_nam > [RA_PATTERN_ALL] = "all", > }; > > +#define CREATE_TRACE_POINTS > +#include Maybe we should create a new fs/trace.c just for this instead of stickin it into the first file that created a tracepoint in the "vfs" namespace.