From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.3 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 74AB5C32750 for ; Tue, 13 Aug 2019 11:03:53 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 31A4F2067D for ; Tue, 13 Aug 2019 11:03:53 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="ZQPdhfR2" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 31A4F2067D Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=01zJQtCt5ZM8/tjBxVGi4uvRwKBRm+3oCbW/Eeko+ho=; b=ZQPdhfR2h/UqNi 26yvVaqxMk3nwMb6Sy5bF5EteSJWVUxUXBmNKGqJB8CDVt2YW8iUIkZJhKJd/bmAD/SEg8SLG/MAK Y3AfW8716PeJt+xlVj9pJlArIzS7CDG5DzFAR93exxxfN0zK3dO0JvIsFUNdDBzC8G5YKQ3K3o5nS PL65MjLR5txmBB2g++fupJZZjy/PctS6wtua1/Mkm2/mOAawnFgk/rqB9dqllEp61HDccxQvLOjYC a87BT/C5lI5djJFQ9+/YVyIOrnxSZYYhRsSQYAxN7LhdcGFO596ONeEnmOgQtq8t6HtK1tcP4DrrK j7cQohVIZtpckb5H9xIw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1hxUam-0005TI-Pp; Tue, 13 Aug 2019 11:03:52 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1hxUaj-0005Lw-Tm for linux-arm-kernel@lists.infradead.org; Tue, 13 Aug 2019 11:03:51 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 4CAEB344; Tue, 13 Aug 2019 04:03:49 -0700 (PDT) Received: from lakrids.cambridge.arm.com (usa-sjc-imap-foss1.foss.arm.com [10.121.207.14]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id E76203F694; Tue, 13 Aug 2019 04:03:47 -0700 (PDT) Date: Tue, 13 Aug 2019 12:03:45 +0100 From: Mark Rutland To: Ganapatrao Kulkarni Subject: Re: [PATCH v3 2/2] drivers/perf: Add CCPI2 PMU support in ThunderX2 UNCORE driver. Message-ID: <20190813110345.GD866@lakrids.cambridge.arm.com> References: <1563873380-2003-1-git-send-email-gkulkarni@marvell.com> <1563873380-2003-3-git-send-email-gkulkarni@marvell.com> <20190812120125.GA50712@lakrids.cambridge.arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.11.1+11 (2f07cb52) (2018-12-01) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190813_040350_006416_7D60A8D8 X-CRM114-Status: GOOD ( 21.54 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Ganapatrao Kulkarni , "corbet@lwn.net" , Jan Glauber , "linux-doc@vger.kernel.org" , "linux-kernel@vger.kernel.org" , Robert Richter , Jayachandran Chandrasekharan Nair , "will@kernel.org" , "linux-arm-kernel@lists.infradead.org" Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue, Aug 13, 2019 at 04:25:15PM +0530, Ganapatrao Kulkarni wrote: > Hi Mark, > > On Mon, Aug 12, 2019 at 5:31 PM Mark Rutland wrote: > > > > On Tue, Jul 23, 2019 at 09:16:28AM +0000, Ganapatrao Kulkarni wrote: > > > CCPI2 is a low-latency high-bandwidth serial interface for connecting > > > ThunderX2 processors. This patch adds support to capture CCPI2 perf events. > > > > It would be worth pointing out in the commit message how the CCPI2 > > counters differ from the others. I realise you have that in the body of > > patch 1, but it's critical information when reviewing this patch... > > Ok, I will add in next version. > > > > > > > > Signed-off-by: Ganapatrao Kulkarni > > > --- > > > drivers/perf/thunderx2_pmu.c | 248 ++++++++++++++++++++++++++++++----- > > > 1 file changed, 214 insertions(+), 34 deletions(-) > > > > > > diff --git a/drivers/perf/thunderx2_pmu.c b/drivers/perf/thunderx2_pmu.c > > > index 43d76c85da56..a4e1273eafa3 100644 > > > --- a/drivers/perf/thunderx2_pmu.c > > > +++ b/drivers/perf/thunderx2_pmu.c > > > @@ -17,22 +17,31 @@ > > > */ > > > > > > #define TX2_PMU_MAX_COUNTERS 4 > > > > Shouldn't this be 8 now? > > It is kept unchanged to 4(as suggested by Will), which is same for > both L3 and DMC. > For CCPI2 this macro is not used. Hmmm.... I disagree with that suggestion given that this also affects the active_counters bitmap size (and thus it is not correctly sized as of this patch), and it doesn't really save us much. I think it would be better to bump this to 8 and always update the events array, even though it will be unused for CCPI2. That's less surprising, needs fewer special-cases, and we can use the hrtimer function pointer alone to determine if we need to do any hrtimer work. Thanks, Mark. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel