From f605181abd95a109031a23c67a824eb8e5dcfe67 Mon Sep 17 00:00:00 2001 From: Thomas Renninger Date: Fri, 28 Jun 2013 15:34:29 +0200 Subject: cpupower: Make idlestate usage unsigned Use unsigned int as the data type for some variables related to CPU idle states which allows the code to be simplified slightly. [rjw: Changelog] Signed-off-by: Thomas Renninger Signed-off-by: Rafael J. Wysocki --- tools/power/cpupower/utils/helpers/sysfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tools/power/cpupower/utils/helpers/sysfs.c') diff --git a/tools/power/cpupower/utils/helpers/sysfs.c b/tools/power/cpupower/utils/helpers/sysfs.c index 38ab91629463..891f6710d026 100644 --- a/tools/power/cpupower/utils/helpers/sysfs.c +++ b/tools/power/cpupower/utils/helpers/sysfs.c @@ -238,7 +238,7 @@ char *sysfs_get_idlestate_desc(unsigned int cpu, unsigned int idlestate) * Negativ in error case * Zero if cpuidle does not export any C-states */ -int sysfs_get_idlestate_count(unsigned int cpu) +unsigned int sysfs_get_idlestate_count(unsigned int cpu) { char file[SYSFS_PATH_MAX]; struct stat statbuf; -- cgit v1.2.3