summaryrefslogtreecommitdiff
path: root/drivers/soc/samsung/exynos-chipid.c
diff options
context:
space:
mode:
authorSylwester Nawrocki <s.nawrocki@samsung.com>2019-10-28 18:20:48 +0300
committerKrzysztof Kozlowski <krzk@kernel.org>2019-10-28 20:02:04 +0300
commit02fb29882d5ccfad352a310cc6fb9ad9d6daad70 (patch)
tree5a317fc960dc000fc99a371b209d5641d3c8de83 /drivers/soc/samsung/exynos-chipid.c
parent5ea428595cc53677a0a5bacd950307463c40411f (diff)
downloadlinux-02fb29882d5ccfad352a310cc6fb9ad9d6daad70.tar.xz
soc: samsung: chipid: Drop "syscon" compatible requirement
As we dropped the requirement of "syscon" compatible in the chipid nodes rework code acquiring the regmap to use device_node_to_regmap() rather than syscon_node_to_regmap(). Signed-off-by: Sylwester Nawrocki <s.nawrocki@samsung.com> Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
Diffstat (limited to 'drivers/soc/samsung/exynos-chipid.c')
-rw-r--r--drivers/soc/samsung/exynos-chipid.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/drivers/soc/samsung/exynos-chipid.c b/drivers/soc/samsung/exynos-chipid.c
index 25562dd0b206..b89c26a71c6e 100644
--- a/drivers/soc/samsung/exynos-chipid.c
+++ b/drivers/soc/samsung/exynos-chipid.c
@@ -50,12 +50,20 @@ static int __init exynos_chipid_early_init(void)
struct soc_device_attribute *soc_dev_attr;
struct soc_device *soc_dev;
struct device_node *root;
+ struct device_node *syscon;
struct regmap *regmap;
u32 product_id;
u32 revision;
int ret;
- regmap = syscon_regmap_lookup_by_compatible("samsung,exynos4210-chipid");
+ syscon = of_find_compatible_node(NULL, NULL,
+ "samsung,exynos4210-chipid");
+ if (!syscon)
+ return ENODEV;
+
+ regmap = device_node_to_regmap(syscon);
+ of_node_put(syscon);
+
if (IS_ERR(regmap))
return PTR_ERR(regmap);