mirror of
https://github.com/team-infusion-developers/android_kernel_samsung_msm8976.git
synced 2024-09-21 20:04:01 +00:00
PM / devfreq: Allocate memory using the right data type
Long and int have different sizes on a 64-bit machine. Allocate memory for the time_in_state table using the right data type. Change-Id: Iecc1acc12ddabdb436c212f205aaed8dbb49a2b4 Signed-off-by: Suman Tatiraju <sumant@codeaurora.org>
This commit is contained in:
parent
512fe3702f
commit
dc65a54d91
|
@ -505,9 +505,10 @@ 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->profile->max_state,
|
||||
GFP_KERNEL);
|
||||
devfreq->time_in_state = devm_kzalloc(dev,
|
||||
sizeof(*(devfreq->time_in_state)) *
|
||||
devfreq->profile->max_state,
|
||||
GFP_KERNEL);
|
||||
devfreq->last_stat_updated = jiffies;
|
||||
devfreq_set_freq_limits(devfreq);
|
||||
|
||||
|
|
Loading…
Reference in a new issue