diff mbox series

[RFC,08/11] soc: realtek: chip: Detect RTD1293

Message ID 20191103013645.9856-9-afaerber@suse.de
State New
Headers show
Series ARM: Realtek RTD1195/RTD1295 SoC info | expand

Commit Message

Andreas Färber Nov. 3, 2019, 1:36 a.m. UTC
Logic self-determined by comparing DS418j and DS418 registers.

Signed-off-by: Andreas Färber <afaerber@suse.de>

---
 drivers/soc/realtek/chip.c | 2 ++
 1 file changed, 2 insertions(+)

-- 
2.16.4
diff mbox series

Patch

diff --git a/drivers/soc/realtek/chip.c b/drivers/soc/realtek/chip.c
index ba653c097644..f4b26fb048c7 100644
--- a/drivers/soc/realtek/chip.c
+++ b/drivers/soc/realtek/chip.c
@@ -59,6 +59,8 @@  static const char *rtd1295_name(struct device *dev, const struct rtd_soc *s)
 		u32 chipinfo1 = readl_relaxed(base);
 		iounmap(base);
 		if (chipinfo1 & BIT(11)) {
+			if (chipinfo1 & BIT(4))
+				return "RTD1293";
 			return "RTD1296";
 		}
 	}