From patchwork Mon Dec 12 15:55:10 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Clark X-Patchwork-Id: 32430 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp2325762wrr; Mon, 12 Dec 2022 08:06:31 -0800 (PST) X-Google-Smtp-Source: AA0mqf5jngWpg/V8du41iG6qwVeXlY7zB6T7b2s1MEHBQVJwylPOkhNziNe712c22tSOovh7p1dy X-Received: by 2002:a17:906:895:b0:7bd:27af:396e with SMTP id n21-20020a170906089500b007bd27af396emr12784678eje.45.1670861191244; Mon, 12 Dec 2022 08:06:31 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1670861191; cv=none; d=google.com; s=arc-20160816; b=Vw9oMGGigDa8sPS6wgjJSpZ7+6ROBAJpiSlIRi473irAEEXLRxhQcYf2YyFtLWXAfW kfhbvRVm7D2QJlxTp+f9UqMJQmbgUjFxiDJd1fOqEvRbiH97XIpdnNvKhLDOUolNOlOy viG9amMVtkoz6y04FFwV3S+YZp4gZAxJ7n14oRUDR2uAA4ph43oAR3qfJ+I94aKs76R+ hCTQ2rimjB5O6DrJyv6oU8vqbxitJmWorNvC75asRq06VyaQ+Kew7r5DQP4+AxI3ZjDL gp/alYcweGpCDVPUNkoEuk6RvAgjuQbuAkRrt3PBTVYS5r5bt9aOnnlMVs1WawxGVWpH K4sQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=7j51waBXT/TsfiBWTW7La16md0bd0IliUIeho55WwM0=; b=r7pJ/2kxKdo5Aa8S2Q4oycFoIQ2c5jlWmh06dVnQY8/qezZ3iL0Se4izkw2Nhp5KCS Kkj5+UkjRWiBRE3lZk5QuW2X1sXGpmHA+76TzsEAAc9bNCb1W11u/Kck0iPJdsic2zCo 0OuWY8veOAb5Q6GG7n2phDZzDjBzAWDgcmGbjClApCpM5l7NuOjUu3BmpAsr6pti0zJ6 q/d+bG1N3FSMcw5Lkjsg3dQY8eKis3HKU83ktbp3fxjMClZz9DSsHlH4WlrAMtZpecNK Rd3auSRNKWzT6+AtoIuW/SpR4Vtqgol3FudbdYb2Pwu+eFyt5zfWLo7F4vm1PIw7qrLS bAhA== 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 Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hw19-20020a170907a0d300b0078d288ddfc9si5070918ejc.143.2022.12.12.08.06.07; Mon, 12 Dec 2022 08:06:31 -0800 (PST) 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 S232560AbiLLPzv (ORCPT + 99 others); Mon, 12 Dec 2022 10:55:51 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53456 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232628AbiLLPzr (ORCPT ); Mon, 12 Dec 2022 10:55:47 -0500 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 7476364FA; Mon, 12 Dec 2022 07:55:46 -0800 (PST) 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 B75FF15BF; Mon, 12 Dec 2022 07:56:26 -0800 (PST) Received: from e126815.warwick.arm.com (e126815.arm.com [10.32.32.26]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id B20343F71E; Mon, 12 Dec 2022 07:55:43 -0800 (PST) From: James Clark To: linux-perf-users@vger.kernel.org Cc: Al.Grant@arm.com, James Clark , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , John Garry , Will Deacon , Mike Leach , Leo Yan , Mathieu Poirier , Suzuki K Poulose , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, coresight@lists.linaro.org Subject: [PATCH 2/5] perf: cs-etm: Remove unused stub methods Date: Mon, 12 Dec 2022 15:55:10 +0000 Message-Id: <20221212155513.2259623-3-james.clark@arm.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221212155513.2259623-1-james.clark@arm.com> References: <20221212155513.2259623-1-james.clark@arm.com> MIME-Version: 1.0 X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_NONE autolearn=ham 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1752024944462025713?= X-GMAIL-MSGID: =?utf-8?q?1752024944462025713?= These aren't used outside of cs-etm so don't need stubs. Leave cs_etm__process_auxtrace_info() which is used externally, and add an error message so that it's obvious to users why it causes errors. Signed-off-by: James Clark --- tools/perf/util/cs-etm.h | 34 ++-------------------------------- 1 file changed, 2 insertions(+), 32 deletions(-) diff --git a/tools/perf/util/cs-etm.h b/tools/perf/util/cs-etm.h index 90c83f932d9a..401f74be98d6 100644 --- a/tools/perf/util/cs-etm.h +++ b/tools/perf/util/cs-etm.h @@ -7,6 +7,7 @@ #ifndef INCLUDE__UTIL_PERF_CS_ETM_H__ #define INCLUDE__UTIL_PERF_CS_ETM_H__ +#include "debug.h" #include "util/event.h" #include @@ -218,40 +219,9 @@ static inline int cs_etm__process_auxtrace_info(union perf_event *event __maybe_unused, struct perf_session *session __maybe_unused) { + pr_err("\nCS ETM Trace: OpenCSD is not linked in, please recompile with CORESIGHT=1\n"); return -1; } - -static inline int cs_etm__get_cpu(u8 trace_chan_id __maybe_unused, - int *cpu __maybe_unused) -{ - return -1; -} - -static inline int cs_etm__etmq_set_tid( - struct cs_etm_queue *etmq __maybe_unused, - pid_t tid __maybe_unused, - u8 trace_chan_id __maybe_unused) -{ - return -1; -} - -static inline bool cs_etm__etmq_is_timeless( - struct cs_etm_queue *etmq __maybe_unused) -{ - /* What else to return? */ - return true; -} - -static inline void cs_etm__etmq_set_traceid_queue_timestamp( - struct cs_etm_queue *etmq __maybe_unused, - u8 trace_chan_id __maybe_unused) {} - -static inline struct cs_etm_packet_queue *cs_etm__etmq_get_packet_queue( - struct cs_etm_queue *etmq __maybe_unused, - u8 trace_chan_id __maybe_unused) -{ - return NULL; -} #endif #endif