drivers: thermal: cpu_voltage: Use the child device node

The cooling device registration is using the parent node of the cpu
voltage cooling device. The devicetree configs are using the child node
to identify the cooling device. Switch to use the child device node, so
that the cooling device is bound with the thermal zone.

Change-Id: Id501421002c5dac7cb924455e09538a384ec9f85
Signed-off-by: Ram Chandrasekar <rkumbako@codeaurora.org>
This commit is contained in:
Ram Chandrasekar 2020-08-20 16:01:43 -07:00
commit 83d14255e3

View file

@ -227,12 +227,11 @@ opp_err_exit:
return ERR_PTR(-ENODEV);
}
static int cc_init(struct device *dev, int *cpus)
static int cc_init(struct device_node *np, int *cpus)
{
struct cc_limits_data *cc_cdev;
int idx = 0, ret = 0;
struct cpufreq_policy *policy;
struct device_node *np = dev->of_node;
mutex_lock(&cc_list_lock);
list_for_each_entry(cc_cdev, &cc_cdev_list, node) {
@ -323,7 +322,7 @@ static int cc_cooling_probe(struct platform_device *pdev)
}
}
}
ret = cc_init(dev, cpu_map);
ret = cc_init(subsys_np, cpu_map);
}
return ret;