>From 4df0d19bb081f3675a910eeb025fb1b01b9f719c Mon Sep 17 00:00:00 2001 From: Tim Gardner Date: Mon, 24 Jun 2013 10:09:05 -0600 Subject: [PATCH] cpufreq_ondemand.c: Added debug Signed-off-by: Tim Gardner --- drivers/cpufreq/cpufreq_ondemand.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/cpufreq/cpufreq_ondemand.c b/drivers/cpufreq/cpufreq_ondemand.c index 4b9bb5d..996ed06 100644 --- a/drivers/cpufreq/cpufreq_ondemand.c +++ b/drivers/cpufreq/cpufreq_ondemand.c @@ -593,8 +593,20 @@ static void od_set_powersave_bias(unsigned int powersave_bias) continue; policy = per_cpu(od_cpu_dbs_info, cpu).cdbs.cur_policy; + if (!policy) { + printk(KERN_ERR "%s !policy, cpu %u\n",__func__,cpu); + continue; + } dbs_data = policy->governor_data; + if (!dbs_data) { + printk(KERN_ERR "%s !dbs_data, cpu %u\n",__func__,cpu); + continue; + } od_tuners = dbs_data->tuners; + if (!od_tuners) { + printk(KERN_ERR "%s !od_tuners, cpu %u\n",__func__,cpu); + continue; + } od_tuners->powersave_bias = powersave_bias; cpumask_or(&done, &done, policy->cpus); -- 1.7.9.5