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 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 smtp.lore.kernel.org (Postfix) with ESMTPS id 2F1BBC10F1A for ; Tue, 7 May 2024 10:57:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:From:References:Cc:To: Subject:MIME-Version:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=jIDgIsyooiq696qbJPnRLFzoQyafXpW7HwJPWfSAqfs=; b=NSBM/aZx37kYew rD2xZbmbsS2c5i8TCTxmrYoWLIUCGVneM7yBChff/hyuglDmXTVeNLkBCq1xzstdcXqeiJ6XYIS1S had0wTSLjP9RogzzdlYyRWcgpWWgYKSp9jjVy4FNFzrZfHpan+A0502J7/NNKmYB1etodGo/aCrSN WAFIBnBVgnPSF5SyWQCEbbO8fZN+jpvCPZ9FKgUZfXRcYTR+OT7kcnRnEMn1dS5f4RmVLPWO4rc75 Jh8c4baRnIbL+ulnCfWu/rj29BpVBxBUbOhJY/NkWx+1zJMMtkI7F0cm9tvouWMrbPagni5EVO7ww uTeTUeyt6zCy331Oug/A==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1s4IVt-0000000AdMI-3akh; Tue, 07 May 2024 10:57:37 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1s4IVp-0000000AdJC-2Pcp for linux-arm-kernel@lists.infradead.org; Tue, 07 May 2024 10:57:36 +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 7B5191063; Tue, 7 May 2024 03:57:58 -0700 (PDT) Received: from [10.163.37.41] (unknown [10.163.37.41]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 31DEF3F587; Tue, 7 May 2024 03:57:23 -0700 (PDT) Message-ID: Date: Tue, 7 May 2024 16:27:25 +0530 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 01/17] perf cs-etm: Print error for new PERF_RECORD_AUX_OUTPUT_HW_ID versions Content-Language: en-US To: James Clark Cc: Alexander Shishkin , Maxime Coquelin , Alexandre Torgue , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Namhyung Kim , Mark Rutland , Jiri Olsa , Ian Rogers , Adrian Hunter , John Garry , Will Deacon , Leo Yan , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-perf-users@vger.kernel.org, gankulkarni@os.amperecomputing.com, scclevenger@os.amperecomputing.com, coresight@lists.linaro.org, mike.leach@linaro.org References: <20240429152207.479221-1-james.clark@arm.com> <20240429152207.479221-2-james.clark@arm.com> <08bcd616-5006-45df-b8cc-45cf3a1dd762@arm.com> From: Anshuman Khandual In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240507_035734_016598_88ED311A X-CRM114-Status: GOOD ( 23.96 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 5/7/24 15:36, James Clark wrote: > > > On 07/05/2024 04:47, Anshuman Khandual wrote: >> >> >> On 4/29/24 20:51, James Clark wrote: >>> The likely fix for this is to update Perf so print a helpful message. >>> >>> Signed-off-by: James Clark >>> --- >>> tools/perf/util/cs-etm.c | 5 ++++- >>> 1 file changed, 4 insertions(+), 1 deletion(-) >>> >>> diff --git a/tools/perf/util/cs-etm.c b/tools/perf/util/cs-etm.c >>> index d65d7485886c..32818bd7cd17 100644 >>> --- a/tools/perf/util/cs-etm.c >>> +++ b/tools/perf/util/cs-etm.c >>> @@ -335,8 +335,11 @@ static int cs_etm__process_aux_output_hw_id(struct perf_session *session, >>> trace_chan_id = FIELD_GET(CS_AUX_HW_ID_TRACE_ID_MASK, hw_id); >>> >>> /* check that we can handle this version */ >>> - if (version > CS_AUX_HW_ID_CURR_VERSION) >>> + if (version > CS_AUX_HW_ID_CURR_VERSION) { >>> + pr_err("CS ETM Trace: PERF_RECORD_AUX_OUTPUT_HW_ID version %d not supported. Please update Perf.\n", >> >> Is not this bit misleading ? PERF_RECORD_AUX_OUTPUT_HW_ID is just the perf record >> format identifier. The record version here, is derived from the platform specific >> hardware ID information embedded in this perf record. > > Not sure I follow what you mean here. 'version' is something that's > output by the kernel. It's saved into a perf.data file, and if Perf > can't handle version 2 for example, you need to update Perf. Got it. > >> >> Should not this be just s/PERF_RECORD_AUX_OUTPUT_HW_ID/hardware ID/ instead ? >> > > It's just a way to go from the error message to the part of the code or > docs that you need to look at. "hardware ID" wouldn't lead you anywhere > so I don't think it would be useful. Sure, fair enough. > >>> + version); >>> return -EINVAL; >>> + } >>> >>> /* get access to the etm metadata */ >>> etm = container_of(session->auxtrace, struct cs_etm_auxtrace, auxtrace); >> > _______________________________________________ > CoreSight mailing list -- coresight@lists.linaro.org > To unsubscribe send an email to coresight-leave@lists.linaro.org _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel