[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201208124641.1787-2-thunder.leizhen@huawei.com>
Date: Tue, 8 Dec 2020 20:46:38 +0800
From: Zhen Lei <thunder.leizhen@...wei.com>
To: Philipp Zabel <p.zabel@...gutronix.de>,
Wei Xu <xuwei5@...ilicon.com>,
"Rob Herring" <robh+dt@...nel.org>,
linux-arm-kernel <linux-arm-kernel@...ts.infradead.org>,
devicetree <devicetree@...r.kernel.org>,
linux-kernel <linux-kernel@...r.kernel.org>
CC: Zhen Lei <thunder.leizhen@...wei.com>,
Zhangfei Gao <zhangfei.gao@...aro.org>,
Chen Feng <puck.chen@...ilicon.com>,
"Manivannan Sadhasivam" <manivannan.sadhasivam@...aro.org>
Subject: [PATCH v3 1/4] reset: hisilicon: correct vendor prefix
The vendor prefix of "Hisilicon Limited" is "hisilicon", it is clearly
stated in "vendor-prefixes.yaml".
For backward compatibility reasons fall back to the deprecated compatible
if the new one failed.
Fixes: 1527058736fa ("reset: hisilicon: add reset-hi3660")
Signed-off-by: Zhen Lei <thunder.leizhen@...wei.com>
Cc: Zhangfei Gao <zhangfei.gao@...aro.org>
---
drivers/reset/hisilicon/reset-hi3660.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/drivers/reset/hisilicon/reset-hi3660.c b/drivers/reset/hisilicon/reset-hi3660.c
index a7d4445924e558c..965f5ceba7d8f4d 100644
--- a/drivers/reset/hisilicon/reset-hi3660.c
+++ b/drivers/reset/hisilicon/reset-hi3660.c
@@ -83,9 +83,14 @@ static int hi3660_reset_probe(struct platform_device *pdev)
if (!rc)
return -ENOMEM;
- rc->map = syscon_regmap_lookup_by_phandle(np, "hisi,rst-syscon");
+ rc->map = syscon_regmap_lookup_by_phandle(np, "hisilicon,rst-syscon");
+ if (rc->map == ERR_PTR(-ENODEV)) {
+ /* fall back to the deprecated compatible */
+ rc->map = syscon_regmap_lookup_by_phandle(np,
+ "hisi,rst-syscon");
+ }
if (IS_ERR(rc->map)) {
- dev_err(dev, "failed to get hi3660,rst-syscon\n");
+ dev_err(dev, "failed to get hisilicon,rst-syscon\n");
return PTR_ERR(rc->map);
}
--
1.8.3
Powered by blists - more mailing lists