[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20191220002430.11995-9-cw00.choi@samsung.com>
Date: Fri, 20 Dec 2019 09:24:27 +0900
From: Chanwoo Choi <cw00.choi@...sung.com>
To: robh+dt@...nel.org, krzk@...nel.org, heiko@...ech.de,
leonard.crestez@....com, lukasz.luba@....com
Cc: mark.rutland@....com, a.swigon@...sung.com,
m.szyprowski@...sung.com, kgene@...nel.org, cw00.choi@...sung.com,
myungjoo.ham@...sung.com, kyungmin.park@...sung.com,
linux-pm@...r.kernel.org, linux-samsung-soc@...r.kernel.org,
devicetree@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org, linux-rockchip@...ts.infradead.org
Subject: [PATCH v2 08/11] PM / devfreq: rk3399_dmc: Replace the deprecated
'devfreq-events' property
Replace the deprecated 'devfreq-events' property with 'rockchip,dfi-device'
property. But, to guarantee the backward-compatibility, keep the support
of 'devfreq-events' property.
Signed-off-by: Chanwoo Choi <cw00.choi@...sung.com>
---
drivers/devfreq/rk3399_dmc.c | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/devfreq/rk3399_dmc.c b/drivers/devfreq/rk3399_dmc.c
index e712c8662d2f..2294de13a3dc 100644
--- a/drivers/devfreq/rk3399_dmc.c
+++ b/drivers/devfreq/rk3399_dmc.c
@@ -306,11 +306,14 @@ static int of_get_ddr_timings(struct dram_timing *timing,
static struct devfreq_event_dev *of_get_edev(struct device_node *np,
int index)
{
- struct device_node *node = of_parse_phandle(np, "devfreq-events",
+ struct device_node *node = of_parse_phandle(np, "rockchip,dfi-device",
index);
- if (!node)
- return ERR_PTR(-ENODEV);
+ if (!node) {
+ node = of_parse_phandle(np, "devfreq-events", index);
+ if (!node)
+ return ERR_PTR(-ENODEV);
+ }
return devfreq_event_get_edev_by_node(node);
}
--
2.17.1
Powered by blists - more mailing lists