OSDN Git Service

net: dsa: ocelot: document why reset procedure is different for felix/seville
authorVladimir Oltean <vladimir.oltean@nxp.com>
Fri, 18 Sep 2020 10:57:46 +0000 (13:57 +0300)
committerDavid S. Miller <davem@davemloft.net>
Sat, 19 Sep 2020 00:52:40 +0000 (17:52 -0700)
The overall idea (issue soft reset, enable memories, initialize
memories, enable core) is the same, so it would make sense that an
attempt is made to unify the procedures.

It is not immediately obvious that the fields are not part of the same
register targets, though. So add a comment.

Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/ocelot/felix_vsc9959.c
drivers/net/dsa/ocelot/seville_vsc9953.c

index 397d24c..6f6e4ef 100644 (file)
@@ -737,6 +737,9 @@ static int vsc9959_sys_ram_init_status(struct ocelot *ocelot)
        return ocelot_read(ocelot, SYS_RAM_INIT);
 }
 
+/* CORE_ENA is in SYS:SYSTEM:RESET_CFG
+ * RAM_INIT is in SYS:RAM_CTRL:RAM_INIT
+ */
 static int vsc9959_reset(struct ocelot *ocelot)
 {
        int val, err;
index 36cf83d..565ea16 100644 (file)
@@ -820,6 +820,10 @@ out:
        return err;
 }
 
+/* CORE_ENA is in SYS:SYSTEM:RESET_CFG
+ * MEM_INIT is in SYS:SYSTEM:RESET_CFG
+ * MEM_ENA is in SYS:SYSTEM:RESET_CFG
+ */
 static int vsc9953_reset(struct ocelot *ocelot)
 {
        int val, err;