Received: by 2002:a89:288:0:b0:1f7:eeee:6653 with SMTP id j8csp439882lqh; Tue, 7 May 2024 04:07:15 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWSUskRs2ahtSuLw8YOtP3/r9Uywgk2sXPdvqoIjog/cNmzf4a1kfmnzMhRADCgH1uM/FCWKrLoxk3B8GADJY190Mne5D9ecooFEHwTjQ== X-Google-Smtp-Source: AGHT+IGmPDO+eiskwHilQ9Ahs8WQE3r12p0dXaCvI/EjtDJ3YlrWD0cmyE/gedS19kpNc6hRL273 X-Received: by 2002:a2e:a488:0:b0:2e1:a747:532d with SMTP id h8-20020a2ea488000000b002e1a747532dmr11502812lji.8.1715080035021; Tue, 07 May 2024 04:07:15 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1715080034; cv=pass; d=google.com; s=arc-20160816; b=EgM8BZwpdTu6WiEwChYVq43moJ+iu2M4wReygRtzP/522IP4ObVzSl6sIltyg6p5Gg aznvBLWwJuh4DRNTYgSNohQq7YSJZFvYiSZQA+feAEc1ZIOmDyr19utIPJQgbMe9G865 uJ3rkBhdP0v+wXB0wqWo9wEOsYintnniv6k1lhWSpO0mQPF4qxCnrcqN4rkPE2I7R80k i9K5e7OLvJLl+fdPFy/WSmvWnIKSN6ALNz2MStVDbEwvMk/1+qHQSNiLlwTaCPm/gpJE Md6x0RZjPpxwxYAX54MuuOQFbh1q30PffcrMbnzjZ11gCDKNTXSAVaJ1onI8Q4mNn9aI LxSw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:references:cc:to :content-language:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id; bh=x2EqaS9yY69DyzZUrvBOzlzfITOzrwQ7qxgutAVYhhs=; fh=ThcOFHi9IsZx4ciT2qKHWHAqsOCdupb+2SQNOBVuxgE=; b=uUvvGCbOp0jOBXO4UeHoeeWjQ1wrqsADyZG1ZLvAxcxkUDWcxJR/Zh6sfmr5u5Xcdh uhgMX1tKF1e6Ma1qBJoLyXZ8jAeufFvaJmp/6gaMa2WsBa6AtT6m+fwSpWwrGhs+5Meb IXwOxCxAWHBMt4X7r7qi0Df+yUaaDfMG9KntaZns818h/sVguvIEWm/Dta+urFhdR2Uz DHSiJ7uJ0SHCnm7rfUxUTkcaduiOA5qQ8VfZ2SJn9LxHbgwdDzELadNrjsoXruj6DmNU FqAsitxoMzRvP7u29OyQ2xjzBSC8oS3iOKpDPFKnRrLe1XSDuMrhg16XmSatW/C/oEil klsw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=arm.com dmarc=pass fromdomain=arm.com); spf=pass (google.com: domain of linux-kernel+bounces-171159-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-171159-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id cr20-20020a170906d55400b00a59e7b3ec91si891373ejc.77.2024.05.07.04.07.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 May 2024 04:07:14 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-171159-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=arm.com dmarc=pass fromdomain=arm.com); spf=pass (google.com: domain of linux-kernel+bounces-171159-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-171159-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id D48641F285B8 for ; Tue, 7 May 2024 10:58:31 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1B0011514C6; Tue, 7 May 2024 10:57:35 +0000 (UTC) Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 3881214F9DE; Tue, 7 May 2024 10:57:32 +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=1715079454; cv=none; b=nvNdvP/SHCd/0DDSBTKrDDHTEC2h03c4TrQjVKG4TY6F6a5sBqbxpHwakQ6B1NaPMfxLkf0HfFCPm94XihrSVmKZTkNStADydzrgqXO76RQ8HFolAJeVPwCV95XAnP0WE5NWZ0+StIREHzsoCPhQb6WNj/RNhJb3GUdFMQS5HY4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1715079454; c=relaxed/simple; bh=njXfh2vlNt8e02BLkhSMu8rI1c4JuveTMOFghreNkOc=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=YO4eN2ubfCeMyJgIaqMNXkssV2m7gyuJ0Lj1QlYcymYAHG5t6o1IW1/iXN1Ut5s81HhX9YqtJqiNW3NDSnbgFOyvMC4FPVe5UuTgTPmZ6AwB8xlu2WeHGwk1cWLtuWcZkmH0xwvUHsSGoLo+MRA6ulyxwwVqSzqLx0BQ6zN3a4w= 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 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 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: 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: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit 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