Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757361AbbLBMpm (ORCPT ); Wed, 2 Dec 2015 07:45:42 -0500 Received: from bombadil.infradead.org ([198.137.202.9]:50070 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755059AbbLBMpk (ORCPT ); Wed, 2 Dec 2015 07:45:40 -0500 Date: Wed, 2 Dec 2015 13:45:31 +0100 From: Peter Zijlstra To: Frederic Weisbecker Cc: LKML , Chris Metcalf , Thomas Gleixner , Luiz Capitulino , Christoph Lameter , Ingo Molnar , Viresh Kumar , Rik van Riel Subject: Re: [PATCH 2/7] nohz: New tick dependency mask Message-ID: <20151202124531.GC9928@worktop.ger.corp.intel.com> References: <1447424529-13671-1-git-send-email-fweisbec@gmail.com> <1447424529-13671-3-git-send-email-fweisbec@gmail.com> <20151201204109.GN17308@twins.programming.kicks-ass.net> <20151201222025.GA31973@lerouge> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20151201222025.GA31973@lerouge> User-Agent: Mutt/1.5.22.1 (2013-10-16) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1180 Lines: 36 On Tue, Dec 01, 2015 at 11:20:28PM +0100, Frederic Weisbecker wrote: > > > +static void trace_tick_dependency(unsigned long dep) > > > +{ > > > + if (dep & TICK_POSIX_TIMER_MASK) { > > > + trace_tick_stop(0, "posix timers running\n"); > > > + return; > > > + } > > > + > > > + if (dep & TICK_PERF_EVENTS_MASK) { > > > + trace_tick_stop(0, "perf events running\n"); > > > + return; > > > + } > > > + > > > + if (dep & TICK_SCHED_MASK) { > > > + trace_tick_stop(0, "more than 1 task in runqueue\n"); > > > + return; > > > + } > > > + > > > + if (dep & TICK_CLOCK_UNSTABLE_MASK) > > > + trace_tick_stop(0, "unstable sched clock\n"); > > > +} > > > > I would suggest ditching the strings and using the > > Using a code value instead? Duh, it seems I forgot to finish that sentence :/ I meant to say use the ftrace enum stuff. So yes, you encode a value and the ftrace printing muck will generate a string if and when required. -- 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/