Re: [RFC][Patch] Adding kmsg_dump() toreboot/halt/poweroff/emergency_restart path

From: Artem Bityutskiy
Date: Thu Oct 28 2010 - 15:58:19 EST


On Wed, 2010-10-27 at 16:35 -0700, Andrew Morton wrote:
> > > I think mtdoops user don't want to dump logs if a system reboot/poweroff
> > > safely because mtd device have write count limitation. and they are main
> > > user of kmsg_dump().
>
> mtdoops was the only user until ramoops came along.
>
> > Right, at least this is how we use mtdoops - we log crashes.
>
> Fair enough. So I suppose the existing clients (mtdoops_do_dump and
> ramoops_do_dump) should be altered to inspect the `reason' argument,
> and return if it isn't KMSG_DUMP_OOPS, KMSG_DUMP_PANIC or
> KMSG_DUMP_KEXEC (I assume?)

I agree, then mtdoops/ramoops can be tweaked to handle other messages.

> If that sounds suitable then I'd ask Seiji to update and resend the
> patch, along with a complete changelog as earlier dicussed.

Yes, I think the patch makes perfect sense, just the existing
functionality should not be changed as a side effect.

> I'd suggest doing it as two patches, the first of which alters mtdoops
> and ramoops to perform their actions only for the appropriate `reason'
> values.

Right, thanks.

--
Best Regards,
Artem Bityutskiy (ÐÐÑÑÑÐÐÐ ÐÑÑÑÐ)

--
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/