[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.1.10.0902091048310.14528@gandalf.stny.rr.com>
Date: Mon, 9 Feb 2009 10:49:59 -0500 (EST)
From: Steven Rostedt <rostedt@...dmis.org>
To: Eduard - Gabriel Munteanu <eduard.munteanu@...ux360.ro>
cc: mingo@...e.hu, fweisbec@...il.com, penberg@...helsinki.fi,
linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH 2/2] trace: splice support for tracing_pipe
On Mon, 9 Feb 2009, Eduard - Gabriel Munteanu wrote:
> +
> +static ssize_t tracing_splice_read_pipe(struct file *filp,
> + loff_t *ppos,
> + struct pipe_inode_info *pipe,
> + size_t len,
> + unsigned int flags)
> +{
> + struct page *pages[PIPE_BUFFERS];
> + struct partial_page partial[PIPE_BUFFERS];
> + struct trace_iterator *iter = filp->private_data;
> + struct splice_pipe_desc spd = {
> + .pages = pages,
> + .partial = partial,
> + .nr_pages = 0, /* This gets updated below. */
> + .flags = flags,
> + .ops = &tracing_pipe_buf_ops,
> + .spd_release = tracing_spd_release_pipe,
> + };
Note, this is getting a little stack heavy. It is still in bounds,
but I get very nervous when I see structure arrays on the stack.
If either the structure or the array grows large, we can be in trouble.
-- Steve
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists