Received: by 10.192.165.156 with SMTP id m28csp334807imm; Mon, 16 Apr 2018 00:28:54 -0700 (PDT) X-Google-Smtp-Source: AIpwx48YbkVIXOSSVrK6ydYqHog/kUmWbbgZ+/ph//paD2aHlIa5HnWjyaJG/dO4Lpm1pQEBrL2X X-Received: by 2002:a17:902:264:: with SMTP id 91-v6mr3162399plc.341.1523863733859; Mon, 16 Apr 2018 00:28:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523863733; cv=none; d=google.com; s=arc-20160816; b=fZbE9uJMavBcWMCyqky/tzefTT9CR54iHrcySGsOojjV37nGNvY5gQy9p+ch3+R7Nr F3dk3jENBA4noh8NmYIz2N2iRw+Bzda3yGpqiviqTecsTkcQzHen9gAJ+fkiCwh6mLLS zr5tVMiPz4m15iQQUZSzY41eSfrsnW/bgCpjsoCyRrS8ig62XlLvdiVrrPBzBGTArLR9 8vB5LgIQtXtHEdsJ/X3q3SdvN5CvJMleualN/cAL5+LqggKS/xQwyhh8YU9q/2CWsus7 DYd9weMOU4zBj6l3bRFWGARaDld6x9O56owhIAAvCdUE2N5CUsvJlcjSq64wWCcvQQc/ blyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :from:references:cc:to:subject:arc-authentication-results; bh=W3C0TO9O7I09MPFiqFA2V84IiU24HOGr0lGdLfnMdF8=; b=eR6uvIMIWVEm+GGAPfrIh0H0q+d0W/X7goRVabnSRhgvSn6rcnJ89XBJ/c15oTliKk ISwjHlgQ1a10bt4IZqDuJA5DJT5EUdq5C2ht+ucJUFAOZU0G36dJWv5R34KS25mbIc7F y4J+OclkJzZfl1fEdZiduWIOQGlgmE2PI0vVEYOTZ/2yBgVruSedmZt5yEyFhT0JleGZ fCx4YYCUOWbetk61Un5C2eGsPvSg0a/DCZpcCfuiD1zn0FFL0s8BZCSW84jT15Dl606N 3Ei4JDAD/gGSMrTJ5W5jt4xg7QdToztczDe/eAFpy4fUWe+RYJNasylfnnyTkkN4JsLj 2kEg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a73si10294021pfe.23.2018.04.16.00.28.39; Mon, 16 Apr 2018 00:28:53 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753267AbeDPG5n (ORCPT + 99 others); Mon, 16 Apr 2018 02:57:43 -0400 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:41856 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751325AbeDPG5m (ORCPT ); Mon, 16 Apr 2018 02:57:42 -0400 Received: from pps.filterd (m0098421.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w3G6oFDI133847 for ; Mon, 16 Apr 2018 02:57:41 -0400 Received: from e06smtp15.uk.ibm.com (e06smtp15.uk.ibm.com [195.75.94.111]) by mx0a-001b2d01.pphosted.com with ESMTP id 2hcn50v934-1 (version=TLSv1.2 cipher=AES256-SHA256 bits=256 verify=NOT) for ; Mon, 16 Apr 2018 02:57:41 -0400 Received: from localhost by e06smtp15.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 16 Apr 2018 07:57:39 +0100 Received: from b06cxnps3074.portsmouth.uk.ibm.com (9.149.109.194) by e06smtp15.uk.ibm.com (192.168.101.145) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Mon, 16 Apr 2018 07:57:36 +0100 Received: from d06av26.portsmouth.uk.ibm.com (d06av26.portsmouth.uk.ibm.com [9.149.105.62]) by b06cxnps3074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id w3G6vZRM7274844; Mon, 16 Apr 2018 06:57:35 GMT Received: from d06av26.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 6710DAE055; Mon, 16 Apr 2018 07:47:27 +0100 (BST) Received: from d06av26.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 1955CAE04D; Mon, 16 Apr 2018 07:47:25 +0100 (BST) Received: from [9.124.31.231] (unknown [9.124.31.231]) by d06av26.portsmouth.uk.ibm.com (Postfix) with ESMTP; Mon, 16 Apr 2018 07:47:24 +0100 (BST) Subject: Re: [PATCH 2/3] perf/buildid-cache: Support --list option To: Jiri Olsa Cc: acme@redhat.com, mhiramat@kernel.org, kstewart@linuxfoundation.org, tglx@linutronix.de, pombredanne@nexb.com, linux-kernel@vger.kernel.org, peterz@infradead.org, mingo@redhat.com, alexander.shishkin@linux.intel.com, namhyung@kernel.org, uneedsihyeon@gmail.com, kjlx@templeofstupid.com, ravi Bangoria References: <20180409110633.20767-1-ravi.bangoria@linux.vnet.ibm.com> <20180409110633.20767-3-ravi.bangoria@linux.vnet.ibm.com> <20180413125801.GG28241@krava> From: Ravi Bangoria Date: Mon, 16 Apr 2018 12:27:32 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: <20180413125801.GG28241@krava> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Content-Language: en-US X-TM-AS-GCONF: 00 x-cbid: 18041606-0020-0000-0000-00000412504E X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 18041606-0021-0000-0000-000042A688DE Message-Id: <51d5e4fc-1c8c-96d1-6b60-390d84f2f960@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-04-16_04:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1011 lowpriorityscore=0 impostorscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1709140000 definitions=main-1804160064 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Thanks Jiri for the reviews. Will post v2 soon. -Ravi On 04/13/2018 06:28 PM, Jiri Olsa wrote: > On Mon, Apr 09, 2018 at 04:36:32PM +0530, Ravi Bangoria wrote: > > SNIP > >> - !remove_name_list_str && !purge_name_list_str && >> - !missing_filename && !update_name_list_str)) >> + opts_flag = add_name_list_str || kcore_filename || >> + remove_name_list_str || purge_name_list_str || >> + missing_filename || update_name_list_str; >> + >> + if (argc || !(list_files || opts_flag)) >> usage_with_options(buildid_cache_usage, buildid_cache_options); >> >> + /* -l is exclusive. It can not be used with other options. */ >> + if (list_files && opts_flag) >> + usage_with_options_msg(buildid_cache_usage, >> + buildid_cache_options, "-l is exclusive.\n"); >> + >> if (ns_id > 0) >> nsi = nsinfo__new(ns_id); >> >> @@ -366,6 +396,11 @@ int cmd_buildid_cache(int argc, const char **argv) >> >> setup_pager(); >> >> + if (list_files) { >> + build_id_cache__show_all(); >> + goto out; > make build_id_cache__show_all return value and store it to ret before going out > > jirka >