summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeert Uytterhoeven <geert+renesas@glider.be>2026-03-02 19:29:10 +0300
committerRob Herring (Arm) <robh@kernel.org>2026-03-14 01:00:04 +0300
commit3ee3d8a44976ac7e39584637ee4c840d70ab2ad1 (patch)
tree7c510bcdac231d0cda0612160176f3c457b58794
parent951318c4651a646f4835ae33abe7c4cb232e7c6e (diff)
downloadlinux-3ee3d8a44976ac7e39584637ee4c840d70ab2ad1.tar.xz
soc: qcom: pd-mapper: Convert to of_machine_get_match()
Use the of_machine_get_match() helper instead of open-coding the same operation. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> Link: https://patch.msgid.link/0d23a449e62ac85f04ff07bc2758efbaa709c9d1.1772468323.git.geert+renesas@glider.be Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
-rw-r--r--drivers/soc/qcom/qcom_pd_mapper.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/soc/qcom/qcom_pd_mapper.c b/drivers/soc/qcom/qcom_pd_mapper.c
index dc10bc859ff4..8a1a18f8c859 100644
--- a/drivers/soc/qcom/qcom_pd_mapper.c
+++ b/drivers/soc/qcom/qcom_pd_mapper.c
@@ -615,15 +615,9 @@ static struct qcom_pdm_data *qcom_pdm_start(void)
const struct qcom_pdm_domain_data * const *domains;
const struct of_device_id *match;
struct qcom_pdm_data *data;
- struct device_node *root;
int ret, i;
- root = of_find_node_by_path("/");
- if (!root)
- return ERR_PTR(-ENODEV);
-
- match = of_match_node(qcom_pdm_domains, root);
- of_node_put(root);
+ match = of_machine_get_match(qcom_pdm_domains);
if (!match) {
pr_notice("PDM: no support for the platform, userspace daemon might be required.\n");
return ERR_PTR(-ENODEV);