From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751288AbdJDT21 (ORCPT ); Wed, 4 Oct 2017 15:28:27 -0400 Received: from mail.kernel.org ([198.145.29.99]:58096 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750787AbdJDT2Z (ORCPT ); Wed, 4 Oct 2017 15:28:25 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org DD7AD20C01 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=goodmis.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=rostedt@goodmis.org Date: Wed, 4 Oct 2017 15:28:22 -0400 From: Steven Rostedt To: Tom Zanussi Cc: tglx@linutronix.de, mhiramat@kernel.org, namhyung@kernel.org, vedang.patel@intel.com, bigeasy@linutronix.de, joel.opensrc@gmail.com, joelaf@google.com, mathieu.desnoyers@efficios.com, baohong.liu@intel.com, rajvi.jingar@intel.com, linux-kernel@vger.kernel.org, linux-rt-users@vger.kernel.org Subject: Re: [PATCH v3 25/33] tracing: Allow whitespace to surround hist trigger filter Message-ID: <20171004152822.060e3833@gandalf.local.home> In-Reply-To: <1507143917.14461.8.camel@tzanussi-mobl.amr.corp.intel.com> References: <68a176facc91c86e90862f3e719c6bf57f505340.1506105131.git.tom.zanussi@linux.intel.com> <20171004141105.4f88f44f@gandalf.local.home> <1507143917.14461.8.camel@tzanussi-mobl.amr.corp.intel.com> X-Mailer: Claws Mail 3.14.0 (GTK+ 2.24.31; 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 Wed, 04 Oct 2017 14:05:17 -0500 Tom Zanussi wrote: > Hi Steve, > > On Wed, 2017-10-04 at 14:11 -0400, Steven Rostedt wrote: > > On Fri, 22 Sep 2017 15:00:05 -0500 > > Tom Zanussi wrote: > > > > > The existing code only allows for one space before and after the 'if' > > > specifying the filter for a hist trigger. Add code to make that more > > > permissive as far as whitespace goes. Specifically, we want to allow > > > spaces in the trigger itself now that we have additional syntax > > > (onmatch/onmax) where spaces are more natural e.g. spaces after commas > > > in param lists. > > > > > > > > > I think you forgot to update this: > > > > I was going to but on closer inspection realized the simpler form > wouldn't accomplish the same thing - the problem this is trying to solve > is to allow bits of whitespace within the trigger (because we now have > function-like syntax, which should allow whitespace after commas for > instance) and separating the trigger from the filter ('if'). So we > explicitly search for 'if' with preceding whitespace, which strsep won't > accomplish. > > So while it may not be pretty, it accomplishes that, while the below > won't (it would create a truncated trigger if there were e.g. commas > followed by spaces). OK, and I just noticed that you updated the changelog too, which sorta describes what you are trying to say here. -- Steve