Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp451557rwl; Wed, 29 Mar 2023 04:25:07 -0700 (PDT) X-Google-Smtp-Source: AKy350Zf8o5Ym56HWTnvFEyt4Y4OsbsfW/SlUbQHeOfbzJD9oGhYAvVzvKaPU5EXti79eoZGooxU X-Received: by 2002:a17:902:b10b:b0:1a1:8007:d370 with SMTP id q11-20020a170902b10b00b001a18007d370mr1676044plr.33.1680089107150; Wed, 29 Mar 2023 04:25:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680089107; cv=none; d=google.com; s=arc-20160816; b=bduZE7FVVXQGzkQuHEsr42MSrXrefSvHfU0qGvdxq8nDYn8V/qy6Frt0uThNO4n87l iboGHURftCyI8sRbwSNjneP/QceDkJX2/dlaIO3hCskrC1AcixgtEwwve3ZipYbl4+NA zR9VrNYponpem6H2857cXWZHQerFzww5yRcPuJFL29XCaVU6nOEofGpWoyrRui4aB9/W 6WXeRAHcbcf+SqAKcT5w1KL656sKCFWUU+vVbfPSmi5ViMdtdFFAKvP2/YGYk3mlLAQz 9nnURUrV0a/I5nWH1NRvbYeO1jMUSqcyIkroh0J2b0AjaOwV2th8TN8vnyM0Ld0AfL6I /c2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:subject:user-agent:mime-version:date:message-id; bh=Sek9BBRExoouP0kRnOQWbgqzpTbhdnxC+fUgdggLSuo=; b=G84Et5Pv9UiBE/DZdf4UbCFb/xd7XQcGJQ9S7DZ0v1tYVwCjd5C9iPZmzKea6KCgZo tZFayqJTKPGWiaJpkTxOC5+21woBylg0luM37L1oXUXOyqghZJYJaASHShf0sjAXoc3F C3jJCVebx4I2/ctCKYu4wQRXaVihaL4/VXUb4Y3yD/OrrOL2VbRIb7qohMiQQ4VYwJ5D wNoqLr10bXec+BML75RIonwLFsqUsylnFDqBWHjYqVyCzTnOVgbQCKfLZl7xjR7Bcx93 LgMdVmZfTia0EkkQmIkECP/xgLep9lqi3TKzyoqylOiWjcH1itfjFbHhhUc1r08l4kj0 jGOQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id w2-20020a170902e88200b001a1dc272022si22913846plg.22.2023.03.29.04.24.55; Wed, 29 Mar 2023 04:25:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=arm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229754AbjC2LSr (ORCPT + 99 others); Wed, 29 Mar 2023 07:18:47 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48970 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229747AbjC2LSl (ORCPT ); Wed, 29 Mar 2023 07:18:41 -0400 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 07F664213; Wed, 29 Mar 2023 04:18:32 -0700 (PDT) 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 DB1C01FB; Wed, 29 Mar 2023 04:19:15 -0700 (PDT) Received: from [10.57.56.86] (unknown [10.57.56.86]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 281783F73F; Wed, 29 Mar 2023 04:18:29 -0700 (PDT) Message-ID: <0ada81b0-42d7-a9fe-41ff-9476b4b68ee0@arm.com> Date: Wed, 29 Mar 2023 12:18:27 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:102.0) Gecko/20100101 Thunderbird/102.9.0 Subject: Re: [PATCH v8 0/3] perf: cs-etm: Update perf to handle new Coresight Trace ID To: Mike Leach , linux-perf-users@vger.kernel.org, linux-arm-kernel@lists.infradead.org, coresight@lists.linaro.org, linux-kernel@vger.kernel.org, acme@kernel.org Cc: leo.yan@linaro.org, peterz@infradead.org, mingo@redhat.com, will@kernel.org, john.garry@huawei.com, mark.rutland@arm.com, alexander.shishkin@linux.intel.com, jolsa@redhat.com, namhyung@kernel.org, gankulkarni@os.amperecomputing.com, darren@os.amperecomputing.com References: <20230329111422.3693-1-mike.leach@linaro.org> From: Suzuki K Poulose In-Reply-To: <20230329111422.3693-1-mike.leach@linaro.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.3 required=5.0 tests=NICE_REPLY_A, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_NONE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Arnaldo, On 29/03/2023 12:14, Mike Leach wrote: > The original method for allocating trace source ID values to sources was > to use a fixed algorithm for CPU based sources of (cpu_num * 2 + 0x10). > The STM was allocated ID 0x1. > > This mechanism is broken for systems with more than 47 cores. > > The kernel related patches the provide a fixed Trace ID allocation mechanism > are now upstreamed. > > This patchset updates the perf code to handle the changes to the trace ID > notification mechanism that now uses the PERF_RECORD_AUX_OUTPUT_HW_ID > packet to set Trace ID in the perf ETM decoders. > > Applies to perf/core > > Changes since v7: > Split from original patchset [1] to be sent separately as kernel related > patches are now upstream. Please could you pull this in ? This is critical for enabling the CoreSight perf support on systems with > 47 cores. The kernel changes are already in. Suzuki > > [1] https://lore.kernel.org/linux-arm-kernel/20230116124928.5440-1-mike.leach@linaro.org/ > > Mike Leach (3): > perf: cs-etm: Move mapping of Trace ID and cpu into helper function > perf: cs-etm: Update record event to use new Trace ID protocol > perf: cs-etm: Handle PERF_RECORD_AUX_OUTPUT_HW_ID packet > > tools/include/linux/coresight-pmu.h | 47 ++- > tools/perf/arch/arm/util/cs-etm.c | 21 +- > .../perf/util/cs-etm-decoder/cs-etm-decoder.c | 7 + > tools/perf/util/cs-etm.c | 326 +++++++++++++++--- > tools/perf/util/cs-etm.h | 14 +- > 5 files changed, 350 insertions(+), 65 deletions(-) >