lkml.org 
[lkml]   [2023]   [Mar]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[RFC PATCH net-next v3 12/15] net: dsa: mt7530: add support for single-chip reset line
Similar to multi-chip-module MT7530 also MT7988 uses an internal
reset line instead of using an optional reset GPIO like it is the
case for external MT7530 and MT7531 ICs.
Add support for internal but non-MCM reset line in preparation for
adding support for MT7988.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
---
drivers/net/dsa/mt7530.c | 6 ++++++
1 file changed, 6 insertions(+)

diff --git a/drivers/net/dsa/mt7530.c b/drivers/net/dsa/mt7530.c
index c6fad2d156160..fd55ddc2d1eb3 100644
--- a/drivers/net/dsa/mt7530.c
+++ b/drivers/net/dsa/mt7530.c
@@ -3066,6 +3066,12 @@ mt7530_probe_common(struct mt7530_priv *priv)
dev_err(dev, "Couldn't get our reset line\n");
return PTR_ERR(priv->rstc);
}
+ } else if (!priv->bus) {
+ priv->rstc = devm_reset_control_get(dev, NULL);
+ if (IS_ERR(priv->rstc)) {
+ dev_err(dev, "Couldn't get our reset line\n");
+ return PTR_ERR(priv->rstc);
+ }
} else {
priv->reset = devm_gpiod_get_optional(dev, "reset",
GPIOD_OUT_LOW);
--
2.39.2
\
 
 \ /
  Last update: 2023-03-29 18:04    [W:0.119 / U:0.136 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site