[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.00.0903100939200.4802@gandalf.stny.rr.com>
Date: Tue, 10 Mar 2009 09:39:52 -0400 (EDT)
From: Steven Rostedt <rostedt@...dmis.org>
To: Andrew Morton <akpm@...ux-foundation.org>
cc: linux-kernel@...r.kernel.org, Ingo Molnar <mingo@...e.hu>,
Thomas Gleixner <tglx@...utronix.de>,
Peter Zijlstra <peterz@...radead.org>,
Frederic Weisbecker <fweisbec@...il.com>,
Theodore Tso <tytso@....edu>,
Arnaldo Carvalho de Melo <acme@...hat.com>,
"H. Peter Anvin" <hpa@...or.com>,
Mathieu Desnoyers <compudj@...stal.dyndns.org>,
Lai Jiangshan <laijs@...fujitsu.com>,
"Martin J. Bligh" <mbligh@...igh.org>,
"Frank Ch. Eigler" <fche@...hat.com>,
KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>,
Larry Woodman <lwoodman@...hat.com>,
Jason Baron <jbaron@...hat.com>,
Tom Zanussi <tzanussi@...il.com>,
Masami Hiramatsu <mhiramat@...hat.com>,
Christoph Hellwig <hch@...radead.org>,
Jiaying Zhang <jiayingz@...gle.com>,
Steven Rostedt <srostedt@...hat.com>
Subject: Re: [PATCH 1/7] tracing: typecast sizeof and offsetof to unsigned
int
On Mon, 9 Mar 2009, Andrew Morton wrote:
> On Tue, 10 Mar 2009 00:57:11 -0400 Steven Rostedt <rostedt@...dmis.org> wrote:
>
> > On x86_64 sizeof and offsetof are treated as long, where as on x86_32
> > they are int. This patch typecasts them to unsigned int to avoid
> > one arch giving warnings while the other does not.
>
> Actually, both have type size_t.
>
> > static int trace_write_header(struct trace_seq *s)
> > {
> > @@ -457,11 +458,11 @@ static int trace_write_header(struct trace_seq *s)
> >
> > /* struct trace_entry */
> > return trace_seq_printf(s,
> > - "\tfield:%s %s;\toffset:%lu;\tsize:%lu;\n"
> > - "\tfield:%s %s;\toffset:%lu;\tsize:%lu;\n"
> > - "\tfield:%s %s;\toffset:%lu;\tsize:%lu;\n"
> > - "\tfield:%s %s;\toffset:%lu;\tsize:%lu;\n"
> > - "\tfield:%s %s;\toffset:%lu;\tsize:%lu;\n"
> > + "\tfield:%s %s;\toffset:%u;\tsize:%u;\n"
> > + "\tfield:%s %s;\toffset:%u;\tsize:%u;\n"
> > + "\tfield:%s %s;\toffset:%u;\tsize:%u;\n"
> > + "\tfield:%s %s;\toffset:%u;\tsize:%u;\n"
> > + "\tfield:%s %s;\toffset:%u;\tsize:%u;\n"
>
> Which may be printed with %z.
That's new to me ;-)
OK, I'll add a patch to my next series.
Thanks,
-- 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