acpi thermal: fix result check
commitbb070e43497d4fcfea7d8b52003fe1376c218343
authorKrzysztof Helt <krzysztof.h1@wp.pl>
Wed, 9 Apr 2008 00:41:52 +0000 (8 17:41 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 9 Apr 2008 01:25:52 +0000 (8 18:25 -0700)
tree7efb2a140fafb62eeb389ec8e8de499151aeede5
parentef45cb624b9517f71ad6c61299478c2cc08e4d98
acpi thermal: fix result check

thermal_zone_device_register() uses the ERR_PTR macro on its return values.  A
correct check is to use the IS_ERR() macro.

The 2.6.25 kernels panic on Compaq AP550 without this patch as it has more
then 10 (THERMAL_MAX_TRIPS) trip points (there are 12).

Signed-off-by: Krzysztof Helt <krzysztof.h1@wp.pl>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Len Brown <lenb@kernel.org>
Acked-by: Zhang Rui <rui.zhang@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/acpi/thermal.c