diff options
author | Roel Kluin <roel.kluin@gmail.com> | 2009-12-15 22:46:50 +0100 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2009-12-16 00:07:21 -0500 |
commit | edb949185210365f107ddc5efa60df105d25e1d7 (patch) | |
tree | 95bd2ee22bfa9f25cd1f30dd1267a1105622a3de /drivers/thermal/thermal_sys.c | |
parent | 13c41157096f05d5037a99152b4cf9d68ef00ef7 (diff) | |
download | op-kernel-dev-edb949185210365f107ddc5efa60df105d25e1d7.zip op-kernel-dev-edb949185210365f107ddc5efa60df105d25e1d7.tar.gz |
thermal: Fix test of unsigned in thermal_cooling_device_cur_state_store()
state is unsigned long so the test did not work.
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Acked-by: Zhang Rui <rui.zhang@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/thermal/thermal_sys.c')
-rw-r--r-- | drivers/thermal/thermal_sys.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/thermal/thermal_sys.c b/drivers/thermal/thermal_sys.c index 6f8d8f97..800e0c5 100644 --- a/drivers/thermal/thermal_sys.c +++ b/drivers/thermal/thermal_sys.c @@ -374,7 +374,7 @@ thermal_cooling_device_cur_state_store(struct device *dev, if (!sscanf(buf, "%ld\n", &state)) return -EINVAL; - if (state < 0) + if ((long)state < 0) return -EINVAL; result = cdev->ops->set_cur_state(cdev, state); |