From: Boris Ostrovsky Date: Tue, 13 Mar 2012 18:55:10 +0000 (+0100) Subject: cpuidle: power_usage should be declared signed integer X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=02401c06b7f6bec65f314e3cec7894502c973501;p=openwrt%2Fstaging%2Fblogic.git cpuidle: power_usage should be declared signed integer power_usage is always assigned a negative value and should be declared a signed integer Signed-off-by: Boris Ostrovsky Signed-off-by: Len Brown --- diff --git a/drivers/cpuidle/governors/menu.c b/drivers/cpuidle/governors/menu.c index 5c17ca112fc2..06335756ea14 100644 --- a/drivers/cpuidle/governors/menu.c +++ b/drivers/cpuidle/governors/menu.c @@ -236,7 +236,7 @@ static int menu_select(struct cpuidle_driver *drv, struct cpuidle_device *dev) { struct menu_device *data = &__get_cpu_var(menu_devices); int latency_req = pm_qos_request(PM_QOS_CPU_DMA_LATENCY); - unsigned int power_usage = -1; + int power_usage = -1; int i; int multiplier; struct timespec t; diff --git a/include/linux/cpuidle.h b/include/linux/cpuidle.h index d557bcd0ada7..6c26a3da0e03 100644 --- a/include/linux/cpuidle.h +++ b/include/linux/cpuidle.h @@ -44,7 +44,7 @@ struct cpuidle_state { unsigned int flags; unsigned int exit_latency; /* in US */ - unsigned int power_usage; /* in mW */ + int power_usage; /* in mW */ unsigned int target_residency; /* in US */ unsigned int disable;