soc: samsung: add exynos chipid driver support
authorPankaj Dubey <pankaj.dubey@samsung.com>
Thu, 15 Nov 2018 15:11:31 +0000 (16:11 +0100)
committerJunghoon Kim <jhoon20.kim@samsung.com>
Thu, 14 Feb 2019 05:57:48 +0000 (14:57 +0900)
commitae79fb2db47cdf9257d5911fc2b225e0e82d257a
treee56e7aa32c62d3cc5fd3d38b710ee0b869fc91f9
parentd7f37819f37dd421c0dcd9194185f323b64e2de1
soc: samsung: add exynos chipid driver support

Exynos SoCs have Chipid, for identification of product IDs and SoC
revisions. This patch intends to provide initialization code for all
these functionalities, at the same time it provides some sysfs entries
for accessing these information to user-space.

This driver uses existing binding for exynos-chipid.

Changes by Bartlomiej:
- fixed return values on errors
- removed bogus kfree_const()
- added missing Exynos4210 EVT0 id
- converted code to use EXYNOS_MASK define
- fixed np use after of_node_put()
- fixed too early use of dev_info()
- made driver fail for unknown SoC-s
- added SPDX tag
- updated Copyrights

Change-Id: I02ee0e759166f3722f61f108026aa8dc658a5608
Cc: Grant Likely <grant.likely@secretlab.ca>
Cc: Rob Herring <robh+dt@kernel.org>
Cc: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Pankaj Dubey <pankaj.dubey@samsung.com>
[m.szyprowski: for suggestion and code snippet of product_id_to_soc_id]
Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
drivers/soc/samsung/Kconfig
drivers/soc/samsung/Makefile
drivers/soc/samsung/exynos-chipid.c [new file with mode: 0644]