Re: [PATCH] ACPI: more verbose thermal zone shutdown message
On Sonntag, 15. April 2007, Pavel Machek wrote: > Hi! > > > while debug some strange termal shutdowns I wrote this patch to get more > > information in /var/log/messages about the reason for the shutdown. I > > think this would be useful in general. > > > > Danny > > > > From: Danny Kukawka <[EMAIL PROTECTED]> > > Subject: ACPI: more verbose thermal zone shutdown message > > > > add more information to acpi thermal zone shutdown message for easier > > debugging > > > > Signed-off-by: Danny Kukawka <[EMAIL PROTECTED]> > > Yes, please. [..] > Why two printks with same info, and why is one of them WARNING and > second EMERG? I think this is what happen and why there are currently two messages: * if the temperature is really critical you get (now) this: kernel: Critical trip point (102 C) reached on Thermalzone [THM] kernel: Critical temperature reached (150 C on [THM] with trip point set to: 102 C), shutting down. * and if something send a critical temp event to the thermal zone you get: kernel: Critical temperature reached (42 C on [THM] with trip point set to: 102 C), shutting down. Maybe we can delete the first one, since you get now also from second message the information if the temperature was really critical or if there was an other reason for the shutdown, but in the past this was IMO needed to differ. Danny - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH] ACPI: more verbose thermal zone shutdown message
On Sonntag, 15. April 2007, Pavel Machek wrote: Hi! while debug some strange termal shutdowns I wrote this patch to get more information in /var/log/messages about the reason for the shutdown. I think this would be useful in general. Danny From: Danny Kukawka [EMAIL PROTECTED] Subject: ACPI: more verbose thermal zone shutdown message add more information to acpi thermal zone shutdown message for easier debugging Signed-off-by: Danny Kukawka [EMAIL PROTECTED] Yes, please. [..] Why two printks with same info, and why is one of them WARNING and second EMERG? I think this is what happen and why there are currently two messages: * if the temperature is really critical you get (now) this: kernel: Critical trip point (102 C) reached on Thermalzone [THM] kernel: Critical temperature reached (150 C on [THM] with trip point set to: 102 C), shutting down. * and if something send a critical temp event to the thermal zone you get: kernel: Critical temperature reached (42 C on [THM] with trip point set to: 102 C), shutting down. Maybe we can delete the first one, since you get now also from second message the information if the temperature was really critical or if there was an other reason for the shutdown, but in the past this was IMO needed to differ. Danny - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH] ACPI: more verbose thermal zone shutdown message
Hi! > while debug some strange termal shutdowns I wrote this patch to get more > information in /var/log/messages about the reason for the shutdown. I > think this would be useful in general. > > Danny > > From: Danny Kukawka <[EMAIL PROTECTED]> > Subject: ACPI: more verbose thermal zone shutdown message > > add more information to acpi thermal zone shutdown message for easier > debugging > > Signed-off-by: Danny Kukawka <[EMAIL PROTECTED]> Yes, please. (I actually had similar patch in my tree forever). > if (tz->temperature >= tz->trips.critical.temperature) { > - printk(KERN_WARNING PREFIX "Critical trip point\n"); > + printk(KERN_WARNING PREFIX > +"Critical trip point (%ld C) reached on thermal zone > [%s]\n", > +KELVIN_TO_CELSIUS(tz->trips.critical.temperature), > +acpi_device_bid(tz->device)); > tz->trips.critical.flags.enabled = 1; > } else if (tz->trips.critical.flags.enabled) > tz->trips.critical.flags.enabled = 0; > > printk(KERN_EMERG > -"Critical temperature reached (%ld C), shutting down.\n", > -KELVIN_TO_CELSIUS(tz->temperature)); > +"Critical temperature reached (%ld C on [%s] with trip point set > to: %ld C), shutting down.\n", > +KELVIN_TO_CELSIUS(tz->temperature), > +acpi_device_bid(tz->device), > +KELVIN_TO_CELSIUS(tz->trips.critical.temperature)); > + Why two printks with same info, and why is one of them WARNING and second EMERG? Pavel -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH] ACPI: more verbose thermal zone shutdown message
Hi! while debug some strange termal shutdowns I wrote this patch to get more information in /var/log/messages about the reason for the shutdown. I think this would be useful in general. Danny From: Danny Kukawka [EMAIL PROTECTED] Subject: ACPI: more verbose thermal zone shutdown message add more information to acpi thermal zone shutdown message for easier debugging Signed-off-by: Danny Kukawka [EMAIL PROTECTED] Yes, please. (I actually had similar patch in my tree forever). if (tz-temperature = tz-trips.critical.temperature) { - printk(KERN_WARNING PREFIX Critical trip point\n); + printk(KERN_WARNING PREFIX +Critical trip point (%ld C) reached on thermal zone [%s]\n, +KELVIN_TO_CELSIUS(tz-trips.critical.temperature), +acpi_device_bid(tz-device)); tz-trips.critical.flags.enabled = 1; } else if (tz-trips.critical.flags.enabled) tz-trips.critical.flags.enabled = 0; printk(KERN_EMERG -Critical temperature reached (%ld C), shutting down.\n, -KELVIN_TO_CELSIUS(tz-temperature)); +Critical temperature reached (%ld C on [%s] with trip point set to: %ld C), shutting down.\n, +KELVIN_TO_CELSIUS(tz-temperature), +acpi_device_bid(tz-device), +KELVIN_TO_CELSIUS(tz-trips.critical.temperature)); + Why two printks with same info, and why is one of them WARNING and second EMERG? Pavel -- (english) http://www.livejournal.com/~pavelmachek (cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH] ACPI: more verbose thermal zone shutdown message
On Thu, Apr 05, 2007 at 04:15:07PM +0200, Danny Kukawka wrote: > Hi, > > while debug some strange termal shutdowns I wrote this patch to get more > information in /var/log/messages about the reason for the shutdown. I > think this would be useful in general. Yes, especially as these were bogus thermal shutdowns, it is useful for debugging to know from which thermal zone they were initiated. > Danny > > From: Danny Kukawka <[EMAIL PROTECTED]> > Subject: ACPI: more verbose thermal zone shutdown message > > add more information to acpi thermal zone shutdown message for easier > debugging > > Signed-off-by: Danny Kukawka <[EMAIL PROTECTED]> FWIW: Signed-off-by: Stefan Seyfried <[EMAIL PROTECTED]> -- Stefan Seyfried "Any ideas, John?" "Well, surrounding them's out." - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[PATCH] ACPI: more verbose thermal zone shutdown message
Hi, while debug some strange termal shutdowns I wrote this patch to get more information in /var/log/messages about the reason for the shutdown. I think this would be useful in general. Danny From: Danny Kukawka <[EMAIL PROTECTED]> Subject: ACPI: more verbose thermal zone shutdown message add more information to acpi thermal zone shutdown message for easier debugging Signed-off-by: Danny Kukawka <[EMAIL PROTECTED]> --- thermal.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-) --- linux-2.6.21-rc5/drivers/acpi/thermal.c 2007-04-05 13:37:07.0 +0200 +++ linux-2.6.21-rc5/drivers/acpi/thermal.c 2007-04-05 16:02:03.0 +0200 @@ -457,14 +457,20 @@ return -EINVAL; if (tz->temperature >= tz->trips.critical.temperature) { - printk(KERN_WARNING PREFIX "Critical trip point\n"); + printk(KERN_WARNING PREFIX + "Critical trip point (%ld C) reached on thermal zone [%s]\n", + KELVIN_TO_CELSIUS(tz->trips.critical.temperature), + acpi_device_bid(tz->device)); tz->trips.critical.flags.enabled = 1; } else if (tz->trips.critical.flags.enabled) tz->trips.critical.flags.enabled = 0; printk(KERN_EMERG - "Critical temperature reached (%ld C), shutting down.\n", - KELVIN_TO_CELSIUS(tz->temperature)); + "Critical temperature reached (%ld C on [%s] with trip point set to: %ld C), shutting down.\n", + KELVIN_TO_CELSIUS(tz->temperature), + acpi_device_bid(tz->device), + KELVIN_TO_CELSIUS(tz->trips.critical.temperature)); + acpi_bus_generate_event(tz->device, ACPI_THERMAL_NOTIFY_CRITICAL, tz->trips.critical.flags.enabled); - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
[PATCH] ACPI: more verbose thermal zone shutdown message
Hi, while debug some strange termal shutdowns I wrote this patch to get more information in /var/log/messages about the reason for the shutdown. I think this would be useful in general. Danny From: Danny Kukawka [EMAIL PROTECTED] Subject: ACPI: more verbose thermal zone shutdown message add more information to acpi thermal zone shutdown message for easier debugging Signed-off-by: Danny Kukawka [EMAIL PROTECTED] --- thermal.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-) --- linux-2.6.21-rc5/drivers/acpi/thermal.c 2007-04-05 13:37:07.0 +0200 +++ linux-2.6.21-rc5/drivers/acpi/thermal.c 2007-04-05 16:02:03.0 +0200 @@ -457,14 +457,20 @@ return -EINVAL; if (tz-temperature = tz-trips.critical.temperature) { - printk(KERN_WARNING PREFIX Critical trip point\n); + printk(KERN_WARNING PREFIX + Critical trip point (%ld C) reached on thermal zone [%s]\n, + KELVIN_TO_CELSIUS(tz-trips.critical.temperature), + acpi_device_bid(tz-device)); tz-trips.critical.flags.enabled = 1; } else if (tz-trips.critical.flags.enabled) tz-trips.critical.flags.enabled = 0; printk(KERN_EMERG - Critical temperature reached (%ld C), shutting down.\n, - KELVIN_TO_CELSIUS(tz-temperature)); + Critical temperature reached (%ld C on [%s] with trip point set to: %ld C), shutting down.\n, + KELVIN_TO_CELSIUS(tz-temperature), + acpi_device_bid(tz-device), + KELVIN_TO_CELSIUS(tz-trips.critical.temperature)); + acpi_bus_generate_event(tz-device, ACPI_THERMAL_NOTIFY_CRITICAL, tz-trips.critical.flags.enabled); - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH] ACPI: more verbose thermal zone shutdown message
On Thu, Apr 05, 2007 at 04:15:07PM +0200, Danny Kukawka wrote: Hi, while debug some strange termal shutdowns I wrote this patch to get more information in /var/log/messages about the reason for the shutdown. I think this would be useful in general. Yes, especially as these were bogus thermal shutdowns, it is useful for debugging to know from which thermal zone they were initiated. Danny From: Danny Kukawka [EMAIL PROTECTED] Subject: ACPI: more verbose thermal zone shutdown message add more information to acpi thermal zone shutdown message for easier debugging Signed-off-by: Danny Kukawka [EMAIL PROTECTED] FWIW: Signed-off-by: Stefan Seyfried [EMAIL PROTECTED] -- Stefan Seyfried Any ideas, John? Well, surrounding them's out. - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/