Message ID | 1685440265-7021-4-git-send-email-yangtiezhu@loongson.cn |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp2068593vqr; Tue, 30 May 2023 03:12:29 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5A1bbZyzwEQK6qzFGnysqCW1tFGDx55lThQj5RuoJ21S92qwlTSn4309Kyi4K6E2K6tao0 X-Received: by 2002:a05:6a00:181e:b0:63d:641f:5048 with SMTP id y30-20020a056a00181e00b0063d641f5048mr1988412pfa.16.1685441549172; Tue, 30 May 2023 03:12:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685441549; cv=none; d=google.com; s=arc-20160816; b=BRPrA1xdTtP1lWoWtVQfek8oFPS5jtXJ3bnzwGCi/RRoKYYgO/87D0OyJh7JpqOVGJ SAJCbxux+0hd4dsoOeTbWNnnmJB7Is9REgHPF49t3BbSC1pOuJ22fcP/Ev5jGwZ8UT1A Ndp6RkMsD2bTthUV+PEKmmaSK0CTiGmJrkKy9g+WgyJx8mZ+EFCLzjjg/nxxC7QZQg6n pOeAiqt/koCRF4jFyCUfQFAFJZ6VUWq/Er5T6LvBCxXxDt89ghr5yrm0LIDyb+3thu8N t6g+Hyfj2dOn1MITfXgFsCTnRx0qsBCdcPliatUM5QG3rPFO8YZeCtMbOu2nmNk6UO1N V/GQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:message-id:date:subject :cc:to:from; bh=GQSZK0dxm9oXJ8BBB+Np/iCCgnmIvGHu/PEoNCtAREU=; b=tSvT/vrHs8USnd7BMt2TJSeR19+t0NP5yYscGRVOXRnS6+HBrZObN2FQMjbZnLlb+B gMrqyY3v7oH7nONlTnuGu+KdYSKDDr661KthX9K612i+Hkt2dFCNuBaeJ+0bkHplaoaX AGLsio3IJQoch3+RD6W8Cj4xT37hVJ0pJpnfV0K94BXp02zBOWtSn6Leyfe+RWUa3zSJ erC9pWw5TA/jgKogKvVb8Ek8R6ZhJOgQlOz7UFbIZ3IGyhNmglO9fkIGLfqV/KlZ7bQW btwpjZaw9VFzJzNjWG617b9h9Jg6vd8znGu5e36pwIZ1U786DWVPhP3iiBYN8Jbsqfki 6KiQ== 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 Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u81-20020a627954000000b00643a730d50bsi1470764pfc.389.2023.05.30.03.12.13; Tue, 30 May 2023 03:12:29 -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 S231255AbjE3Jv0 (ORCPT <rfc822;andrewvogler123@gmail.com> + 99 others); Tue, 30 May 2023 05:51:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60006 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231177AbjE3JvO (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 30 May 2023 05:51:14 -0400 Received: from mail.loongson.cn (mail.loongson.cn [114.242.206.163]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id D01E493; Tue, 30 May 2023 02:51:10 -0700 (PDT) Received: from loongson.cn (unknown [113.200.148.30]) by gateway (Coremail) with SMTP id _____8Bx7OoNx3VkX4QCAA--.1286S3; Tue, 30 May 2023 17:51:09 +0800 (CST) Received: from linux.localdomain (unknown [113.200.148.30]) by localhost.localdomain (Coremail) with SMTP id AQAAf8BxWdIJx3VkkmSAAA--.12317S5; Tue, 30 May 2023 17:51:09 +0800 (CST) From: Tiezhu Yang <yangtiezhu@loongson.cn> To: Peter Zijlstra <peterz@infradead.org>, Ingo Molnar <mingo@redhat.com>, Arnaldo Carvalho de Melo <acme@kernel.org>, Mark Rutland <mark.rutland@arm.com>, Alexander Shishkin <alexander.shishkin@linux.intel.com>, Jiri Olsa <jolsa@kernel.org>, Namhyung Kim <namhyung@kernel.org>, Ian Rogers <irogers@google.com>, Adrian Hunter <adrian.hunter@intel.com> Cc: Hans-Peter Nilsson <hp@axis.com>, Alexander Kapshuk <alexander.kapshuk@gmail.com>, Leo Yan <leo.yan@linaro.org>, linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org, loongarch@lists.linux.dev, loongson-kernel@lists.loongnix.cn Subject: [PATCH v3 3/5] perf arm64: Handle __NR3264_ prefixed syscall number Date: Tue, 30 May 2023 17:51:03 +0800 Message-Id: <1685440265-7021-4-git-send-email-yangtiezhu@loongson.cn> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1685440265-7021-1-git-send-email-yangtiezhu@loongson.cn> References: <1685440265-7021-1-git-send-email-yangtiezhu@loongson.cn> X-CM-TRANSID: AQAAf8BxWdIJx3VkkmSAAA--.12317S5 X-CM-SenderInfo: p1dqw3xlh2x3gn0dqz5rrqw2lrqou0/ X-Coremail-Antispam: 1Uk129KBjvJXoW7trWxur1Dtw1xtw4ktF15CFg_yoW8JFW8pw s3C34UtFZ5GF10kw1xur4jqFZ5CF4kJF1UKryjyrW3Crn8J345tr1YqasYkFW7Xw1xK3y5 Zr1FqFy5XF18Xw7anT9S1TB71UUUUbJqnTZGkaVYY2UrUUUUj1kv1TuYvTs0mT0YCTnIWj qI5I8CrVACY4xI64kE6c02F40Ex7xfYxn0WfASr-VFAUDa7-sFnT9fnUUIcSsGvfJTRUUU bSkYFVCjjxCrM7AC8VAFwI0_Jr0_Gr1l1xkIjI8I6I8E6xAIw20EY4v20xvaj40_Wr0E3s 1l1IIY67AEw4v_Jrv_JF1l8cAvFVAK0II2c7xJM28CjxkF64kEwVA0rcxSw2x7M28EF7xv wVC0I7IYx2IY67AKxVW7JVWDJwA2z4x0Y4vE2Ix0cI8IcVCY1x0267AKxVWxJVW8Jr1l84 ACjcxK6I8E87Iv67AKxVWxJr0_GcWl84ACjcxK6I8E87Iv6xkF7I0E14v26rxl6s0DM2kK e7AKxVWUtVW8ZwAS0I0E0xvYzxvE52x082IY62kv0487Mc804VCY07AIYIkI8VC2zVCFFI 0UMc02F40EFcxC0VAKzVAqx4xG6I80ewAv7VC0I7IYx2IY67AKxVWrXVW3AwAv7VC2z280 aVAFwI0_Cr0_Gr1UMcvjeVCFs4IE7xkEbVWUJVW8JwACjcxG0xvY0x0EwIxGrwCY1x0262 kKe7AKxVWUtVW8ZwCF04k20xvY0x0EwIxGrwCFx2IqxVCFs4IE7xkEbVWUJVW8JwCFI7km 07C267AKxVWUtVW8ZwC20s026c02F40E14v26r1j6r18MI8I3I0E7480Y4vE14v26r106r 1rMI8E67AF67kF1VAFwI0_GFv_WrylIxkGc2Ij64vIr41lIxAIcVC0I7IYx2IY67AKxVW7 JVWDJwCI42IY6xIIjxv20xvEc7CjxVAFwI0_Cr0_Gr1UMIIF0xvE42xK8VAvwI8IcIk0rV WUJVWUCwCI42IY6I8E87Iv67AKxVWxJVW8Jr1lIxAIcVC2z280aVCY1x0267AKxVW8JVW8 JrUvcSsGvfC2KfnxnUUI43ZEXa7IUnbAw7UUUUU== X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,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: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1767313557804648453?= X-GMAIL-MSGID: =?utf-8?q?1767313557804648453?= |
Series |
perf tools: Modify mksyscalltbl
|
|
Commit Message
Tiezhu Yang
May 30, 2023, 9:51 a.m. UTC
After commit 9854e7ad35fe ("perf arm64: Simplify mksyscalltbl"), in the generated syscall table file syscalls.c, there exist some __NR3264_ prefixed syscall numbers such as [__NR3264_ftruncate], it looks like not so good, just do some small filter operations to handle __NR3264_ prefixed syscall number as a digital number. Without this patch: [__NR3264_ftruncate] = "ftruncate", With this patch: [46] = "ftruncate", Suggested-by: Alexander Kapshuk <alexander.kapshuk@gmail.com> Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn> Reviewed-by: Leo Yan <leo.yan@linaro.org> --- tools/perf/arch/arm64/entry/syscalls/mksyscalltbl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/tools/perf/arch/arm64/entry/syscalls/mksyscalltbl b/tools/perf/arch/arm64/entry/syscalls/mksyscalltbl index 84976dc..0bcd64a 100755 --- a/tools/perf/arch/arm64/entry/syscalls/mksyscalltbl +++ b/tools/perf/arch/arm64/entry/syscalls/mksyscalltbl @@ -40,6 +40,7 @@ create_table() } $gcc -E -dM -x c -I $incpath/include/uapi $input \ - |sed -ne 's/^#define __NR_//p' \ - |sort -t' ' -k2 -n \ + |awk '$2 ~ "__NR" && $3 !~ "__NR3264_" { + sub("^#define __NR(3264)?_", ""); + print | "sort -k2 -n"}' \ |create_table