perf tools: Use O_LARGEFILE to open perf data file
authorXiao Guangrong <xiaoguangrong@cn.fujitsu.com>
Wed, 3 Feb 2010 03:53:14 +0000 (11:53 +0800)
committerIngo Molnar <mingo@elte.hu>
Wed, 3 Feb 2010 08:03:59 +0000 (09:03 +0100)
commitb8f46c5a34fa64fd456295388d18f50ae69d9f37
treecba5da0bb3e4ca5c450df8aaa53fc74945c6fd28
parent59f411b62c9282891274e721fea29026b0eda3cc
perf tools: Use O_LARGEFILE to open perf data file

Open perf data file with O_LARGEFILE flag since its size is
easily larger that 2G.

For example:

 # rm -rf perf.data
 # ./perf kmem record sleep 300

 [ perf record: Woken up 0 times to write data ]
 [ perf record: Captured and wrote 3142.147 MB perf.data
 (~137282513 samples) ]

 # ll -h perf.data
 -rw------- 1 root root 3.1G .....

Signed-off-by: Xiao Guangrong <xiaoguangrong@cn.fujitsu.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
LKML-Reference: <4B68F32A.9040203@cn.fujitsu.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
tools/perf/builtin-record.c
tools/perf/util/header.c
tools/perf/util/session.c
tools/perf/util/trace-event-read.c