Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751691AbdIOTPl (ORCPT ); Fri, 15 Sep 2017 15:15:41 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:48552 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751494AbdIOTPk (ORCPT ); Fri, 15 Sep 2017 15:15:40 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org 2E4DA600CE Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=sboyd@codeaurora.org Date: Fri, 15 Sep 2017 12:15:38 -0700 From: Stephen Boyd To: James Morse Cc: Will Deacon , Catalin Marinas , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Tyler Baicar , Jonathan Zhang , Tom Zanussi , Steven Rostedt Subject: Re: [PATCH] arm64: Unconditionally support ARCH_HAVE_NMI_SAFE_CMPXCHG Message-ID: <20170915191538.GD3349@codeaurora.org> References: <20170915011915.7993-1-sboyd@codeaurora.org> <59BC1D7F.4090107@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <59BC1D7F.4090107@arm.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1370 Lines: 35 On 09/15, James Morse wrote: > On 15/09/17 02:19, Stephen Boyd wrote: > > From what I can see there isn't anything about ACPI_APEI_SEA that > > means the arm64 architecture can or cannot support NMI safe > > cmpxchg, so the if condition here is not important. > > Yup, it was to match 'HAVE_NMI', which was new with ACPI_APEI_SEA and pulls in > some printk() stuff. > > ... how come you don't need to change HAVE_NMI too? I didn't change HAVE_NMI because it wasn't needed to get hist triggers working. Sorry, I didn't even notice that HAVE_NMI was also there, probably both of these configs should drop the condition. I'll update the patch to do so. > > > > Let's remove > > it. Doing that allows us to support ftrace histograms via > > CONFIG_HIST_TRIGGERS that depends on the arch having this config > > selected. > > What does CONFIG_HIST_TRIGGERS need this for? I can't see any > cmpxchg use in kernel/trace/trace_events_hist.c True. I think this isn't necessary for CONFIG_HIST_TRIGGERS, but more for CONFIG_TRACING_MAP that is selected and used by CONFIG_HIST_TRIGGERS. We put the dependency in both places so we don't get the trigger config selecting a config that has unmet dependencies. Note there's a cmpxchg in the tracing map code too. -- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project