aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/dsa/mv88e6xxx/port.h
diff options
context:
space:
mode:
authorVivien Didelot2017-06-12 12:37:38 -0400
committerDavid S. Miller2017-06-13 11:23:10 -0400
commitcd985bbf9a30ed58ff7d56b236144d98ff64e89d (patch)
tree33db1bfb9597ca0becc357af89e5ba51f4d7b22f /drivers/net/dsa/mv88e6xxx/port.h
parenta89b433bee684aeb5535b186d88bac17516380e8 (diff)
net: dsa: mv88e6xxx: prefix Port Control 1 macros
For implicit namespacing and clarity, prefix the common Port Control 1 Register macros with MV88E6XXX_PORT_CTL1. Document the register and prefer ordered hex masks values for all Marvell 16-bit registers. Signed-off-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/dsa/mv88e6xxx/port.h')
-rw-r--r--drivers/net/dsa/mv88e6xxx/port.h8
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/net/dsa/mv88e6xxx/port.h b/drivers/net/dsa/mv88e6xxx/port.h
index 880f1b117248..451f99fd81cf 100644
--- a/drivers/net/dsa/mv88e6xxx/port.h
+++ b/drivers/net/dsa/mv88e6xxx/port.h
@@ -141,9 +141,11 @@
#define MV88E6XXX_PORT_CTL0_STATE_LEARNING 0x0002
#define MV88E6XXX_PORT_CTL0_STATE_FORWARDING 0x0003
-#define PORT_CONTROL_1 0x05
-#define PORT_CONTROL_1_MESSAGE_PORT BIT(15)
-#define PORT_CONTROL_1_FID_11_4_MASK (0xff << 0)
+/* Offset 0x05: Port Control 1 */
+#define MV88E6XXX_PORT_CTL1 0x05
+#define MV88E6XXX_PORT_CTL1_MESSAGE_PORT 0x8000
+#define MV88E6XXX_PORT_CTL1_FID_11_4_MASK 0x00ff
+
#define PORT_BASE_VLAN 0x06
#define PORT_BASE_VLAN_FID_3_0_MASK (0xf << 12)
#define PORT_DEFAULT_VLAN 0x07