From b23397f95aa259e164f8ead7927440e9d907d593 Mon Sep 17 00:00:00 2001 From: Arjan van de Ven Date: Mon, 19 May 2008 15:55:15 -0700 Subject: [PATCH] --- yaml --- r: 98009 b: refs/heads/master c: a39a2d7c72b358c6253a2ec28e17b023b7f6f41c h: refs/heads/master i: 98007: 8097ce58eeffc90bc391d2d1962ea23b5c7d68e6 v: v3 --- [refs] | 2 +- trunk/drivers/acpi/thermal.c | 11 +++++++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index 272711f23f51..25d9fee187ff 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 8410565f540db87ca938f56f92780d251e4f157d +refs/heads/master: a39a2d7c72b358c6253a2ec28e17b023b7f6f41c diff --git a/trunk/drivers/acpi/thermal.c b/trunk/drivers/acpi/thermal.c index 504385b1f211..84c795fb9b1e 100644 --- a/trunk/drivers/acpi/thermal.c +++ b/trunk/drivers/acpi/thermal.c @@ -364,10 +364,17 @@ static int acpi_thermal_trips_update(struct acpi_thermal *tz, int flag) if (flag & ACPI_TRIPS_CRITICAL) { status = acpi_evaluate_integer(tz->device->handle, "_CRT", NULL, &tz->trips.critical.temperature); - if (ACPI_FAILURE(status)) { + /* + * Treat freezing temperatures as invalid as well; some + * BIOSes return really low values and cause reboots at startup. + * Below zero (Celcius) values clearly aren't right for sure.. + * ... so lets discard those as invalid. + */ + if (ACPI_FAILURE(status) || + tz->trips.critical.temperature <= 2732) { tz->trips.critical.flags.valid = 0; ACPI_EXCEPTION((AE_INFO, status, - "No critical threshold")); + "No or invalid critical threshold")); return -ENODEV; } else { tz->trips.critical.flags.valid = 1;