From nobody Fri Dec 19 04:02:25 2025 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 17F248172A; Mon, 29 Apr 2024 15:23:43 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714404225; cv=none; b=KhGHv+wWhxjjJTBL6bq18GOwsOFoLyOWBc5R0t3Hyr30YtR3+lnWDP1ZFu4aH0HDs+qkPdHBbWekiHQEZlhWRD98WbL8cX9qUYv0+GKTHC/y4QdwzcEWuyYcUomy1qa0P4ZCLUmr72lSUyjT1KuKftXc5O36DdBkzQkyq3dYYkE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714404225; c=relaxed/simple; bh=NZYQS9DoJX1Ne9ARwerYzJ7WRfVLN4BYuXhHYJnCE2k=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=XBj1Loyt5FvCc6aBvsz0izbjB4mNSdytbgVqbLXUPXEku+B3YbSiu0hmObjzy2zDB73lIVCh7qx402IEvmf4rR6U07UIs/LK6GTQqxUnJTB2Q9oV64RJCm8bOXKnHe8AwilPWr4JjTJW7jVZ7fzyz0w2dteUfhpv8BJONHAfH4o= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com; spf=pass smtp.mailfrom=arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=arm.com 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 2A97A339; Mon, 29 Apr 2024 08:24:10 -0700 (PDT) Received: from e127643.broadband (usa-sjc-mx-foss1.foss.arm.com [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 512CA3F793; Mon, 29 Apr 2024 08:23:40 -0700 (PDT) From: James Clark To: linux-perf-users@vger.kernel.org, gankulkarni@os.amperecomputing.com, scclevenger@os.amperecomputing.com, coresight@lists.linaro.org, suzuki.poulose@arm.com, mike.leach@linaro.org Cc: James Clark , 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 Subject: [PATCH 01/17] perf cs-etm: Print error for new PERF_RECORD_AUX_OUTPUT_HW_ID versions Date: Mon, 29 Apr 2024 16:21:46 +0100 Message-Id: <20240429152207.479221-2-james.clark@arm.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240429152207.479221-1-james.clark@arm.com> References: <20240429152207.479221-1-james.clark@arm.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" 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 per= f_session *session, trace_chan_id =3D FIELD_GET(CS_AUX_HW_ID_TRACE_ID_MASK, hw_id); =20 /* 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 suppor= ted. Please update Perf.\n", + version); return -EINVAL; + } =20 /* get access to the etm metadata */ etm =3D container_of(session->auxtrace, struct cs_etm_auxtrace, auxtrace); --=20 2.34.1