Received: by 2002:a05:6358:e9c4:b0:b2:91dc:71ab with SMTP id hc4csp1506554rwb; Fri, 5 Aug 2022 03:16:18 -0700 (PDT) X-Google-Smtp-Source: AA6agR6xS8fROx0mzpy/vyVf+/n4N9WpeHA9As7TTQwl6ISN96vREyLYHZ5OggMpcqtZEsypmpqp X-Received: by 2002:a17:907:9816:b0:730:73fc:1fae with SMTP id ji22-20020a170907981600b0073073fc1faemr4682075ejc.310.1659694578541; Fri, 05 Aug 2022 03:16:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659694578; cv=none; d=google.com; s=arc-20160816; b=hS5/jjP2rbdn+ZjksEiflvcQAgzKyaILvaF6R9KYY+aivbYMy7OlrgjviyRz0RqzYD cVD8+jPN2oqbsKK+H499hug2qbTTgiQQcNjRQODGS1sH5T+RfFxROyI/Hkg26nm6vOqn Wx8++JLOW1U+/SlYWeGj+jleYqk6knMwJKI392oumrcLXF6lq8WMbbOCSaj1W3LYKGrR FIpuJROjU/VjkuzGfkmU7sZWHRb/SRcBvwlwwV5DM4Ac8eIS2/vxyswuoeE0FqI2N3qP oV4oHoygPKE+/IkPexSTi1V6ahovGhQeWB14nWVPXENr+LHJQBQbcv0DokwHWfz2c01Y 9gPw== 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=yDyDExt7ql6aQ8QyZSJBtEpfAMH5S2JUCiFYyN7/yz4=; b=oq6gI66ffeN0dUSgImKTJDkYFBIfSid5SYgt8N8tB9L4CHPAgtoduiz0udJB6Kr7Gx t2IBRhg/Luecd5a2lxka4/X6a6ZfLrFXu67+dsOFpyktXhcJa+IGofVmy7yMCXsAp/4W U5e9/QeDvbRB2z3PWLq13ljGRf89KxcEcYmOHPQiMKJgSvSRCTvlb5UjLcIiZZrfV635 9QMcfYqxaoNh5L5+ppMhskF2srxIxqinuWHGunZlZNxH7Ip/WDlE8eGtUUUq43jQVBI2 FshKInwAskEQeSdM4EGH3mWATAToVkGJFmy82DMgt8p4SgC7Kyr5mKW84Pd8GJzM5A+g AWyQ== 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g22-20020a170906595600b0073094eb8655si3134978ejr.91.2022.08.05.03.15.52; Fri, 05 Aug 2022 03:16:18 -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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240587AbiHEJz5 (ORCPT + 99 others); Fri, 5 Aug 2022 05:55:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52628 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240580AbiHEJzw (ORCPT ); Fri, 5 Aug 2022 05:55:52 -0400 Received: from frasgout.his.huawei.com (frasgout.his.huawei.com [185.176.79.56]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6222877555; Fri, 5 Aug 2022 02:55:51 -0700 (PDT) Received: from fraeml740-chm.china.huawei.com (unknown [172.18.147.200]) by frasgout.his.huawei.com (SkyGuard) with ESMTP id 4Lzgp52Bmkz67ykV; Fri, 5 Aug 2022 17:50:53 +0800 (CST) Received: from lhrpeml500003.china.huawei.com (7.191.162.67) by fraeml740-chm.china.huawei.com (10.206.15.221) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Fri, 5 Aug 2022 11:55:48 +0200 Received: from [10.126.170.142] (10.126.170.142) by lhrpeml500003.china.huawei.com (7.191.162.67) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.2375.24; Fri, 5 Aug 2022 10:55:47 +0100 Message-ID: Date: Fri, 5 Aug 2022 10:55:50 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.6.1 Subject: Re: [PATCH v4 03/17] perf jevents: Add JEVENTS_ARCH make option To: Ian Rogers , Will Deacon , "James Clark" , Mike Leach , Leo Yan , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , "Namhyung Kim" , Andi Kleen , Zhengjun Xing , Ravi Bangoria , "Kan Liang" , Adrian Hunter , , , CC: Stephane Eranian References: <20220804221816.1802790-1-irogers@google.com> <20220804221816.1802790-4-irogers@google.com> From: John Garry In-Reply-To: <20220804221816.1802790-4-irogers@google.com> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.126.170.142] X-ClientProxiedBy: lhreml704-chm.china.huawei.com (10.201.108.53) To lhrpeml500003.china.huawei.com (7.191.162.67) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,NICE_REPLY_A, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE 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 On 04/08/2022 23:18, Ian Rogers wrote: > Allow the architecture built into pmu-events.c to be set on the make > command line with JEVENTS_ARCH. > > Signed-off-by: Ian Rogers Seems reasonable, so: Reviewed-by: John Garry I assume that if we run on the wrong arch (than we build for) then it has same effect as if pmu-events is not supported. > --- > tools/perf/pmu-events/Build | 6 +++++- > 1 file changed, 5 insertions(+), 1 deletion(-) > > diff --git a/tools/perf/pmu-events/Build b/tools/perf/pmu-events/Build > index 28a9d01b08af..04ef95174660 100644 > --- a/tools/perf/pmu-events/Build > +++ b/tools/perf/pmu-events/Build > @@ -7,6 +7,10 @@ JSON_TEST = $(shell [ -d $(JDIR_TEST) ] && \ > find $(JDIR_TEST) -name '*.json') > JEVENTS_PY = pmu-events/jevents.py > > +ifeq ($(JEVENTS_ARCH),) > +JEVENTS_ARCH=$(SRCARCH) > +endif > + > # > # Locate/process JSON files in pmu-events/arch/ > # directory and create tables in pmu-events.c. > @@ -19,5 +23,5 @@ $(OUTPUT)pmu-events/pmu-events.c: pmu-events/empty-pmu-events.c > else > $(OUTPUT)pmu-events/pmu-events.c: $(JSON) $(JSON_TEST) $(JEVENTS_PY) > $(call rule_mkdir) > - $(Q)$(call echo-cmd,gen)$(PYTHON) $(JEVENTS_PY) $(SRCARCH) pmu-events/arch $@ > + $(Q)$(call echo-cmd,gen)$(PYTHON) $(JEVENTS_PY) $(JEVENTS_ARCH) pmu-events/arch $@ > endif