cpupower: Fix build error in cpufreq-info
authorShreyas B. Prabhu <shreyas@linux.vnet.ibm.com>
Mon, 18 Jan 2016 15:14:43 +0000 (20:44 +0530)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Tue, 19 Jan 2016 00:17:23 +0000 (01:17 +0100)
Fix the following build error by including limits.h -

utils/cpufreq-info.c: In function ‘get_latency’:
utils/cpufreq-info.c:437:29: error: ‘UINT_MAX’ undeclared (first use in
this function)
  if (!latency || latency == UINT_MAX) {
                             ^
Signed-off-by: Shreyas B. Prabhu <shreyas@linux.vnet.ibm.com>
Fixes: e98f033f94f3 (cpupower: fix how "cpupower frequency-info" interprets latency)
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
tools/power/cpupower/utils/cpufreq-info.c

index 8f3f5bb9c74ef514fd003990e20dce019603b6ea..590d12a25f6e0b8c625011e72d1aa2189e9e1c43 100644 (file)
@@ -10,6 +10,7 @@
 #include <errno.h>
 #include <stdlib.h>
 #include <string.h>
+#include <limits.h>
 
 #include <getopt.h>