summaryrefslogtreecommitdiff
path: root/drivers/devfreq
diff options
context:
space:
mode:
authorTerje Bergstrom <tbergstrom@nvidia.com>2014-01-07 13:28:14 +0200
committerTom Cherry <tcherry@nvidia.com>2014-01-22 16:02:51 -0800
commit72e508716afd8bce415d294291ff4fc7445ea9df (patch)
tree9d8362a0b906258fbd268f6943915457a289db95 /drivers/devfreq
parent392b06d951b9dc914e56256e29db7aac94431d1e (diff)
devfreq: Fix type of frequency table
Frequencies are always expressed as ulong, but devfreq's table is of type uint *. Fix the mismatch. Change-Id: I0ed6b43f397331d1940c7f573d37796e50e8ac58 Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com> Reviewed-on: http://git-master/r/352720 Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>
Diffstat (limited to 'drivers/devfreq')
-rw-r--r--drivers/devfreq/devfreq.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq/devfreq.c
index e9adee3ae875..177b5fd51aba 100644
--- a/drivers/devfreq/devfreq.c
+++ b/drivers/devfreq/devfreq.c
@@ -4,7 +4,7 @@
*
* Copyright (C) 2011 Samsung Electronics
* MyungJoo Ham <myungjoo.ham@samsung.com>
- * Copyright (c) 2013, NVIDIA CORPORATION. All rights reserved.
+ * Copyright (c) 2013-2014, NVIDIA CORPORATION. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
@@ -491,7 +491,7 @@ struct devfreq *devfreq_add_device(struct device *dev,
devfreq->profile->max_state *
devfreq->profile->max_state,
GFP_KERNEL);
- devfreq->time_in_state = devm_kzalloc(dev, sizeof(unsigned int) *
+ devfreq->time_in_state = devm_kzalloc(dev, sizeof(unsigned long) *
devfreq->profile->max_state,
GFP_KERNEL);
devfreq->last_stat_updated = jiffies;
@@ -957,7 +957,7 @@ static ssize_t show_trans_table(struct device *dev, struct device_attribute *att
len = sprintf(buf, " From : To\n");
len += sprintf(buf + len, " :");
for (i = 0; i < max_state; i++)
- len += sprintf(buf + len, "%8u",
+ len += sprintf(buf + len, "%8lu",
devfreq->profile->freq_table[i]);
len += sprintf(buf + len, " time(ms)\n");
@@ -968,7 +968,7 @@ static ssize_t show_trans_table(struct device *dev, struct device_attribute *att
} else {
len += sprintf(buf + len, " ");
}
- len += sprintf(buf + len, "%8u:",
+ len += sprintf(buf + len, "%8lu:",
devfreq->profile->freq_table[i]);
for (j = 0; j < max_state; j++)
len += sprintf(buf + len, "%8u",