summaryrefslogtreecommitdiff
path: root/drivers/net/dsa/ocelot/felix.h
diff options
context:
space:
mode:
authorColin Foster <colin.foster@in-advantage.com>2023-01-27 11:35:54 -0800
committerJakub Kicinski <kuba@kernel.org>2023-01-30 21:07:20 -0800
commitde879a016a94a670fafeb3eb03b3d5803d81ab37 (patch)
tree407439c49f2306b84e492bba044e5a1f23b3279c /drivers/net/dsa/ocelot/felix.h
parentdc454fa4b764ab75038e822dfc9a1b2526757a63 (diff)
net: dsa: felix: add functionality when not all ports are supported
When the Felix driver would probe the ports and verify functionality, it would fail if it hit single port mode that wasn't supported by the driver. The initial case for the VSC7512 driver will have physical ports that exist, but aren't supported by the driver implementation. Add the OCELOT_PORT_MODE_NONE macro to handle this scenario, and allow the Felix driver to continue with all the ports that are currently functional. Signed-off-by: Colin Foster <colin.foster@in-advantage.com> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Reviewed-by: Vladimir Oltean <vladimir.oltean@nxp.com> Tested-by: Vladimir Oltean <vladimir.oltean@nxp.com> # regression Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/dsa/ocelot/felix.h')
-rw-r--r--drivers/net/dsa/ocelot/felix.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/dsa/ocelot/felix.h b/drivers/net/dsa/ocelot/felix.h
index 9e1ae1dde0d9..d5d0b30c0b75 100644
--- a/drivers/net/dsa/ocelot/felix.h
+++ b/drivers/net/dsa/ocelot/felix.h
@@ -7,6 +7,7 @@
#define ocelot_to_felix(o) container_of((o), struct felix, ocelot)
#define FELIX_MAC_QUIRKS OCELOT_QUIRK_PCS_PERFORMS_RATE_ADAPTATION
+#define OCELOT_PORT_MODE_NONE 0
#define OCELOT_PORT_MODE_INTERNAL BIT(0)
#define OCELOT_PORT_MODE_SGMII BIT(1)
#define OCELOT_PORT_MODE_QSGMII BIT(2)