[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.1.10.0809261549150.21618@gandalf.stny.rr.com>
Date: Fri, 26 Sep 2008 15:52:14 -0400 (EDT)
From: Steven Rostedt <rostedt@...dmis.org>
To: Martin Bligh <mbligh@...gle.com>
cc: Peter Zijlstra <peterz@...radead.org>,
LKML <linux-kernel@...r.kernel.org>, Ingo Molnar <mingo@...e.hu>,
Thomas Gleixner <tglx@...utronix.de>,
Andrew Morton <akpm@...ux-foundation.org>,
prasad@...ux.vnet.ibm.com,
Linus Torvalds <torvalds@...ux-foundation.org>,
Mathieu Desnoyers <compudj@...stal.dyndns.org>,
"Frank Ch. Eigler" <fche@...hat.com>,
David Wilder <dwilder@...ibm.com>, hch@....de,
Christoph Hellwig <hch@...radead.org>,
Masami Hiramatsu <mhiramat@...hat.com>,
Steven Rostedt <srostedt@...hat.com>,
Arnaldo Carvalho de Melo <acme@...stprotocols.net>
Subject: Re: [PATCH v6] Unified trace buffer
On Fri, 26 Sep 2008, Martin Bligh wrote:
> On Fri, Sep 26, 2008 at 11:59 AM, Peter Zijlstra <peterz@...radead.org> wrote:
> > On Fri, 2008-09-26 at 14:05 -0400, Steven Rostedt wrote:
> >
> >> +struct buffer_page {
> >> + u64 time_stamp;
> >> + unsigned char body[];
> >> +};
> >> +
> >> +#define BUF_PAGE_SIZE (PAGE_SIZE - sizeof(u64))
> >
> > Since you're already using the page frame, you can stick this per page
> > timestamp in there as well, and get the full page for data.
> >
> > You can either use a struct page overlay like slob does, or add a u64 in
> > the union that contains struct {private, mapping}.
>
> What did you guys think of Mathieu's idea of sticking the buffer length
> in the header here, rather than using padding events? Seemed cleaner
> to me.
Actually I like the padding. This way when I move the event pointer
forward, I only need to compare it to a constant (PAGE_SIZE), or test to
see if the event is padding. Placing this into the buffer page, I will
have to always compare it to that pointer.
But I guess I could change it to that if needed. That doesn't affect the
API, as it is only internal.
I'm almost done with v7, perhaps I might try that with v8 to see if I like
it better.
-- 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