From 44f7e432e3dc8a13f5661e8b722f53645df083d1 Mon Sep 17 00:00:00 2001 From: Yunlong Song Date: Thu, 2 Apr 2015 21:47:17 +0800 Subject: [PATCH] perf timechart: Support using -f to override perf.data file ownership Enable perf timechart to use perf.data when it is not owned by current user or root. Example: # perf timechart record ls # chown Yunlong.Song:Yunlong.Song perf.data # ls -al perf.data -rw------- 1 Yunlong.Song Yunlong.Song 5471744 Apr 2 15:15 perf.data # id uid=0(root) gid=0(root) groups=0(root),64(pkcs11) Before this patch: # perf timechart File perf.data not owned by current user or root (use -f to override) # perf timechart -f Error: unknown switch `f' usage: perf timechart [] {record} -i, --input input file name -o, --output output file name -w, --width page width --highlight highlight tasks. Pass duration in ns or process name. -P, --power-only output power data only -T, --tasks-only output processes data only -p, --process process selector. Pass a pid or process name. --symfs Look for files with symbols relative to this directory -n, --proc-num min. number of tasks to print -t, --topology sort CPUs according to topology --io-skip-eagain skip EAGAIN errors --io-min-time