Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp879862rwd; Thu, 15 Jun 2023 03:27:52 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6aVxWAHUkXXsQ5UHrOugDHnp39QmD39nVh9HKawlu5X1ak4sq5xonFkRCamobUBEqlJ1j4 X-Received: by 2002:a05:6830:2081:b0:6b2:9bdb:a84a with SMTP id y1-20020a056830208100b006b29bdba84amr14304485otq.32.1686824872759; Thu, 15 Jun 2023 03:27:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686824872; cv=none; d=google.com; s=arc-20160816; b=ahjr3HW4JRApWXnxKE6tynoufBeBJDYy+utP8Rvw7bpIl41EYhVIDwChwN7375PsJi o9rsua34rrFfWz15zmCSQXX7KNigzcLkfe9lqWr+qERdHLQvQxIXchsLEPU3cf4f8BZk WT49UMesfHM6Q5zSvkcJVAvtciO0yg/p6ID7d1z49R1CfwhPQwbng9w+og5RwL0KDPJq RCm1AKatUlrs63utqBL2RrMPLn12qLok6IzfQ9ztMrAcn6ql0MNOgTMmZF17FkjFin7B ++xVYdp2y9QdUe+VuN8u1qwSDOZ9JjJS5aM+qXI00rL/7U4N1ENa1yqDjy34SVH4cO8Q Wzew== 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:content-language:subject:user-agent:mime-version :date:message-id; bh=UsXbRmUR74gckcKUWu1gluUWRdLRhQL3JB898YtVzlI=; b=N5Nc+TMFUDbeuV3F8ZFjZvBGRQTCaRAqnkG0U0vJ2l3i3gjG6H3KYRjwuMf8hXRYkM NLyMLJ1Kr57Yk+7cgidBltxVqSM6AsYKGq76NUv4mme4ddjrkjDodK6kHfKi/vueXj0Q HMYPoMbjKxwr/tABfC9bfEet2ElQtc+DVAYLrir3cIzrQQxXZ0+ak9uVU5UC/FQ95nUI DkSmduR4qTub0c9tMM1LUdz5NXy9A7LmqyEqNdlgDbvkzZ9MsbhzUaDn7LphKbjMoM0B ZTqMVAfyWKPfd8y7t0DTehOTIGwGBeF4uDL+KzATE1CDszT9eobtLY8l/+OZbAVRubcx CUsA== 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id g9-20020a633749000000b005344b60f7ddsi12197505pgn.117.2023.06.15.03.27.40; Thu, 15 Jun 2023 03:27:52 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S245214AbjFOKCm (ORCPT + 99 others); Thu, 15 Jun 2023 06:02:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56024 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238766AbjFOKCk (ORCPT ); Thu, 15 Jun 2023 06:02:40 -0400 Received: from relay9-d.mail.gandi.net (relay9-d.mail.gandi.net [IPv6:2001:4b98:dc4:8::229]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1017195; Thu, 15 Jun 2023 03:02:35 -0700 (PDT) X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr X-GND-Sasl: alex@ghiti.fr Received: by mail.gandi.net (Postfix) with ESMTPSA id AA24FFF805; Thu, 15 Jun 2023 10:02:28 +0000 (UTC) Message-ID: <35dc3141-ac83-791c-7439-1c1f25ca95e8@ghiti.fr> Date: Thu, 15 Jun 2023 12:02:28 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.11.0 Subject: Re: [PATCH v2 10/10] perf: tests: Adapt mmap-basic.c for riscv Content-Language: en-US To: Andrew Jones , Alexandre Ghiti Cc: Jonathan Corbet , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , Namhyung Kim , Ian Rogers , Paul Walmsley , Palmer Dabbelt , Albert Ou , Atish Patra , Anup Patel , Will Deacon , Rob Herring , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-perf-users@vger.kernel.org, linux-riscv@lists.infradead.org, linux-arm-kernel@lists.infradead.org References: <20230512085321.13259-1-alexghiti@rivosinc.com> <20230512085321.13259-11-alexghiti@rivosinc.com> <20230531-31bd9ddeaca8cb338f81ed14@orel> From: Alexandre Ghiti In-Reply-To: <20230531-31bd9ddeaca8cb338f81ed14@orel> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,NICE_REPLY_A, RCVD_IN_DNSWL_LOW,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 31/05/2023 17:15, Andrew Jones wrote: > On Fri, May 12, 2023 at 10:53:21AM +0200, Alexandre Ghiti wrote: >> riscv now supports mmaping hardware counters to userspace so adapt the test >> to run on this architecture. >> >> Signed-off-by: Alexandre Ghiti >> --- >> tools/perf/tests/mmap-basic.c | 4 ++-- >> 1 file changed, 2 insertions(+), 2 deletions(-) >> >> diff --git a/tools/perf/tests/mmap-basic.c b/tools/perf/tests/mmap-basic.c >> index e68ca6229756..f5075ca774f8 100644 >> --- a/tools/perf/tests/mmap-basic.c >> +++ b/tools/perf/tests/mmap-basic.c >> @@ -284,7 +284,7 @@ static struct test_case tests__basic_mmap[] = { >> "permissions"), >> TEST_CASE_REASON("User space counter reading of instructions", >> mmap_user_read_instr, >> -#if defined(__i386__) || defined(__x86_64__) || defined(__aarch64__) >> +#if defined(__i386__) || defined(__x86_64__) || defined(__aarch64__) || __riscv_xlen == 64 >> "permissions" >> #else >> "unsupported" >> @@ -292,7 +292,7 @@ static struct test_case tests__basic_mmap[] = { >> ), >> TEST_CASE_REASON("User space counter reading of cycles", >> mmap_user_read_cycles, >> -#if defined(__i386__) || defined(__x86_64__) || defined(__aarch64__) >> +#if defined(__i386__) || defined(__x86_64__) || defined(__aarch64__) || __riscv_xlen == 64 >> "permissions" >> #else >> "unsupported" >> -- >> 2.37.2 >> > Reviewed-by: Andrew Jones Thanks for your review Andrew, as usual, always helpful. And sorry for the delay! Alex > > _______________________________________________ > linux-riscv mailing list > linux-riscv@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-riscv