Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 83d14255 authored by Ram Chandrasekar's avatar Ram Chandrasekar
Browse files

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: default avatarRam Chandrasekar <rkumbako@codeaurora.org>
parent 1e4aef37
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -227,12 +227,11 @@ static struct cc_limits_data *opp_init(int *cpus)
	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;