aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/cpufreq/cpufreq.c
diff options
context:
space:
mode:
authorDave Jones <davej@redhat.com>2005-10-20 18:17:43 -0400
committerDave Jones <davej@redhat.com>2005-10-20 18:17:43 -0400
commite98df50c5200ae3c748d69002a8827afc9d2eae2 (patch)
tree885c86b8b573d22176435b51f146bc6177acc13c /drivers/cpufreq/cpufreq.c
parentbfdc708dc7d26fca66df0157b36356a2ba6166eb (diff)
[CPUFREQ] kzalloc conversions for cpufreq core.
Signed-off-by: Dave Jones <davej@redhat.com>
Diffstat (limited to 'drivers/cpufreq/cpufreq.c')
-rw-r--r--drivers/cpufreq/cpufreq.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
index 109d62ccf651..cfe1d0a2262d 100644
--- a/drivers/cpufreq/cpufreq.c
+++ b/drivers/cpufreq/cpufreq.c
@@ -595,12 +595,11 @@ static int cpufreq_add_dev (struct sys_device * sys_dev)
595 goto module_out; 595 goto module_out;
596 } 596 }
597 597
598 policy = kmalloc(sizeof(struct cpufreq_policy), GFP_KERNEL); 598 policy = kzalloc(sizeof(struct cpufreq_policy), GFP_KERNEL);
599 if (!policy) { 599 if (!policy) {
600 ret = -ENOMEM; 600 ret = -ENOMEM;
601 goto nomem_out; 601 goto nomem_out;
602 } 602 }
603 memset(policy, 0, sizeof(struct cpufreq_policy));
604 603
605 policy->cpu = cpu; 604 policy->cpu = cpu;
606 policy->cpus = cpumask_of_cpu(cpu); 605 policy->cpus = cpumask_of_cpu(cpu);