Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753102AbbDCFKL (ORCPT ); Fri, 3 Apr 2015 01:10:11 -0400 Received: from terminus.zytor.com ([198.137.202.10]:43078 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752339AbbDCFKI (ORCPT ); Fri, 3 Apr 2015 01:10:08 -0400 Date: Thu, 2 Apr 2015 22:09:49 -0700 From: tip-bot for Yunlong Song Message-ID: Cc: paulus@samba.org, hpa@zytor.com, linux-kernel@vger.kernel.org, wangnan0@huawei.com, mingo@kernel.org, yunlong.song@huawei.com, acme@redhat.com, tglx@linutronix.de, a.p.zijlstra@chello.nl Reply-To: hpa@zytor.com, paulus@samba.org, mingo@kernel.org, wangnan0@huawei.com, linux-kernel@vger.kernel.org, tglx@linutronix.de, acme@redhat.com, yunlong.song@huawei.com, a.p.zijlstra@chello.nl In-Reply-To: <1427982439-27388-8-git-send-email-yunlong.song@huawei.com> References: <1427982439-27388-8-git-send-email-yunlong.song@huawei.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:perf/core] perf script: Support using -f to override perf.data file ownership Git-Commit-ID: 06af0f2c919d7c8f05efebe0d96a6f22297aafd4 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 5171 Lines: 125 Commit-ID: 06af0f2c919d7c8f05efebe0d96a6f22297aafd4 Gitweb: http://git.kernel.org/tip/06af0f2c919d7c8f05efebe0d96a6f22297aafd4 Author: Yunlong Song AuthorDate: Thu, 2 Apr 2015 21:47:16 +0800 Committer: Arnaldo Carvalho de Melo CommitDate: Thu, 2 Apr 2015 13:18:50 -0300 perf script: Support using -f to override perf.data file ownership Enable perf script to use perf.data when it is not owned by current user or root. Change the short option name of --fields to -F to avoid confusion with --force. Example: # perf record ls # chown Yunlong.Song:Yunlong.Song perf.data # ls -al perf.data -rw------- 1 Yunlong.Song Yunlong.Song 28360 Apr 2 14:53 perf.data # id uid=0(root) gid=0(root) groups=0(root),64(pkcs11) Before this patch: # perf script File perf.data not owned by current user or root (use -f to override) # perf script -f Error: switch `f' requires a value usage: perf script [] or: perf script [] record