summaryrefslogtreecommitdiffstats
path: root/kernel/module.c
diff options
context:
space:
mode:
authorLai Jiangshan <laijs@cn.fujitsu.com>2009-04-02 09:17:08 +0200
committerIngo Molnar <mingo@elte.hu>2009-04-10 12:44:46 +0200
commit93cfb3c9fd83d877a8f1ffad9ff862b617b32828 (patch)
treea88753a44117b9dcfdd65bb0d0572eb5b945e961 /kernel/module.c
parenttracing: update file->f_pos when splice(2) it (diff)
downloadlinux-93cfb3c9fd83d877a8f1ffad9ff862b617b32828.tar.xz
linux-93cfb3c9fd83d877a8f1ffad9ff862b617b32828.zip
tracing: fix splice return too large
I got these from strace: splice(0x3, 0, 0x5, 0, 0x1000, 0x1) = 12288 splice(0x3, 0, 0x5, 0, 0x1000, 0x1) = 12288 splice(0x3, 0, 0x5, 0, 0x1000, 0x1) = 12288 splice(0x3, 0, 0x5, 0, 0x1000, 0x1) = 16384 splice(0x3, 0, 0x5, 0, 0x1000, 0x1) = 8192 splice(0x3, 0, 0x5, 0, 0x1000, 0x1) = 8192 splice(0x3, 0, 0x5, 0, 0x1000, 0x1) = 8192 I wanted to splice_read 4096 bytes, but it returns 8192 or larger. It is because the return value of tracing_buffers_splice_read() does not include "zero out any left over data" bytes. But tracing_buffers_read() includes these bytes, we make them consistent. Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Steven Rostedt <srostedt@redhat.com> LKML-Reference: <49D46674.9030804@cn.fujitsu.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/module.c')
0 files changed, 0 insertions, 0 deletions