Re: [RFC] print symbolic page flag names in bad_page()

From: Ingo Molnar
Date: Mon Dec 07 2009 - 00:38:43 EST



* Andi Kleen <andi@xxxxxxxxxxxxxx> wrote:

> > So how about this patch?
>
> I like it. Decoding the flags by hand is always a very unpleasant
> experience. Bonus: dump_page can be called from kgdb too.

Guys, please do more review:

> +void dump_page(struct page *page)
> +{
> + char buf[1024];

NAK. This code causes a brutal, +1K kernel stack footprint spike that
can crash a system _precisely_ when we are trying to dump a (presumably
rare) condition.

> +EXPORT_SYMBOL(dump_page);

( Small detail: such exports are EXPORT_SYMBOL_GPL - we dont want random
external modules start using it. )

Thanks,

Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/