Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp100434pxk; Wed, 16 Sep 2020 20:17:53 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwbnE6r0Kbz9M0W6RKfEBvuMeggcFa3papShv4qi/HDqou2d1QIP/cDSm7pLUVqdOckTPmq X-Received: by 2002:a50:cf46:: with SMTP id d6mr31192994edk.339.1600312673226; Wed, 16 Sep 2020 20:17:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600312673; cv=none; d=google.com; s=arc-20160816; b=JbgBpya/zIj5omG+ooneShYz2N32dX/YYtocwhafI+NltVmX6S7jYwnzhhJJzBRKNp qa4+UVhESY0jHAyS43vZHLBKvQvCHPlSpmf+3qIGLwNCA1bvJ6dBMgfEGY282QQh8UJA zHm6WznYJL0knT7DHxCC76CWHa5l623JGRl/WdkAZw3aJ9wW8zTiQhuaOVegtmgzTzF3 wn+nlDpG5dApai+iMoGVoNBEaDxHBLtvbt9xQjRl9vieOQbJnhkynrdCru775A4kDpM/ YmE9X0bpkdOWMSoUFvcJX4wwqPhe7GK7q2Ca/dHbwrL4EFs1I6/MawmH8nVi2dzc6mPo V9nA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=Oiee7qifaSng2dID6iHA1B7U4BiqUjihd/ehKTVw8/U=; b=qaUJoeF8Q4wqhqIS0EMnI5IIdWvJcQOTvkC9gsX3R06xV6s0Bw9tdZUzrZhO7IX+sG l+QbrCETx4wwZLex11kH9JcVnaZ4hBELe6twGGHNWBFTjdy4xjPaTuyyEuFjo2i0nLo3 JENfCbdgM6rgApVPz6ERTwm6VkApTU+0n5LChK++V5LrdPyVPBR5AaYcSs0W909F7hk1 Tnq0MSTmBwAYR5DZyrmLbsGt0/99x0odv46IxZC3LY1HyBs9wJYF7kyXT5VP7XyJbxrD l+1UPBhqP57XJR9umfhX7JD1+h5foUEygWuU1JFNu3uZ3CcJNNEENC7ULj6lYcG8pSm+ i8oA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id cb15si13027236ejb.366.2020.09.16.20.17.30; Wed, 16 Sep 2020 20:17:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726118AbgIQDPx (ORCPT + 99 others); Wed, 16 Sep 2020 23:15:53 -0400 Received: from szxga04-in.huawei.com ([45.249.212.190]:12811 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726002AbgIQDPu (ORCPT ); Wed, 16 Sep 2020 23:15:50 -0400 Received: from DGGEMS401-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id 788A67913720DC5DBE00; Thu, 17 Sep 2020 11:15:48 +0800 (CST) Received: from euler.huawei.com (10.175.124.27) by DGGEMS401-HUB.china.huawei.com (10.3.19.201) with Microsoft SMTP Server id 14.3.487.0; Thu, 17 Sep 2020 11:15:41 +0800 From: Wei Li To: Arnaldo Carvalho de Melo , Mark Rutland , Alexander Shishkin , Jiri Olsa , "Namhyung Kim" CC: , , Subject: [PATCH] Revert "perf report: Treat an argument as a symbol filter" Date: Thu, 17 Sep 2020 11:14:14 +0800 Message-ID: <20200917031414.47498-1-liwei391@huawei.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.175.124.27] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Since commit 6db6127c4dad ("perf report: Treat an argument as a symbol filter"), the only one unrecognized argument for perf-report is treated as a symbol filter. This is not described in man page nor help info, and the result is really confusing, especially when it's misspecified by the user (e.g. missing -i for perf.data). As we can use "--symbol-filter=" if we really want to filter a symbol, it may be better to revert this misfeature. Signed-off-by: Wei Li --- tools/perf/builtin-report.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/tools/perf/builtin-report.c b/tools/perf/builtin-report.c index 3c74c9c0f3c3..f57ebc1bcd20 100644 --- a/tools/perf/builtin-report.c +++ b/tools/perf/builtin-report.c @@ -1317,13 +1317,9 @@ int cmd_report(int argc, const char **argv) argc = parse_options(argc, argv, options, report_usage, 0); if (argc) { /* - * Special case: if there's an argument left then assume that - * it's a symbol filter: + * Any (unrecognized) arguments left? */ - if (argc > 1) - usage_with_options(report_usage, options); - - report.symbol_filter_str = argv[0]; + usage_with_options(report_usage, options); } if (annotate_check_args(&report.annotation_opts) < 0) -- 2.17.1