lkml.org 
[lkml]   [2020]   [Jun]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH v2 08/29] soc: realtek: chip: Detect RTD1293
Date
Logic self-determined by comparing DS418j and DS418 registers.

Signed-off-by: Andreas Färber <afaerber@suse.de>
---
TODO: Identify the bit in ISO_CHIP_INFO1:bound_opts and what it really means.

v1 -> v2:
* Rebased onto iso syscon regmap

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

diff --git a/drivers/soc/realtek/chip.c b/drivers/soc/realtek/chip.c
index 103f564aad7f..32ed0e4a3646 100644
--- a/drivers/soc/realtek/chip.c
+++ b/drivers/soc/realtek/chip.c
@@ -75,8 +75,11 @@ static const char *rtd1295_name(struct device *dev, const struct dhc_soc *s)
ret = regmap_read(regmap, REG_ISO_CHIP_INFO1, &val);
if (ret)
dev_warn(dev, "Could not read chip_info1 (%d)\n", ret);
- else if (val & BIT(11))
+ else if (val & BIT(11)) {
+ if (val & BIT(4))
+ return "RTD1293";
return "RTD1296";
+ }
}

return "RTD1295";
--
2.26.2
\
 
 \ /
  Last update: 2020-06-23 04:54    [W:0.174 / U:3.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site