summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorAndrey Utkin <andrey.krieger.utkin@gmail.com>2014-07-19 22:14:04 +0300
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2014-07-19 21:41:17 +0200
commit788606cb8864765bb16be23d368725df84d0e3cc (patch)
tree7170e4aba968834e15a9d13e57b8eb6689b94ace /tools
parent1795cd9b3a91d4b5473c97f491d63892442212ab (diff)
downloadop-kernel-dev-788606cb8864765bb16be23d368725df84d0e3cc.zip
op-kernel-dev-788606cb8864765bb16be23d368725df84d0e3cc.tar.gz
PM / tools: cpupower: drop negativity check on unsigned value
Link: https://bugzilla.kernel.org/show_bug.cgi?id=80621 Reported-by: David Binderman <dcb314@hotmail.com> Signed-off-by: Andrey Utkin <andrey.krieger.utkin@gmail.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'tools')
-rw-r--r--tools/power/cpupower/utils/helpers/sysfs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/power/cpupower/utils/helpers/sysfs.c b/tools/power/cpupower/utils/helpers/sysfs.c
index 851c7a1..09afe5d 100644
--- a/tools/power/cpupower/utils/helpers/sysfs.c
+++ b/tools/power/cpupower/utils/helpers/sysfs.c
@@ -81,7 +81,7 @@ int sysfs_is_cpu_online(unsigned int cpu)
close(fd);
value = strtoull(linebuf, &endp, 0);
- if (value > 1 || value < 0)
+ if (value > 1)
return -EINVAL;
return value;
OpenPOWER on IntegriCloud