[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1260382972.5489.1122.camel@laptop>
Date: Wed, 09 Dec 2009 19:22:52 +0100
From: Peter Zijlstra <peterz@...radead.org>
To: Tony Luck <tony.luck@...el.com>
Cc: Luming Yu <luming.yu@...il.com>, Ingo Molnar <mingo@...e.hu>,
Christoph Hellwig <hch@...radead.org>,
LKML <linux-kernel@...r.kernel.org>,
"linux-ia64@...r.kernel.org" <linux-ia64@...r.kernel.org>,
"Yu, Fenghua" <fenghua.yu@...el.com>,
"Li, Shaohua" <shaohua.li@...el.com>
Subject: Re: [RFC PATCH] Add TRACE_IRQFLAGS_SUPPORT, LOCKDEP_SUPPORT then
enable ftrace for ia64
On Wed, 2009-12-09 at 10:11 -0800, Tony Luck wrote:
> On Wed, Dec 9, 2009 at 12:52 AM, Luming Yu <luming.yu@...il.com> wrote:
> > Commenting out the change make -32 Lockdep kernel boot.
> >
> > Tony, please let me know whether you can reproduce..
>
> Yes. Commenting this out makes the system bootable for me.
>
> > kernel/lockdep.c
> > static int save_trace(struct stack_trace *trace)
> > {
> > trace->nr_entries = 0;
> > trace->max_entries = MAX_STACK_TRACE_ENTRIES - nr_stack_trace_entries;
> > trace->entries = stack_trace + nr_stack_trace_entries;
> >
> > trace->skip = 3;
> >
> > save_stack_trace(trace);
> > #if 0
> >
> > /*
> > * Some daft arches put -1 at the end to indicate its a full trace.
> > *
> > * <rant> this is buggy anyway, since it takes a whole extra entry so a
> > * complete trace that maxes out the entries provided will be reported
> > * as incomplete, friggin useless </rant>
> > */
> > if (trace->entries[trace->nr_entries-1] == ULONG_MAX)
> > trace->nr_entries--;
> > #endif
>
> This happens because ia64 save_stack_trace() is currently an empty stub, so it
> doesn't set trace->nr_entries.
>
> Options:
> 1) Add trace->nr_entries = 1; to ia64 stub.
> 2) Change the generic code to defend against an unexpected failure in
> save_stack_trace()
>
> if (trace->nr_entries > 0 &&
> trace->entries[trace->nr_entries-1] == ULONG_MAX)
> trace->nr_entries--;
> 3) Delete the code in the "daft"[1] architectures, and drop this hunk
> from the generic code.
I'm thinking 2 and 3 together sound like a plan :-)
--
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