aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/trace
diff options
context:
space:
mode:
authorMasami Hiramatsu <masami.hiramatsu.pt@hitachi.com>2012-08-09 08:31:10 -0400
committerRusty Russell <rusty@rustcorp.com.au>2012-09-28 01:35:12 -0400
commitd55cb6cf143ae16eaa415baab520b8eaf4a1012f (patch)
tree449f118e54bc77d753e319fb5a5294611b86c36d /kernel/trace
parentefe75d24a69fc39bb09d882ca2d5b90d4da02afe (diff)
ftrace: Allow stealing pages from pipe buffer
Use generic steal operation on pipe buffer to allow stealing ring buffer's read page from pipe buffer. Note that this could reduce the performance of splice on the splice_write side operation without affinity setting. Since the ring buffer's read pages are allocated on the tracing-node, but the splice user does not always execute splice write side operation on the same node. In this case, the page will be accessed from the another node. Thus, it is strongly recommended to assign the splicing thread to corresponding node. Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt@hitachi.com> Acked-by: Steven Rostedt <rostedt@goodmis.org> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'kernel/trace')
-rw-r--r--kernel/trace/trace.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c
index 5c38c81496ce..adde0994911e 100644
--- a/kernel/trace/trace.c
+++ b/kernel/trace/trace.c
@@ -4195,12 +4195,6 @@ static void buffer_pipe_buf_release(struct pipe_inode_info *pipe,
4195 buf->private = 0; 4195 buf->private = 0;
4196} 4196}
4197 4197
4198static int buffer_pipe_buf_steal(struct pipe_inode_info *pipe,
4199 struct pipe_buffer *buf)
4200{
4201 return 1;
4202}
4203
4204static void buffer_pipe_buf_get(struct pipe_inode_info *pipe, 4198static void buffer_pipe_buf_get(struct pipe_inode_info *pipe,
4205 struct pipe_buffer *buf) 4199 struct pipe_buffer *buf)
4206{ 4200{
@@ -4216,7 +4210,7 @@ static const struct pipe_buf_operations buffer_pipe_buf_ops = {
4216 .unmap = generic_pipe_buf_unmap, 4210 .unmap = generic_pipe_buf_unmap,
4217 .confirm = generic_pipe_buf_confirm, 4211 .confirm = generic_pipe_buf_confirm,
4218 .release = buffer_pipe_buf_release, 4212 .release = buffer_pipe_buf_release,
4219 .steal = buffer_pipe_buf_steal, 4213 .steal = generic_pipe_buf_steal,
4220 .get = buffer_pipe_buf_get, 4214 .get = buffer_pipe_buf_get,
4221}; 4215};
4222 4216