lan9303_driver.h File Reference

LAN9303 3-port Ethernet switch driver. More...

#include "core/nic.h"

Go to the source code of this file.

Macros

#define LAN9303_PORT0   3
 
#define LAN9303_PORT1   1
 
#define LAN9303_PORT2   2
 
#define LAN9303_PORT_MASK   0x07
 
#define LAN9303_PORT0_MASK   0x04
 
#define LAN9303_PORT1_MASK   0x01
 
#define LAN9303_PORT2_MASK   0x02
 
#define LAN9303_PORT0_1_MASK   0x05
 
#define LAN9303_PORT0_2_MASK   0x06
 
#define LAN9303_PORT1_2_MASK   0x03
 
#define LAN9303_PORT0_1_2_MASK   0x07
 
#define LAN9303_ALR_TABLE_SIZE   512
 
#define LAN9303_VID_VLAN_RULES   0x0040
 
#define LAN9303_VID_CALC_PRIORITY   0x0020
 
#define LAN9303_VID_STP_OVERRIDE   0x0010
 
#define LAN9303_VID_ALR_LOOKUP   0x0008
 
#define LAN9303_VID_BROADCAST   0x0003
 
#define LAN9303_VID_DEST_PORT2   0x0002
 
#define LAN9303_VID_DEST_PORT1   0x0001
 
#define LAN9303_VID_DEST_PORT0   0x0000
 
#define LAN9303_VID_PRIORITY   0x0380
 
#define LAN9303_VID_PRIORITY_EN   0x0040
 
#define LAN9303_VID_STATIC   0x0020
 
#define LAN9303_VID_STP_OVERRIDE   0x0010
 
#define LAN9303_VID_IGMP_PACKET   0x0008
 
#define LAN9303_VID_SRC_PORT   0x0003
 
#define LAN9303_BMCR   0x00
 
#define LAN9303_BMSR   0x01
 
#define LAN9303_PHYID1   0x02
 
#define LAN9303_PHYID2   0x03
 
#define LAN9303_ANAR   0x04
 
#define LAN9303_ANLPAR   0x05
 
#define LAN9303_ANER   0x06
 
#define LAN9303_PMCSR   0x11
 
#define LAN9303_PSMR   0x12
 
#define LAN9303_PSCSIR   0x1B
 
#define LAN9303_PISR   0x1D
 
#define LAN9303_PIMR   0x1E
 
#define LAN9303_PSCSR   0x1F
 
#define LAN9303_BYTE_TEST   0x0064
 
#define LAN9303_HW_CFG   0x0074
 
#define LAN9303_SWITCH_CSR_DATA   0x01AC
 
#define LAN9303_SWITCH_CSR_CMD   0x01B0
 
#define LAN9303_SW_DEV_ID   0x0000
 
#define LAN9303_SW_RESET   0x0001
 
#define LAN9303_SW_IMR   0x0004
 
#define LAN9303_SW_IPR   0x0005
 
#define LAN9303_MAC_VER_ID0   0x0400
 
#define LAN9303_MAC_RX_CFG0   0x0401
 
#define LAN9303_MAC_TX_CFG0   0x0440
 
#define LAN9303_MAC_VER_ID1   0x0800
 
#define LAN9303_MAC_RX_CFG1   0x0801
 
#define LAN9303_MAC_TX_CFG1   0x0840
 
#define LAN9303_MAC_VER_ID2   0x0C00
 
#define LAN9303_MAC_RX_CFG2   0x0C01
 
#define LAN9303_MAC_TX_CFG2   0x0C40
 
#define LAN9303_SWE_ALR_CMD   0x1800
 
#define LAN9303_SWE_ALR_WR_DAT0   0x1801
 
#define LAN9303_SWE_ALR_WR_DAT1   0x1802
 
#define LAN9303_SWE_ALR_RD_DAT0   0x1805
 
#define LAN9303_SWE_ALR_RD_DAT1   0x1806
 
#define LAN9303_SWE_ALR_CMD_STS   0x1808
 
#define LAN9303_SWE_ALR_CFG   0x1809
 
#define LAN9303_SWE_PORT_STATE   0x1843
 
#define LAN9303_SWE_PORT_MIRROR   0x1846
 
#define LAN9303_SWE_INGRSS_PORT_TYP   0x1847
 
#define LAN9303_BM_EGRSS_PORT_TYPE   0x1C0C
 
#define LAN9303_MAC_VER_ID(port)   (0x0400 + ((port) * 0x0400))
 
#define LAN9303_MAC_RX_CFG(port)   (0x0401 + ((port) * 0x0400))
 
#define LAN9303_MAC_TX_CFG(port)   (0x0440 + ((port) * 0x0400))
 
#define LAN9303_BMCR_RESET   0x8000
 
#define LAN9303_BMCR_LOOPBACK   0x4000
 
#define LAN9303_BMCR_SPEED_SEL   0x2000
 
#define LAN9303_BMCR_AN_EN   0x1000
 
#define LAN9303_BMCR_POWER_DOWN   0x0800
 
#define LAN9303_BMCR_RESTART_AN   0x0200
 
#define LAN9303_BMCR_DUPLEX_MODE   0x0100
 
#define LAN9303_BMCR_COL_TEST   0x0080
 
#define LAN9303_BMSR_100BT4   0x8000
 
#define LAN9303_BMSR_100BTX_FD   0x4000
 
#define LAN9303_BMSR_100BTX_HD   0x2000
 
#define LAN9303_BMSR_10BT_FD   0x1000
 
#define LAN9303_BMSR_10BT_HD   0x0800
 
#define LAN9303_BMSR_100BT2_FD   0x0400
 
#define LAN9303_BMSR_100BT2_HD   0x0200
 
#define LAN9303_BMSR_AN_COMPLETE   0x0020
 
#define LAN9303_BMSR_REMOTE_FAULT   0x0010
 
#define LAN9303_BMSR_AN_CAPABLE   0x0008
 
#define LAN9303_BMSR_LINK_STATUS   0x0004
 
#define LAN9303_BMSR_JABBER_DETECT   0x0002
 
#define LAN9303_BMSR_EXTENDED_CAPABLE   0x0001
 
#define LAN9303_PHYID1_PHY_ID_MSB   0xFFFF
 
#define LAN9303_PHYID1_PHY_ID_MSB_DEFAULT   0x0007
 
#define LAN9303_PHYID2_PHY_ID_LSB   0xFFFF
 
#define LAN9303_PHYID2_PHY_ID_LSB_DEFAULT   0x0030
 
#define LAN9303_PHYID2_MODEL_NUM   0x03F0
 
#define LAN9303_PHYID2_MODEL_NUM_DEFAULT   0x00D0
 
#define LAN9303_PHYID2_REVISION_NUM   0x000F
 
#define LAN9303_ANAR_REMOTE_FAULT   0x2000
 
#define LAN9303_ANAR_ASYM_PAUSE   0x0800
 
#define LAN9303_ANAR_SYM_PAUSE   0x0400
 
#define LAN9303_ANAR_100BTX_FD   0x0100
 
#define LAN9303_ANAR_100BTX_HD   0x0080
 
#define LAN9303_ANAR_10BT_FD   0x0040
 
#define LAN9303_ANAR_10BT_HD   0x0020
 
#define LAN9303_ANAR_SELECTOR   0x001F
 
#define LAN9303_ANAR_SELECTOR_DEFAULT   0x0001
 
#define LAN9303_ANLPAR_NEXT_PAGE   0x8000
 
#define LAN9303_ANLPAR_ACK   0x4000
 
#define LAN9303_ANLPAR_REMOTE_FAULT   0x2000
 
#define LAN9303_ANLPAR_ASYM_PAUSE   0x0800
 
#define LAN9303_ANLPAR_SYM_PAUSE   0x0400
 
#define LAN9303_ANLPAR_100BT4   0x0200
 
#define LAN9303_ANLPAR_100BTX_FD   0x0100
 
#define LAN9303_ANLPAR_100BTX_HD   0x0080
 
#define LAN9303_ANLPAR_10BT_FD   0x0040
 
#define LAN9303_ANLPAR_10BT_HD   0x0020
 
#define LAN9303_ANLPAR_SELECTOR   0x001F
 
#define LAN9303_ANLPAR_SELECTOR_DEFAULT   0x0001
 
#define LAN9303_ANER_PAR_DETECT_FAULT   0x0010
 
#define LAN9303_ANER_LP_NEXT_PAGE_ABLE   0x0008
 
#define LAN9303_ANER_NEXT_PAGE_ABLE   0x0004
 
#define LAN9303_ANER_PAGE_RECEIVED   0x0002
 
#define LAN9303_ANER_LP_AN_ABLE   0x0001
 
#define LAN9303_PMCSR_EDPWRDOWN   0x2000
 
#define LAN9303_PMCSR_ENERGYON   0x0002
 
#define LAN9303_PSMR_MODE   0x00E0
 
#define LAN9303_PSMR_MODE_10BT_HD   0x0000
 
#define LAN9303_PSMR_MODE_10BT_FD   0x0020
 
#define LAN9303_PSMR_MODE_100BTX_HD   0x0040
 
#define LAN9303_PSMR_MODE_100BTX_FD   0x0060
 
#define LAN9303_PSMR_MODE_POWER_DOWN   0x00C0
 
#define LAN9303_PSMR_MODE_AN   0x00E0
 
#define LAN9303_PSMR_PHYAD   0x001F
 
#define LAN9303_PSCSIR_AMDIXCTRL   0x8000
 
#define LAN9303_PSCSIR_AMDIXEN   0x4000
 
#define LAN9303_PSCSIR_AMDIXSTATE   0x2000
 
#define LAN9303_PSCSIR_SQEOFF   0x0800
 
#define LAN9303_PSCSIR_VCOOFF_LP   0x0400
 
#define LAN9303_PSCSIR_XPOL   0x0010
 
#define LAN9303_PISR_ENERGYON   0x0080
 
#define LAN9303_PISR_AN_COMPLETE   0x0040
 
#define LAN9303_PISR_REMOTE_FAULT   0x0020
 
#define LAN9303_PISR_LINK_DOWN   0x0010
 
#define LAN9303_PISR_AN_LP_ACK   0x0008
 
#define LAN9303_PISR_PAR_DETECT_FAULT   0x0004
 
#define LAN9303_PISR_AN_PAGE_RECEIVED   0x0002
 
#define LAN9303_PIMR_ENERGYON   0x0080
 
#define LAN9303_PIMR_AN_COMPLETE   0x0040
 
#define LAN9303_PIMR_REMOTE_FAULT   0x0020
 
#define LAN9303_PIMR_LINK_DOWN   0x0010
 
#define LAN9303_PIMR_AN_LP_ACK   0x0008
 
#define LAN9303_PIMR_PAR_DETECT_FAULT   0x0004
 
#define LAN9303_PIMR_AN_PAGE_RECEIVED   0x0002
 
#define LAN9303_PSCSR_AUTODONE   0x1000
 
#define LAN9303_PSCSR_SPEED   0x001C
 
#define LAN9303_PSCSR_SPEED_10BT_HD   0x0004
 
#define LAN9303_PSCSR_SPEED_100BTX_HD   0x0008
 
#define LAN9303_PSCSR_SPEED_10BT_FD   0x0014
 
#define LAN9303_PSCSR_SPEED_100BTX_FD   0x0018
 
#define LAN9303_BYTE_TEST_DEFAULT   0x87654321
 
#define LAN9303_HW_CFG_DEVICE_READY   0x08000000
 
#define LAN9303_HW_CFG_AMDIX_EN_STRAP_STATE_PORT2   0x04000000
 
#define LAN9303_HW_CFG_AMDIX_EN_STRAP_STATE_PORT1   0x02000000
 
#define LAN9303_SWITCH_CSR_CMD_BUSY   0x80000000
 
#define LAN9303_SWITCH_CSR_CMD_READ   0x40000000
 
#define LAN9303_SWITCH_CSR_CMD_AUTO_INC   0x20000000
 
#define LAN9303_SWITCH_CSR_CMD_AUTO_DEC   0x10000000
 
#define LAN9303_SWITCH_CSR_CMD_BE   0x000F0000
 
#define LAN9303_SWITCH_CSR_CMD_BE_0   0x00010000
 
#define LAN9303_SWITCH_CSR_CMD_BE_1   0x00020000
 
#define LAN9303_SWITCH_CSR_CMD_BE_2   0x00040000
 
#define LAN9303_SWITCH_CSR_CMD_BE_3   0x00080000
 
#define LAN9303_SWITCH_CSR_CMD_ADDR   0x0000FFFF
 
#define LAN9303_SW_DEV_ID_DEVICE_TYPE   0x00FF0000
 
#define LAN9303_SW_DEV_ID_DEVICE_TYPE_DEFAULT   0x00030000
 
#define LAN9303_SW_DEV_ID_CHIP_VERSION   0x0000FF00
 
#define LAN9303_SW_DEV_ID_CHIP_VERSION_DEFAULT   0x00000400
 
#define LAN9303_SW_DEV_ID_REVISION   0x000000FF
 
#define LAN9303_SW_DEV_ID_REVISION_DEFAULT   0x00000007
 
#define LAN9303_SW_RESET_SW_RESET   0x00000001
 
#define LAN9303_SW_IMR_BM   0x00000040
 
#define LAN9303_SW_IMR_SWE   0x00000020
 
#define LAN9303_SW_IMR_MAC2   0x00000004
 
#define LAN9303_SW_IMR_MAC1   0x00000002
 
#define LAN9303_SW_IMR_MAC0   0x00000001
 
#define LAN9303_SW_IPR_BM   0x00000040
 
#define LAN9303_SW_IPR_SWE   0x00000020
 
#define LAN9303_SW_IPR_MAC2   0x00000004
 
#define LAN9303_SW_IPR_MAC1   0x00000002
 
#define LAN9303_SW_IPR_MAC0   0x00000001
 
#define LAN9303_MAC_VER_ID_DEVICE_TYPE   0x00000F00
 
#define LAN9303_MAC_VER_ID_DEVICE_TYPE_DEFAULT   0x00000500
 
#define LAN9303_MAC_VER_ID_CHIP_VERSION   0x000000F0
 
#define LAN9303_MAC_VER_ID_CHIP_VERSION_DEFAULT   0x00000080
 
#define LAN9303_MAC_VER_ID_REVISION   0x0000000F
 
#define LAN9303_MAC_VER_ID_REVISION_DEFAULT   0x00000003
 
#define LAN9303_MAC_RX_CFG_RECEIVE_OWN_TRANSMIT_EN   0x00000020
 
#define LAN9303_MAC_RX_CFG_JUMBO_2K   0x00000008
 
#define LAN9303_MAC_RX_CFG_REJECT_MAC_TYPES   0x00000002
 
#define LAN9303_MAC_RX_CFG_RX_EN   0x00000001
 
#define LAN9303_MAC_TX_CFG_MAC_COUNTER_TEST   0x00000080
 
#define LAN9303_MAC_TX_CFG_IFG_CONFIG   0x0000007C
 
#define LAN9303_MAC_TX_CFG_IFG_CONFIG_DEFAULT   0x00000054
 
#define LAN9303_MAC_TX_CFG_TX_PAD_EN   0x00000002
 
#define LAN9303_MAC_TX_CFG_TX_EN   0x00000001
 
#define LAN9303_SWE_ALR_CMD_MAKE_ENTRY   0x00000004
 
#define LAN9303_SWE_ALR_CMD_GET_FIRST_ENTRY   0x00000002
 
#define LAN9303_SWE_ALR_CMD_GET_NEXT_ENTRY   0x00000001
 
#define LAN9303_SWE_ALR_WR_DAT0_MAC_ADDR   0xFFFFFFFF
 
#define LAN9303_SWE_ALR_WR_DAT1_VALID   0x04000000
 
#define LAN9303_SWE_ALR_WR_DAT1_AGE_OVERRIDE   0x02000000
 
#define LAN9303_SWE_ALR_WR_DAT1_STATIC   0x01000000
 
#define LAN9303_SWE_ALR_WR_DAT1_FILTER   0x00800000
 
#define LAN9303_SWE_ALR_WR_DAT1_PRIORITY_EN   0x00400000
 
#define LAN9303_SWE_ALR_WR_DAT1_PRIORITY   0x00380000
 
#define LAN9303_SWE_ALR_WR_DAT1_PORT   0x00070000
 
#define LAN9303_SWE_ALR_WR_DAT1_PORT_0   0x00000000
 
#define LAN9303_SWE_ALR_WR_DAT1_PORT_1   0x00010000
 
#define LAN9303_SWE_ALR_WR_DAT1_PORT_2   0x00020000
 
#define LAN9303_SWE_ALR_WR_DAT1_PORT_RESERVED   0x00030000
 
#define LAN9303_SWE_ALR_WR_DAT1_PORT_0_1   0x00040000
 
#define LAN9303_SWE_ALR_WR_DAT1_PORT_0_2   0x00050000
 
#define LAN9303_SWE_ALR_WR_DAT1_PORT_1_2   0x00060000
 
#define LAN9303_SWE_ALR_WR_DAT1_PORT_0_1_2   0x00070000
 
#define LAN9303_SWE_ALR_WR_DAT1_MAC_ADDR   0x0000FFFF
 
#define LAN9303_SWE_ALR_RD_DAT0_MAC_ADDR   0xFFFFFFFF
 
#define LAN9303_SWE_ALR_RD_DAT1_VALID   0x04000000
 
#define LAN9303_SWE_ALR_RD_DAT1_END_OF_TABLE   0x02000000
 
#define LAN9303_SWE_ALR_RD_DAT1_STATIC   0x01000000
 
#define LAN9303_SWE_ALR_RD_DAT1_FILTER   0x00800000
 
#define LAN9303_SWE_ALR_RD_DAT1_PRIORITY_EN   0x00400000
 
#define LAN9303_SWE_ALR_RD_DAT1_PRIORITY   0x00380000
 
#define LAN9303_SWE_ALR_RD_DAT1_PORT   0x00070000
 
#define LAN9303_SWE_ALR_RD_DAT1_PORT_0   0x00000000
 
#define LAN9303_SWE_ALR_RD_DAT1_PORT_1   0x00010000
 
#define LAN9303_SWE_ALR_RD_DAT1_PORT_2   0x00020000
 
#define LAN9303_SWE_ALR_RD_DAT1_PORT_RESERVED   0x00030000
 
#define LAN9303_SWE_ALR_RD_DAT1_PORT_0_1   0x00040000
 
#define LAN9303_SWE_ALR_RD_DAT1_PORT_0_2   0x00050000
 
#define LAN9303_SWE_ALR_RD_DAT1_PORT_1_2   0x00060000
 
#define LAN9303_SWE_ALR_RD_DAT1_PORT_0_1_2   0x00070000
 
#define LAN9303_SWE_ALR_RD_DAT1_MAC_ADDR   0x0000FFFF
 
#define LAN9303_SWE_ALR_CMD_STS_ALR_INIT_DONE   0x00000002
 
#define LAN9303_SWE_ALR_CMD_STS_MAKE_PENDING   0x00000001
 
#define LAN9303_SWE_ALR_CFG_ALR_AGE_TEST   0x00000001
 
#define LAN9303_SWE_PORT_STATE_PORT2   0x00000030
 
#define LAN9303_SWE_PORT_STATE_PORT2_FORWARDING   0x00000000
 
#define LAN9303_SWE_PORT_STATE_PORT2_LISTENING   0x00000010
 
#define LAN9303_SWE_PORT_STATE_PORT2_LEARNING   0x00000020
 
#define LAN9303_SWE_PORT_STATE_PORT2_DISABLED   0x00000030
 
#define LAN9303_SWE_PORT_STATE_PORT1   0x0000000C
 
#define LAN9303_SWE_PORT_STATE_PORT1_FORWARDING   0x00000000
 
#define LAN9303_SWE_PORT_STATE_PORT1_LISTENING   0x00000004
 
#define LAN9303_SWE_PORT_STATE_PORT1_LEARNING   0x00000008
 
#define LAN9303_SWE_PORT_STATE_PORT1_DISABLED   0x0000000C
 
#define LAN9303_SWE_PORT_STATE_PORT0   0x00000003
 
#define LAN9303_SWE_PORT_STATE_PORT0_FORWARDING   0x00000000
 
#define LAN9303_SWE_PORT_STATE_PORT0_LISTENING   0x00000001
 
#define LAN9303_SWE_PORT_STATE_PORT0_LEARNING   0x00000002
 
#define LAN9303_SWE_PORT_STATE_PORT0_DISABLED   0x00000003
 
#define LAN9303_SWE_PORT_MIRROR_RX_MIRRORING_FILT_EN   0x00000100
 
#define LAN9303_SWE_PORT_MIRROR_SNIFFER   0x000000E0
 
#define LAN9303_SWE_PORT_MIRROR_SNIFFER_PORT0   0x00000020
 
#define LAN9303_SWE_PORT_MIRROR_SNIFFER_PORT1   0x00000040
 
#define LAN9303_SWE_PORT_MIRROR_SNIFFER_PORT2   0x00000080
 
#define LAN9303_SWE_PORT_MIRROR_MIRRORED   0x0000001C
 
#define LAN9303_SWE_PORT_MIRROR_MIRRORED_PORT0   0x00000004
 
#define LAN9303_SWE_PORT_MIRROR_MIRRORED_PORT1   0x00000008
 
#define LAN9303_SWE_PORT_MIRROR_MIRRORED_PORT2   0x00000010
 
#define LAN9303_SWE_PORT_MIRROR_RX_MIRRORING_EN   0x00000002
 
#define LAN9303_SWE_PORT_MIRROR_TX_MIRRORING_EN   0x00000001
 
#define LAN9303_SWE_INGRSS_PORT_TYP_PORT2   0x00000030
 
#define LAN9303_SWE_INGRSS_PORT_TYP_PORT2_DIS   0x00000000
 
#define LAN9303_SWE_INGRSS_PORT_TYP_PORT2_EN   0x00000030
 
#define LAN9303_SWE_INGRSS_PORT_TYP_PORT1   0x0000000C
 
#define LAN9303_SWE_INGRSS_PORT_TYP_PORT1_DIS   0x00000000
 
#define LAN9303_SWE_INGRSS_PORT_TYP_PORT1_EN   0x0000000C
 
#define LAN9303_SWE_INGRSS_PORT_TYP_PORT0   0x00000003
 
#define LAN9303_SWE_INGRSS_PORT_TYP_PORT0_DIS   0x00000000
 
#define LAN9303_SWE_INGRSS_PORT_TYP_PORT0_EN   0x00000003
 
#define LAN9303_BM_EGRSS_PORT_TYPE_VID_SEL_PORT2   0x00400000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_INSERT_TAG_PORT2   0x00200000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_VID_PORT2   0x00100000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_PRIO_PORT2   0x00080000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_TAG_PORT2   0x00040000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT2   0x00030000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT2_DUMB   0x00000000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT2_ACCESS   0x00010000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT2_HYBRID   0x00020000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT2_CPU   0x00030000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_VID_SEL_PORT1   0x00004000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_INSERT_TAG_PORT1   0x00002000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_VID_PORT1   0x00001000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_PRIO_PORT1   0x00000800
 
#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_TAG_PORT1   0x00000400
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT1   0x00000300
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT1_DUMB   0x00000000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT1_ACCESS   0x00000100
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT1_HYBRID   0x00000200
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT1_CPU   0x00000300
 
#define LAN9303_BM_EGRSS_PORT_TYPE_VID_SEL_PORT0   0x00000040
 
#define LAN9303_BM_EGRSS_PORT_TYPE_INSERT_TAG_PORT0   0x00000020
 
#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_VID_PORT0   0x00000010
 
#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_PRIO_PORT0   0x00000008
 
#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_TAG_PORT0   0x00000004
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT0   0x00000003
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT0_DUMB   0x00000000
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT0_ACCESS   0x00000001
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT0_HYBRID   0x00000002
 
#define LAN9303_BM_EGRSS_PORT_TYPE_PORT0_CPU   0x00000003
 

Functions

error_t lan9303Init (NetInterface *interface)
 LAN9303 Ethernet switch initialization. More...
 
void lan9303Tick (NetInterface *interface)
 LAN9303 timer handler. More...
 
void lan9303EnableIrq (NetInterface *interface)
 Enable interrupts. More...
 
void lan9303DisableIrq (NetInterface *interface)
 Disable interrupts. More...
 
void lan9303EventHandler (NetInterface *interface)
 LAN9303 event handler. More...
 
error_t lan9303TagFrame (NetInterface *interface, NetBuffer *buffer, size_t *offset, NetTxAncillary *ancillary)
 Add special VLAN tag to Ethernet frame. More...
 
error_t lan9303UntagFrame (NetInterface *interface, uint8_t **frame, size_t *length, NetRxAncillary *ancillary)
 Decode special VLAN tag from incoming Ethernet frame. More...
 
bool_t lan9303GetLinkState (NetInterface *interface, uint8_t port)
 Get link state. More...
 
uint32_t lan9303GetLinkSpeed (NetInterface *interface, uint8_t port)
 Get link speed. More...
 
NicDuplexMode lan9303GetDuplexMode (NetInterface *interface, uint8_t port)
 Get duplex mode. More...
 
void lan9303SetPortState (NetInterface *interface, uint8_t port, SwitchPortState state)
 Set port state. More...
 
SwitchPortState lan9303GetPortState (NetInterface *interface, uint8_t port)
 Get port state. More...
 
void lan9303SetAgingTime (NetInterface *interface, uint32_t agingTime)
 Set aging time for dynamic filtering entries. More...
 
void lan9303EnableRsvdMcastTable (NetInterface *interface, bool_t enable)
 Enable reserved multicast table. More...
 
error_t lan9303AddStaticFdbEntry (NetInterface *interface, const SwitchFdbEntry *entry)
 Add a new entry to the static MAC table. More...
 
error_t lan9303DeleteStaticFdbEntry (NetInterface *interface, const SwitchFdbEntry *entry)
 Remove an entry from the static MAC table. More...
 
error_t lan9303GetStaticFdbEntry (NetInterface *interface, uint_t index, SwitchFdbEntry *entry)
 Read an entry from the static MAC table. More...
 
void lan9303FlushStaticFdbTable (NetInterface *interface)
 Flush static MAC table. More...
 
error_t lan9303GetDynamicFdbEntry (NetInterface *interface, uint_t index, SwitchFdbEntry *entry)
 Read an entry from the dynamic MAC table. More...
 
void lan9303FlushDynamicFdbTable (NetInterface *interface, uint8_t port)
 Flush dynamic MAC table. More...
 
void lan9303WritePhyReg (NetInterface *interface, uint8_t port, uint8_t address, uint16_t data)
 Write PHY register. More...
 
uint16_t lan9303ReadPhyReg (NetInterface *interface, uint8_t port, uint8_t address)
 Read PHY register. More...
 
void lan9303DumpPhyReg (NetInterface *interface, uint8_t port)
 Dump PHY registers for debugging purpose. More...
 
void lan9303WriteSysReg (NetInterface *interface, uint16_t address, uint32_t data)
 Write system CSR register. More...
 
uint32_t lan9303ReadSysReg (NetInterface *interface, uint16_t address)
 Read system CSR register. More...
 
void lan9303DumpSysReg (NetInterface *interface)
 Dump system CSR registers for debugging purpose. More...
 
void lan9303WriteSwitchReg (NetInterface *interface, uint16_t address, uint32_t data)
 Write switch fabric CSR register. More...
 
uint32_t lan9303ReadSwitchReg (NetInterface *interface, uint16_t address)
 Read switch fabric CSR register. More...
 

Variables

const SwitchDriver lan9303SwitchDriver
 LAN9303 Ethernet switch driver. More...
 

Detailed Description

LAN9303 3-port Ethernet switch driver.

License

SPDX-License-Identifier: GPL-2.0-or-later

Copyright (C) 2010-2020 Oryx Embedded SARL. All rights reserved.

This file is part of CycloneTCP Open.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.

Author
Oryx Embedded SARL (www.oryx-embedded.com)
Version
1.9.8

Definition in file lan9303_driver.h.

Macro Definition Documentation

◆ LAN9303_ALR_TABLE_SIZE

#define LAN9303_ALR_TABLE_SIZE   512

Definition at line 53 of file lan9303_driver.h.

◆ LAN9303_ANAR

#define LAN9303_ANAR   0x04

Definition at line 78 of file lan9303_driver.h.

◆ LAN9303_ANAR_100BTX_FD

#define LAN9303_ANAR_100BTX_FD   0x0100

Definition at line 165 of file lan9303_driver.h.

◆ LAN9303_ANAR_100BTX_HD

#define LAN9303_ANAR_100BTX_HD   0x0080

Definition at line 166 of file lan9303_driver.h.

◆ LAN9303_ANAR_10BT_FD

#define LAN9303_ANAR_10BT_FD   0x0040

Definition at line 167 of file lan9303_driver.h.

◆ LAN9303_ANAR_10BT_HD

#define LAN9303_ANAR_10BT_HD   0x0020

Definition at line 168 of file lan9303_driver.h.

◆ LAN9303_ANAR_ASYM_PAUSE

#define LAN9303_ANAR_ASYM_PAUSE   0x0800

Definition at line 163 of file lan9303_driver.h.

◆ LAN9303_ANAR_REMOTE_FAULT

#define LAN9303_ANAR_REMOTE_FAULT   0x2000

Definition at line 162 of file lan9303_driver.h.

◆ LAN9303_ANAR_SELECTOR

#define LAN9303_ANAR_SELECTOR   0x001F

Definition at line 169 of file lan9303_driver.h.

◆ LAN9303_ANAR_SELECTOR_DEFAULT

#define LAN9303_ANAR_SELECTOR_DEFAULT   0x0001

Definition at line 170 of file lan9303_driver.h.

◆ LAN9303_ANAR_SYM_PAUSE

#define LAN9303_ANAR_SYM_PAUSE   0x0400

Definition at line 164 of file lan9303_driver.h.

◆ LAN9303_ANER

#define LAN9303_ANER   0x06

Definition at line 80 of file lan9303_driver.h.

◆ LAN9303_ANER_LP_AN_ABLE

#define LAN9303_ANER_LP_AN_ABLE   0x0001

Definition at line 191 of file lan9303_driver.h.

◆ LAN9303_ANER_LP_NEXT_PAGE_ABLE

#define LAN9303_ANER_LP_NEXT_PAGE_ABLE   0x0008

Definition at line 188 of file lan9303_driver.h.

◆ LAN9303_ANER_NEXT_PAGE_ABLE

#define LAN9303_ANER_NEXT_PAGE_ABLE   0x0004

Definition at line 189 of file lan9303_driver.h.

◆ LAN9303_ANER_PAGE_RECEIVED

#define LAN9303_ANER_PAGE_RECEIVED   0x0002

Definition at line 190 of file lan9303_driver.h.

◆ LAN9303_ANER_PAR_DETECT_FAULT

#define LAN9303_ANER_PAR_DETECT_FAULT   0x0010

Definition at line 187 of file lan9303_driver.h.

◆ LAN9303_ANLPAR

#define LAN9303_ANLPAR   0x05

Definition at line 79 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_100BT4

#define LAN9303_ANLPAR_100BT4   0x0200

Definition at line 178 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_100BTX_FD

#define LAN9303_ANLPAR_100BTX_FD   0x0100

Definition at line 179 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_100BTX_HD

#define LAN9303_ANLPAR_100BTX_HD   0x0080

Definition at line 180 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_10BT_FD

#define LAN9303_ANLPAR_10BT_FD   0x0040

Definition at line 181 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_10BT_HD

#define LAN9303_ANLPAR_10BT_HD   0x0020

Definition at line 182 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_ACK

#define LAN9303_ANLPAR_ACK   0x4000

Definition at line 174 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_ASYM_PAUSE

#define LAN9303_ANLPAR_ASYM_PAUSE   0x0800

Definition at line 176 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_NEXT_PAGE

#define LAN9303_ANLPAR_NEXT_PAGE   0x8000

Definition at line 173 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_REMOTE_FAULT

#define LAN9303_ANLPAR_REMOTE_FAULT   0x2000

Definition at line 175 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_SELECTOR

#define LAN9303_ANLPAR_SELECTOR   0x001F

Definition at line 183 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_SELECTOR_DEFAULT

#define LAN9303_ANLPAR_SELECTOR_DEFAULT   0x0001

Definition at line 184 of file lan9303_driver.h.

◆ LAN9303_ANLPAR_SYM_PAUSE

#define LAN9303_ANLPAR_SYM_PAUSE   0x0400

Definition at line 177 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE

#define LAN9303_BM_EGRSS_PORT_TYPE   0x1C0C

Definition at line 118 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_PRIO_PORT0

#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_PRIO_PORT0   0x00000008

Definition at line 426 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_PRIO_PORT1

#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_PRIO_PORT1   0x00000800

Definition at line 416 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_PRIO_PORT2

#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_PRIO_PORT2   0x00080000

Definition at line 406 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_TAG_PORT0

#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_TAG_PORT0   0x00000004

Definition at line 427 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_TAG_PORT1

#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_TAG_PORT1   0x00000400

Definition at line 417 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_TAG_PORT2

#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_TAG_PORT2   0x00040000

Definition at line 407 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_VID_PORT0

#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_VID_PORT0   0x00000010

Definition at line 425 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_VID_PORT1

#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_VID_PORT1   0x00001000

Definition at line 415 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_VID_PORT2

#define LAN9303_BM_EGRSS_PORT_TYPE_CHANGE_VID_PORT2   0x00100000

Definition at line 405 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_INSERT_TAG_PORT0

#define LAN9303_BM_EGRSS_PORT_TYPE_INSERT_TAG_PORT0   0x00000020

Definition at line 424 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_INSERT_TAG_PORT1

#define LAN9303_BM_EGRSS_PORT_TYPE_INSERT_TAG_PORT1   0x00002000

Definition at line 414 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_INSERT_TAG_PORT2

#define LAN9303_BM_EGRSS_PORT_TYPE_INSERT_TAG_PORT2   0x00200000

Definition at line 404 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT0

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT0   0x00000003

Definition at line 428 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT0_ACCESS

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT0_ACCESS   0x00000001

Definition at line 430 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT0_CPU

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT0_CPU   0x00000003

Definition at line 432 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT0_DUMB

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT0_DUMB   0x00000000

Definition at line 429 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT0_HYBRID

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT0_HYBRID   0x00000002

Definition at line 431 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT1

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT1   0x00000300

Definition at line 418 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT1_ACCESS

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT1_ACCESS   0x00000100

Definition at line 420 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT1_CPU

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT1_CPU   0x00000300

Definition at line 422 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT1_DUMB

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT1_DUMB   0x00000000

Definition at line 419 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT1_HYBRID

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT1_HYBRID   0x00000200

Definition at line 421 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT2

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT2   0x00030000

Definition at line 408 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT2_ACCESS

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT2_ACCESS   0x00010000

Definition at line 410 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT2_CPU

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT2_CPU   0x00030000

Definition at line 412 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT2_DUMB

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT2_DUMB   0x00000000

Definition at line 409 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_PORT2_HYBRID

#define LAN9303_BM_EGRSS_PORT_TYPE_PORT2_HYBRID   0x00020000

Definition at line 411 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_VID_SEL_PORT0

#define LAN9303_BM_EGRSS_PORT_TYPE_VID_SEL_PORT0   0x00000040

Definition at line 423 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_VID_SEL_PORT1

#define LAN9303_BM_EGRSS_PORT_TYPE_VID_SEL_PORT1   0x00004000

Definition at line 413 of file lan9303_driver.h.

◆ LAN9303_BM_EGRSS_PORT_TYPE_VID_SEL_PORT2

#define LAN9303_BM_EGRSS_PORT_TYPE_VID_SEL_PORT2   0x00400000

Definition at line 403 of file lan9303_driver.h.

◆ LAN9303_BMCR

#define LAN9303_BMCR   0x00

Definition at line 74 of file lan9303_driver.h.

◆ LAN9303_BMCR_AN_EN

#define LAN9303_BMCR_AN_EN   0x1000

Definition at line 129 of file lan9303_driver.h.

◆ LAN9303_BMCR_COL_TEST

#define LAN9303_BMCR_COL_TEST   0x0080

Definition at line 133 of file lan9303_driver.h.

◆ LAN9303_BMCR_DUPLEX_MODE

#define LAN9303_BMCR_DUPLEX_MODE   0x0100

Definition at line 132 of file lan9303_driver.h.

◆ LAN9303_BMCR_LOOPBACK

#define LAN9303_BMCR_LOOPBACK   0x4000

Definition at line 127 of file lan9303_driver.h.

◆ LAN9303_BMCR_POWER_DOWN

#define LAN9303_BMCR_POWER_DOWN   0x0800

Definition at line 130 of file lan9303_driver.h.

◆ LAN9303_BMCR_RESET

#define LAN9303_BMCR_RESET   0x8000

Definition at line 126 of file lan9303_driver.h.

◆ LAN9303_BMCR_RESTART_AN

#define LAN9303_BMCR_RESTART_AN   0x0200

Definition at line 131 of file lan9303_driver.h.

◆ LAN9303_BMCR_SPEED_SEL

#define LAN9303_BMCR_SPEED_SEL   0x2000

Definition at line 128 of file lan9303_driver.h.

◆ LAN9303_BMSR

#define LAN9303_BMSR   0x01

Definition at line 75 of file lan9303_driver.h.

◆ LAN9303_BMSR_100BT2_FD

#define LAN9303_BMSR_100BT2_FD   0x0400

Definition at line 141 of file lan9303_driver.h.

◆ LAN9303_BMSR_100BT2_HD

#define LAN9303_BMSR_100BT2_HD   0x0200

Definition at line 142 of file lan9303_driver.h.

◆ LAN9303_BMSR_100BT4

#define LAN9303_BMSR_100BT4   0x8000

Definition at line 136 of file lan9303_driver.h.

◆ LAN9303_BMSR_100BTX_FD

#define LAN9303_BMSR_100BTX_FD   0x4000

Definition at line 137 of file lan9303_driver.h.

◆ LAN9303_BMSR_100BTX_HD

#define LAN9303_BMSR_100BTX_HD   0x2000

Definition at line 138 of file lan9303_driver.h.

◆ LAN9303_BMSR_10BT_FD

#define LAN9303_BMSR_10BT_FD   0x1000

Definition at line 139 of file lan9303_driver.h.

◆ LAN9303_BMSR_10BT_HD

#define LAN9303_BMSR_10BT_HD   0x0800

Definition at line 140 of file lan9303_driver.h.

◆ LAN9303_BMSR_AN_CAPABLE

#define LAN9303_BMSR_AN_CAPABLE   0x0008

Definition at line 145 of file lan9303_driver.h.

◆ LAN9303_BMSR_AN_COMPLETE

#define LAN9303_BMSR_AN_COMPLETE   0x0020

Definition at line 143 of file lan9303_driver.h.

◆ LAN9303_BMSR_EXTENDED_CAPABLE

#define LAN9303_BMSR_EXTENDED_CAPABLE   0x0001

Definition at line 148 of file lan9303_driver.h.

◆ LAN9303_BMSR_JABBER_DETECT

#define LAN9303_BMSR_JABBER_DETECT   0x0002

Definition at line 147 of file lan9303_driver.h.

◆ LAN9303_BMSR_LINK_STATUS

#define LAN9303_BMSR_LINK_STATUS   0x0004

Definition at line 146 of file lan9303_driver.h.

◆ LAN9303_BMSR_REMOTE_FAULT

#define LAN9303_BMSR_REMOTE_FAULT   0x0010

Definition at line 144 of file lan9303_driver.h.

◆ LAN9303_BYTE_TEST

#define LAN9303_BYTE_TEST   0x0064

Definition at line 89 of file lan9303_driver.h.

◆ LAN9303_BYTE_TEST_DEFAULT

#define LAN9303_BYTE_TEST_DEFAULT   0x87654321

Definition at line 242 of file lan9303_driver.h.

◆ LAN9303_HW_CFG

#define LAN9303_HW_CFG   0x0074

Definition at line 90 of file lan9303_driver.h.

◆ LAN9303_HW_CFG_AMDIX_EN_STRAP_STATE_PORT1

#define LAN9303_HW_CFG_AMDIX_EN_STRAP_STATE_PORT1   0x02000000

Definition at line 247 of file lan9303_driver.h.

◆ LAN9303_HW_CFG_AMDIX_EN_STRAP_STATE_PORT2

#define LAN9303_HW_CFG_AMDIX_EN_STRAP_STATE_PORT2   0x04000000

Definition at line 246 of file lan9303_driver.h.

◆ LAN9303_HW_CFG_DEVICE_READY

#define LAN9303_HW_CFG_DEVICE_READY   0x08000000

Definition at line 245 of file lan9303_driver.h.

◆ LAN9303_MAC_RX_CFG

#define LAN9303_MAC_RX_CFG (   port)    (0x0401 + ((port) * 0x0400))

Definition at line 122 of file lan9303_driver.h.

◆ LAN9303_MAC_RX_CFG0

#define LAN9303_MAC_RX_CFG0   0x0401

Definition at line 100 of file lan9303_driver.h.

◆ LAN9303_MAC_RX_CFG1

#define LAN9303_MAC_RX_CFG1   0x0801

Definition at line 103 of file lan9303_driver.h.

◆ LAN9303_MAC_RX_CFG2

#define LAN9303_MAC_RX_CFG2   0x0C01

Definition at line 106 of file lan9303_driver.h.

◆ LAN9303_MAC_RX_CFG_JUMBO_2K

#define LAN9303_MAC_RX_CFG_JUMBO_2K   0x00000008

Definition at line 296 of file lan9303_driver.h.

◆ LAN9303_MAC_RX_CFG_RECEIVE_OWN_TRANSMIT_EN

#define LAN9303_MAC_RX_CFG_RECEIVE_OWN_TRANSMIT_EN   0x00000020

Definition at line 295 of file lan9303_driver.h.

◆ LAN9303_MAC_RX_CFG_REJECT_MAC_TYPES

#define LAN9303_MAC_RX_CFG_REJECT_MAC_TYPES   0x00000002

Definition at line 297 of file lan9303_driver.h.

◆ LAN9303_MAC_RX_CFG_RX_EN

#define LAN9303_MAC_RX_CFG_RX_EN   0x00000001

Definition at line 298 of file lan9303_driver.h.

◆ LAN9303_MAC_TX_CFG

#define LAN9303_MAC_TX_CFG (   port)    (0x0440 + ((port) * 0x0400))

Definition at line 123 of file lan9303_driver.h.

◆ LAN9303_MAC_TX_CFG0

#define LAN9303_MAC_TX_CFG0   0x0440

Definition at line 101 of file lan9303_driver.h.

◆ LAN9303_MAC_TX_CFG1

#define LAN9303_MAC_TX_CFG1   0x0840

Definition at line 104 of file lan9303_driver.h.

◆ LAN9303_MAC_TX_CFG2

#define LAN9303_MAC_TX_CFG2   0x0C40

Definition at line 107 of file lan9303_driver.h.

◆ LAN9303_MAC_TX_CFG_IFG_CONFIG

#define LAN9303_MAC_TX_CFG_IFG_CONFIG   0x0000007C

Definition at line 302 of file lan9303_driver.h.

◆ LAN9303_MAC_TX_CFG_IFG_CONFIG_DEFAULT

#define LAN9303_MAC_TX_CFG_IFG_CONFIG_DEFAULT   0x00000054

Definition at line 303 of file lan9303_driver.h.

◆ LAN9303_MAC_TX_CFG_MAC_COUNTER_TEST

#define LAN9303_MAC_TX_CFG_MAC_COUNTER_TEST   0x00000080

Definition at line 301 of file lan9303_driver.h.

◆ LAN9303_MAC_TX_CFG_TX_EN

#define LAN9303_MAC_TX_CFG_TX_EN   0x00000001

Definition at line 305 of file lan9303_driver.h.

◆ LAN9303_MAC_TX_CFG_TX_PAD_EN

#define LAN9303_MAC_TX_CFG_TX_PAD_EN   0x00000002

Definition at line 304 of file lan9303_driver.h.

◆ LAN9303_MAC_VER_ID

#define LAN9303_MAC_VER_ID (   port)    (0x0400 + ((port) * 0x0400))

Definition at line 121 of file lan9303_driver.h.

◆ LAN9303_MAC_VER_ID0

#define LAN9303_MAC_VER_ID0   0x0400

Definition at line 99 of file lan9303_driver.h.

◆ LAN9303_MAC_VER_ID1

#define LAN9303_MAC_VER_ID1   0x0800

Definition at line 102 of file lan9303_driver.h.

◆ LAN9303_MAC_VER_ID2

#define LAN9303_MAC_VER_ID2   0x0C00

Definition at line 105 of file lan9303_driver.h.

◆ LAN9303_MAC_VER_ID_CHIP_VERSION

#define LAN9303_MAC_VER_ID_CHIP_VERSION   0x000000F0

Definition at line 289 of file lan9303_driver.h.

◆ LAN9303_MAC_VER_ID_CHIP_VERSION_DEFAULT

#define LAN9303_MAC_VER_ID_CHIP_VERSION_DEFAULT   0x00000080

Definition at line 290 of file lan9303_driver.h.

◆ LAN9303_MAC_VER_ID_DEVICE_TYPE

#define LAN9303_MAC_VER_ID_DEVICE_TYPE   0x00000F00

Definition at line 287 of file lan9303_driver.h.

◆ LAN9303_MAC_VER_ID_DEVICE_TYPE_DEFAULT

#define LAN9303_MAC_VER_ID_DEVICE_TYPE_DEFAULT   0x00000500

Definition at line 288 of file lan9303_driver.h.

◆ LAN9303_MAC_VER_ID_REVISION

#define LAN9303_MAC_VER_ID_REVISION   0x0000000F

Definition at line 291 of file lan9303_driver.h.

◆ LAN9303_MAC_VER_ID_REVISION_DEFAULT

#define LAN9303_MAC_VER_ID_REVISION_DEFAULT   0x00000003

Definition at line 292 of file lan9303_driver.h.

◆ LAN9303_PHYID1

#define LAN9303_PHYID1   0x02

Definition at line 76 of file lan9303_driver.h.

◆ LAN9303_PHYID1_PHY_ID_MSB

#define LAN9303_PHYID1_PHY_ID_MSB   0xFFFF

Definition at line 151 of file lan9303_driver.h.

◆ LAN9303_PHYID1_PHY_ID_MSB_DEFAULT

#define LAN9303_PHYID1_PHY_ID_MSB_DEFAULT   0x0007

Definition at line 152 of file lan9303_driver.h.

◆ LAN9303_PHYID2

#define LAN9303_PHYID2   0x03

Definition at line 77 of file lan9303_driver.h.

◆ LAN9303_PHYID2_MODEL_NUM

#define LAN9303_PHYID2_MODEL_NUM   0x03F0

Definition at line 157 of file lan9303_driver.h.

◆ LAN9303_PHYID2_MODEL_NUM_DEFAULT

#define LAN9303_PHYID2_MODEL_NUM_DEFAULT   0x00D0

Definition at line 158 of file lan9303_driver.h.

◆ LAN9303_PHYID2_PHY_ID_LSB

#define LAN9303_PHYID2_PHY_ID_LSB   0xFFFF

Definition at line 155 of file lan9303_driver.h.

◆ LAN9303_PHYID2_PHY_ID_LSB_DEFAULT

#define LAN9303_PHYID2_PHY_ID_LSB_DEFAULT   0x0030

Definition at line 156 of file lan9303_driver.h.

◆ LAN9303_PHYID2_REVISION_NUM

#define LAN9303_PHYID2_REVISION_NUM   0x000F

Definition at line 159 of file lan9303_driver.h.

◆ LAN9303_PIMR

#define LAN9303_PIMR   0x1E

Definition at line 85 of file lan9303_driver.h.

◆ LAN9303_PIMR_AN_COMPLETE

#define LAN9303_PIMR_AN_COMPLETE   0x0040

Definition at line 226 of file lan9303_driver.h.

◆ LAN9303_PIMR_AN_LP_ACK

#define LAN9303_PIMR_AN_LP_ACK   0x0008

Definition at line 229 of file lan9303_driver.h.

◆ LAN9303_PIMR_AN_PAGE_RECEIVED

#define LAN9303_PIMR_AN_PAGE_RECEIVED   0x0002

Definition at line 231 of file lan9303_driver.h.

◆ LAN9303_PIMR_ENERGYON

#define LAN9303_PIMR_ENERGYON   0x0080

Definition at line 225 of file lan9303_driver.h.

◆ LAN9303_PIMR_LINK_DOWN

#define LAN9303_PIMR_LINK_DOWN   0x0010

Definition at line 228 of file lan9303_driver.h.

◆ LAN9303_PIMR_PAR_DETECT_FAULT

#define LAN9303_PIMR_PAR_DETECT_FAULT   0x0004

Definition at line 230 of file lan9303_driver.h.

◆ LAN9303_PIMR_REMOTE_FAULT

#define LAN9303_PIMR_REMOTE_FAULT   0x0020

Definition at line 227 of file lan9303_driver.h.

◆ LAN9303_PISR

#define LAN9303_PISR   0x1D

Definition at line 84 of file lan9303_driver.h.

◆ LAN9303_PISR_AN_COMPLETE

#define LAN9303_PISR_AN_COMPLETE   0x0040

Definition at line 217 of file lan9303_driver.h.

◆ LAN9303_PISR_AN_LP_ACK

#define LAN9303_PISR_AN_LP_ACK   0x0008

Definition at line 220 of file lan9303_driver.h.

◆ LAN9303_PISR_AN_PAGE_RECEIVED

#define LAN9303_PISR_AN_PAGE_RECEIVED   0x0002

Definition at line 222 of file lan9303_driver.h.

◆ LAN9303_PISR_ENERGYON

#define LAN9303_PISR_ENERGYON   0x0080

Definition at line 216 of file lan9303_driver.h.

◆ LAN9303_PISR_LINK_DOWN

#define LAN9303_PISR_LINK_DOWN   0x0010

Definition at line 219 of file lan9303_driver.h.

◆ LAN9303_PISR_PAR_DETECT_FAULT

#define LAN9303_PISR_PAR_DETECT_FAULT   0x0004

Definition at line 221 of file lan9303_driver.h.

◆ LAN9303_PISR_REMOTE_FAULT

#define LAN9303_PISR_REMOTE_FAULT   0x0020

Definition at line 218 of file lan9303_driver.h.

◆ LAN9303_PMCSR

#define LAN9303_PMCSR   0x11

Definition at line 81 of file lan9303_driver.h.

◆ LAN9303_PMCSR_EDPWRDOWN

#define LAN9303_PMCSR_EDPWRDOWN   0x2000

Definition at line 194 of file lan9303_driver.h.

◆ LAN9303_PMCSR_ENERGYON

#define LAN9303_PMCSR_ENERGYON   0x0002

Definition at line 195 of file lan9303_driver.h.

◆ LAN9303_PORT0

#define LAN9303_PORT0   3

Definition at line 38 of file lan9303_driver.h.

◆ LAN9303_PORT0_1_2_MASK

#define LAN9303_PORT0_1_2_MASK   0x07

Definition at line 50 of file lan9303_driver.h.

◆ LAN9303_PORT0_1_MASK

#define LAN9303_PORT0_1_MASK   0x05

Definition at line 47 of file lan9303_driver.h.

◆ LAN9303_PORT0_2_MASK

#define LAN9303_PORT0_2_MASK   0x06

Definition at line 48 of file lan9303_driver.h.

◆ LAN9303_PORT0_MASK

#define LAN9303_PORT0_MASK   0x04

Definition at line 44 of file lan9303_driver.h.

◆ LAN9303_PORT1

#define LAN9303_PORT1   1

Definition at line 39 of file lan9303_driver.h.

◆ LAN9303_PORT1_2_MASK

#define LAN9303_PORT1_2_MASK   0x03

Definition at line 49 of file lan9303_driver.h.

◆ LAN9303_PORT1_MASK

#define LAN9303_PORT1_MASK   0x01

Definition at line 45 of file lan9303_driver.h.

◆ LAN9303_PORT2

#define LAN9303_PORT2   2

Definition at line 40 of file lan9303_driver.h.

◆ LAN9303_PORT2_MASK

#define LAN9303_PORT2_MASK   0x02

Definition at line 46 of file lan9303_driver.h.

◆ LAN9303_PORT_MASK

#define LAN9303_PORT_MASK   0x07

Definition at line 43 of file lan9303_driver.h.

◆ LAN9303_PSCSIR

#define LAN9303_PSCSIR   0x1B

Definition at line 83 of file lan9303_driver.h.

◆ LAN9303_PSCSIR_AMDIXCTRL

#define LAN9303_PSCSIR_AMDIXCTRL   0x8000

Definition at line 208 of file lan9303_driver.h.

◆ LAN9303_PSCSIR_AMDIXEN

#define LAN9303_PSCSIR_AMDIXEN   0x4000

Definition at line 209 of file lan9303_driver.h.

◆ LAN9303_PSCSIR_AMDIXSTATE

#define LAN9303_PSCSIR_AMDIXSTATE   0x2000

Definition at line 210 of file lan9303_driver.h.

◆ LAN9303_PSCSIR_SQEOFF

#define LAN9303_PSCSIR_SQEOFF   0x0800

Definition at line 211 of file lan9303_driver.h.

◆ LAN9303_PSCSIR_VCOOFF_LP

#define LAN9303_PSCSIR_VCOOFF_LP   0x0400

Definition at line 212 of file lan9303_driver.h.

◆ LAN9303_PSCSIR_XPOL

#define LAN9303_PSCSIR_XPOL   0x0010

Definition at line 213 of file lan9303_driver.h.

◆ LAN9303_PSCSR

#define LAN9303_PSCSR   0x1F

Definition at line 86 of file lan9303_driver.h.

◆ LAN9303_PSCSR_AUTODONE

#define LAN9303_PSCSR_AUTODONE   0x1000

Definition at line 234 of file lan9303_driver.h.

◆ LAN9303_PSCSR_SPEED

#define LAN9303_PSCSR_SPEED   0x001C

Definition at line 235 of file lan9303_driver.h.

◆ LAN9303_PSCSR_SPEED_100BTX_FD

#define LAN9303_PSCSR_SPEED_100BTX_FD   0x0018

Definition at line 239 of file lan9303_driver.h.

◆ LAN9303_PSCSR_SPEED_100BTX_HD

#define LAN9303_PSCSR_SPEED_100BTX_HD   0x0008

Definition at line 237 of file lan9303_driver.h.

◆ LAN9303_PSCSR_SPEED_10BT_FD

#define LAN9303_PSCSR_SPEED_10BT_FD   0x0014

Definition at line 238 of file lan9303_driver.h.

◆ LAN9303_PSCSR_SPEED_10BT_HD

#define LAN9303_PSCSR_SPEED_10BT_HD   0x0004

Definition at line 236 of file lan9303_driver.h.

◆ LAN9303_PSMR

#define LAN9303_PSMR   0x12

Definition at line 82 of file lan9303_driver.h.

◆ LAN9303_PSMR_MODE

#define LAN9303_PSMR_MODE   0x00E0

Definition at line 198 of file lan9303_driver.h.

◆ LAN9303_PSMR_MODE_100BTX_FD

#define LAN9303_PSMR_MODE_100BTX_FD   0x0060

Definition at line 202 of file lan9303_driver.h.

◆ LAN9303_PSMR_MODE_100BTX_HD

#define LAN9303_PSMR_MODE_100BTX_HD   0x0040

Definition at line 201 of file lan9303_driver.h.

◆ LAN9303_PSMR_MODE_10BT_FD

#define LAN9303_PSMR_MODE_10BT_FD   0x0020

Definition at line 200 of file lan9303_driver.h.

◆ LAN9303_PSMR_MODE_10BT_HD

#define LAN9303_PSMR_MODE_10BT_HD   0x0000

Definition at line 199 of file lan9303_driver.h.

◆ LAN9303_PSMR_MODE_AN

#define LAN9303_PSMR_MODE_AN   0x00E0

Definition at line 204 of file lan9303_driver.h.

◆ LAN9303_PSMR_MODE_POWER_DOWN

#define LAN9303_PSMR_MODE_POWER_DOWN   0x00C0

Definition at line 203 of file lan9303_driver.h.

◆ LAN9303_PSMR_PHYAD

#define LAN9303_PSMR_PHYAD   0x001F

Definition at line 205 of file lan9303_driver.h.

◆ LAN9303_SW_DEV_ID

#define LAN9303_SW_DEV_ID   0x0000

Definition at line 95 of file lan9303_driver.h.

◆ LAN9303_SW_DEV_ID_CHIP_VERSION

#define LAN9303_SW_DEV_ID_CHIP_VERSION   0x0000FF00

Definition at line 264 of file lan9303_driver.h.

◆ LAN9303_SW_DEV_ID_CHIP_VERSION_DEFAULT

#define LAN9303_SW_DEV_ID_CHIP_VERSION_DEFAULT   0x00000400

Definition at line 265 of file lan9303_driver.h.

◆ LAN9303_SW_DEV_ID_DEVICE_TYPE

#define LAN9303_SW_DEV_ID_DEVICE_TYPE   0x00FF0000

Definition at line 262 of file lan9303_driver.h.

◆ LAN9303_SW_DEV_ID_DEVICE_TYPE_DEFAULT

#define LAN9303_SW_DEV_ID_DEVICE_TYPE_DEFAULT   0x00030000

Definition at line 263 of file lan9303_driver.h.

◆ LAN9303_SW_DEV_ID_REVISION

#define LAN9303_SW_DEV_ID_REVISION   0x000000FF

Definition at line 266 of file lan9303_driver.h.

◆ LAN9303_SW_DEV_ID_REVISION_DEFAULT

#define LAN9303_SW_DEV_ID_REVISION_DEFAULT   0x00000007

Definition at line 267 of file lan9303_driver.h.

◆ LAN9303_SW_IMR

#define LAN9303_SW_IMR   0x0004

Definition at line 97 of file lan9303_driver.h.

◆ LAN9303_SW_IMR_BM

#define LAN9303_SW_IMR_BM   0x00000040

Definition at line 273 of file lan9303_driver.h.

◆ LAN9303_SW_IMR_MAC0

#define LAN9303_SW_IMR_MAC0   0x00000001

Definition at line 277 of file lan9303_driver.h.

◆ LAN9303_SW_IMR_MAC1

#define LAN9303_SW_IMR_MAC1   0x00000002

Definition at line 276 of file lan9303_driver.h.

◆ LAN9303_SW_IMR_MAC2

#define LAN9303_SW_IMR_MAC2   0x00000004

Definition at line 275 of file lan9303_driver.h.

◆ LAN9303_SW_IMR_SWE

#define LAN9303_SW_IMR_SWE   0x00000020

Definition at line 274 of file lan9303_driver.h.

◆ LAN9303_SW_IPR

#define LAN9303_SW_IPR   0x0005

Definition at line 98 of file lan9303_driver.h.

◆ LAN9303_SW_IPR_BM

#define LAN9303_SW_IPR_BM   0x00000040

Definition at line 280 of file lan9303_driver.h.

◆ LAN9303_SW_IPR_MAC0

#define LAN9303_SW_IPR_MAC0   0x00000001

Definition at line 284 of file lan9303_driver.h.

◆ LAN9303_SW_IPR_MAC1

#define LAN9303_SW_IPR_MAC1   0x00000002

Definition at line 283 of file lan9303_driver.h.

◆ LAN9303_SW_IPR_MAC2

#define LAN9303_SW_IPR_MAC2   0x00000004

Definition at line 282 of file lan9303_driver.h.

◆ LAN9303_SW_IPR_SWE

#define LAN9303_SW_IPR_SWE   0x00000020

Definition at line 281 of file lan9303_driver.h.

◆ LAN9303_SW_RESET

#define LAN9303_SW_RESET   0x0001

Definition at line 96 of file lan9303_driver.h.

◆ LAN9303_SW_RESET_SW_RESET

#define LAN9303_SW_RESET_SW_RESET   0x00000001

Definition at line 270 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_CFG

#define LAN9303_SWE_ALR_CFG   0x1809

Definition at line 114 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_CFG_ALR_AGE_TEST

#define LAN9303_SWE_ALR_CFG_ALR_AGE_TEST   0x00000001

Definition at line 359 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_CMD

#define LAN9303_SWE_ALR_CMD   0x1800

Definition at line 108 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_CMD_GET_FIRST_ENTRY

#define LAN9303_SWE_ALR_CMD_GET_FIRST_ENTRY   0x00000002

Definition at line 309 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_CMD_GET_NEXT_ENTRY

#define LAN9303_SWE_ALR_CMD_GET_NEXT_ENTRY   0x00000001

Definition at line 310 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_CMD_MAKE_ENTRY

#define LAN9303_SWE_ALR_CMD_MAKE_ENTRY   0x00000004

Definition at line 308 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_CMD_STS

#define LAN9303_SWE_ALR_CMD_STS   0x1808

Definition at line 113 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_CMD_STS_ALR_INIT_DONE

#define LAN9303_SWE_ALR_CMD_STS_ALR_INIT_DONE   0x00000002

Definition at line 355 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_CMD_STS_MAKE_PENDING

#define LAN9303_SWE_ALR_CMD_STS_MAKE_PENDING   0x00000001

Definition at line 356 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT0

#define LAN9303_SWE_ALR_RD_DAT0   0x1805

Definition at line 111 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT0_MAC_ADDR

#define LAN9303_SWE_ALR_RD_DAT0_MAC_ADDR   0xFFFFFFFF

Definition at line 334 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1

#define LAN9303_SWE_ALR_RD_DAT1   0x1806

Definition at line 112 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_END_OF_TABLE

#define LAN9303_SWE_ALR_RD_DAT1_END_OF_TABLE   0x02000000

Definition at line 338 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_FILTER

#define LAN9303_SWE_ALR_RD_DAT1_FILTER   0x00800000

Definition at line 340 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_MAC_ADDR

#define LAN9303_SWE_ALR_RD_DAT1_MAC_ADDR   0x0000FFFF

Definition at line 352 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_PORT

#define LAN9303_SWE_ALR_RD_DAT1_PORT   0x00070000

Definition at line 343 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_PORT_0

#define LAN9303_SWE_ALR_RD_DAT1_PORT_0   0x00000000

Definition at line 344 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_PORT_0_1

#define LAN9303_SWE_ALR_RD_DAT1_PORT_0_1   0x00040000

Definition at line 348 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_PORT_0_1_2

#define LAN9303_SWE_ALR_RD_DAT1_PORT_0_1_2   0x00070000

Definition at line 351 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_PORT_0_2

#define LAN9303_SWE_ALR_RD_DAT1_PORT_0_2   0x00050000

Definition at line 349 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_PORT_1

#define LAN9303_SWE_ALR_RD_DAT1_PORT_1   0x00010000

Definition at line 345 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_PORT_1_2

#define LAN9303_SWE_ALR_RD_DAT1_PORT_1_2   0x00060000

Definition at line 350 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_PORT_2

#define LAN9303_SWE_ALR_RD_DAT1_PORT_2   0x00020000

Definition at line 346 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_PORT_RESERVED

#define LAN9303_SWE_ALR_RD_DAT1_PORT_RESERVED   0x00030000

Definition at line 347 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_PRIORITY

#define LAN9303_SWE_ALR_RD_DAT1_PRIORITY   0x00380000

Definition at line 342 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_PRIORITY_EN

#define LAN9303_SWE_ALR_RD_DAT1_PRIORITY_EN   0x00400000

Definition at line 341 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_STATIC

#define LAN9303_SWE_ALR_RD_DAT1_STATIC   0x01000000

Definition at line 339 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_RD_DAT1_VALID

#define LAN9303_SWE_ALR_RD_DAT1_VALID   0x04000000

Definition at line 337 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT0

#define LAN9303_SWE_ALR_WR_DAT0   0x1801

Definition at line 109 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT0_MAC_ADDR

#define LAN9303_SWE_ALR_WR_DAT0_MAC_ADDR   0xFFFFFFFF

Definition at line 313 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1

#define LAN9303_SWE_ALR_WR_DAT1   0x1802

Definition at line 110 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_AGE_OVERRIDE

#define LAN9303_SWE_ALR_WR_DAT1_AGE_OVERRIDE   0x02000000

Definition at line 317 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_FILTER

#define LAN9303_SWE_ALR_WR_DAT1_FILTER   0x00800000

Definition at line 319 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_MAC_ADDR

#define LAN9303_SWE_ALR_WR_DAT1_MAC_ADDR   0x0000FFFF

Definition at line 331 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_PORT

#define LAN9303_SWE_ALR_WR_DAT1_PORT   0x00070000

Definition at line 322 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_PORT_0

#define LAN9303_SWE_ALR_WR_DAT1_PORT_0   0x00000000

Definition at line 323 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_PORT_0_1

#define LAN9303_SWE_ALR_WR_DAT1_PORT_0_1   0x00040000

Definition at line 327 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_PORT_0_1_2

#define LAN9303_SWE_ALR_WR_DAT1_PORT_0_1_2   0x00070000

Definition at line 330 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_PORT_0_2

#define LAN9303_SWE_ALR_WR_DAT1_PORT_0_2   0x00050000

Definition at line 328 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_PORT_1

#define LAN9303_SWE_ALR_WR_DAT1_PORT_1   0x00010000

Definition at line 324 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_PORT_1_2

#define LAN9303_SWE_ALR_WR_DAT1_PORT_1_2   0x00060000

Definition at line 329 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_PORT_2

#define LAN9303_SWE_ALR_WR_DAT1_PORT_2   0x00020000

Definition at line 325 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_PORT_RESERVED

#define LAN9303_SWE_ALR_WR_DAT1_PORT_RESERVED   0x00030000

Definition at line 326 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_PRIORITY

#define LAN9303_SWE_ALR_WR_DAT1_PRIORITY   0x00380000

Definition at line 321 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_PRIORITY_EN

#define LAN9303_SWE_ALR_WR_DAT1_PRIORITY_EN   0x00400000

Definition at line 320 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_STATIC

#define LAN9303_SWE_ALR_WR_DAT1_STATIC   0x01000000

Definition at line 318 of file lan9303_driver.h.

◆ LAN9303_SWE_ALR_WR_DAT1_VALID

#define LAN9303_SWE_ALR_WR_DAT1_VALID   0x04000000

Definition at line 316 of file lan9303_driver.h.

◆ LAN9303_SWE_INGRSS_PORT_TYP

#define LAN9303_SWE_INGRSS_PORT_TYP   0x1847

Definition at line 117 of file lan9303_driver.h.

◆ LAN9303_SWE_INGRSS_PORT_TYP_PORT0

#define LAN9303_SWE_INGRSS_PORT_TYP_PORT0   0x00000003

Definition at line 398 of file lan9303_driver.h.

◆ LAN9303_SWE_INGRSS_PORT_TYP_PORT0_DIS

#define LAN9303_SWE_INGRSS_PORT_TYP_PORT0_DIS   0x00000000

Definition at line 399 of file lan9303_driver.h.

◆ LAN9303_SWE_INGRSS_PORT_TYP_PORT0_EN

#define LAN9303_SWE_INGRSS_PORT_TYP_PORT0_EN   0x00000003

Definition at line 400 of file lan9303_driver.h.

◆ LAN9303_SWE_INGRSS_PORT_TYP_PORT1

#define LAN9303_SWE_INGRSS_PORT_TYP_PORT1   0x0000000C

Definition at line 395 of file lan9303_driver.h.

◆ LAN9303_SWE_INGRSS_PORT_TYP_PORT1_DIS

#define LAN9303_SWE_INGRSS_PORT_TYP_PORT1_DIS   0x00000000

Definition at line 396 of file lan9303_driver.h.

◆ LAN9303_SWE_INGRSS_PORT_TYP_PORT1_EN

#define LAN9303_SWE_INGRSS_PORT_TYP_PORT1_EN   0x0000000C

Definition at line 397 of file lan9303_driver.h.

◆ LAN9303_SWE_INGRSS_PORT_TYP_PORT2

#define LAN9303_SWE_INGRSS_PORT_TYP_PORT2   0x00000030

Definition at line 392 of file lan9303_driver.h.

◆ LAN9303_SWE_INGRSS_PORT_TYP_PORT2_DIS

#define LAN9303_SWE_INGRSS_PORT_TYP_PORT2_DIS   0x00000000

Definition at line 393 of file lan9303_driver.h.

◆ LAN9303_SWE_INGRSS_PORT_TYP_PORT2_EN

#define LAN9303_SWE_INGRSS_PORT_TYP_PORT2_EN   0x00000030

Definition at line 394 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR

#define LAN9303_SWE_PORT_MIRROR   0x1846

Definition at line 116 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR_MIRRORED

#define LAN9303_SWE_PORT_MIRROR_MIRRORED   0x0000001C

Definition at line 384 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR_MIRRORED_PORT0

#define LAN9303_SWE_PORT_MIRROR_MIRRORED_PORT0   0x00000004

Definition at line 385 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR_MIRRORED_PORT1

#define LAN9303_SWE_PORT_MIRROR_MIRRORED_PORT1   0x00000008

Definition at line 386 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR_MIRRORED_PORT2

#define LAN9303_SWE_PORT_MIRROR_MIRRORED_PORT2   0x00000010

Definition at line 387 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR_RX_MIRRORING_EN

#define LAN9303_SWE_PORT_MIRROR_RX_MIRRORING_EN   0x00000002

Definition at line 388 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR_RX_MIRRORING_FILT_EN

#define LAN9303_SWE_PORT_MIRROR_RX_MIRRORING_FILT_EN   0x00000100

Definition at line 379 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR_SNIFFER

#define LAN9303_SWE_PORT_MIRROR_SNIFFER   0x000000E0

Definition at line 380 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR_SNIFFER_PORT0

#define LAN9303_SWE_PORT_MIRROR_SNIFFER_PORT0   0x00000020

Definition at line 381 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR_SNIFFER_PORT1

#define LAN9303_SWE_PORT_MIRROR_SNIFFER_PORT1   0x00000040

Definition at line 382 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR_SNIFFER_PORT2

#define LAN9303_SWE_PORT_MIRROR_SNIFFER_PORT2   0x00000080

Definition at line 383 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_MIRROR_TX_MIRRORING_EN

#define LAN9303_SWE_PORT_MIRROR_TX_MIRRORING_EN   0x00000001

Definition at line 389 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE

#define LAN9303_SWE_PORT_STATE   0x1843

Definition at line 115 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT0

#define LAN9303_SWE_PORT_STATE_PORT0   0x00000003

Definition at line 372 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT0_DISABLED

#define LAN9303_SWE_PORT_STATE_PORT0_DISABLED   0x00000003

Definition at line 376 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT0_FORWARDING

#define LAN9303_SWE_PORT_STATE_PORT0_FORWARDING   0x00000000

Definition at line 373 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT0_LEARNING

#define LAN9303_SWE_PORT_STATE_PORT0_LEARNING   0x00000002

Definition at line 375 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT0_LISTENING

#define LAN9303_SWE_PORT_STATE_PORT0_LISTENING   0x00000001

Definition at line 374 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT1

#define LAN9303_SWE_PORT_STATE_PORT1   0x0000000C

Definition at line 367 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT1_DISABLED

#define LAN9303_SWE_PORT_STATE_PORT1_DISABLED   0x0000000C

Definition at line 371 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT1_FORWARDING

#define LAN9303_SWE_PORT_STATE_PORT1_FORWARDING   0x00000000

Definition at line 368 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT1_LEARNING

#define LAN9303_SWE_PORT_STATE_PORT1_LEARNING   0x00000008

Definition at line 370 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT1_LISTENING

#define LAN9303_SWE_PORT_STATE_PORT1_LISTENING   0x00000004

Definition at line 369 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT2

#define LAN9303_SWE_PORT_STATE_PORT2   0x00000030

Definition at line 362 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT2_DISABLED

#define LAN9303_SWE_PORT_STATE_PORT2_DISABLED   0x00000030

Definition at line 366 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT2_FORWARDING

#define LAN9303_SWE_PORT_STATE_PORT2_FORWARDING   0x00000000

Definition at line 363 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT2_LEARNING

#define LAN9303_SWE_PORT_STATE_PORT2_LEARNING   0x00000020

Definition at line 365 of file lan9303_driver.h.

◆ LAN9303_SWE_PORT_STATE_PORT2_LISTENING

#define LAN9303_SWE_PORT_STATE_PORT2_LISTENING   0x00000010

Definition at line 364 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_CMD

#define LAN9303_SWITCH_CSR_CMD   0x01B0

Definition at line 92 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_CMD_ADDR

#define LAN9303_SWITCH_CSR_CMD_ADDR   0x0000FFFF

Definition at line 259 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_CMD_AUTO_DEC

#define LAN9303_SWITCH_CSR_CMD_AUTO_DEC   0x10000000

Definition at line 253 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_CMD_AUTO_INC

#define LAN9303_SWITCH_CSR_CMD_AUTO_INC   0x20000000

Definition at line 252 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_CMD_BE

#define LAN9303_SWITCH_CSR_CMD_BE   0x000F0000

Definition at line 254 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_CMD_BE_0

#define LAN9303_SWITCH_CSR_CMD_BE_0   0x00010000

Definition at line 255 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_CMD_BE_1

#define LAN9303_SWITCH_CSR_CMD_BE_1   0x00020000

Definition at line 256 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_CMD_BE_2

#define LAN9303_SWITCH_CSR_CMD_BE_2   0x00040000

Definition at line 257 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_CMD_BE_3

#define LAN9303_SWITCH_CSR_CMD_BE_3   0x00080000

Definition at line 258 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_CMD_BUSY

#define LAN9303_SWITCH_CSR_CMD_BUSY   0x80000000

Definition at line 250 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_CMD_READ

#define LAN9303_SWITCH_CSR_CMD_READ   0x40000000

Definition at line 251 of file lan9303_driver.h.

◆ LAN9303_SWITCH_CSR_DATA

#define LAN9303_SWITCH_CSR_DATA   0x01AC

Definition at line 91 of file lan9303_driver.h.

◆ LAN9303_VID_ALR_LOOKUP

#define LAN9303_VID_ALR_LOOKUP   0x0008

Definition at line 59 of file lan9303_driver.h.

◆ LAN9303_VID_BROADCAST

#define LAN9303_VID_BROADCAST   0x0003

Definition at line 60 of file lan9303_driver.h.

◆ LAN9303_VID_CALC_PRIORITY

#define LAN9303_VID_CALC_PRIORITY   0x0020

Definition at line 57 of file lan9303_driver.h.

◆ LAN9303_VID_DEST_PORT0

#define LAN9303_VID_DEST_PORT0   0x0000

Definition at line 63 of file lan9303_driver.h.

◆ LAN9303_VID_DEST_PORT1

#define LAN9303_VID_DEST_PORT1   0x0001

Definition at line 62 of file lan9303_driver.h.

◆ LAN9303_VID_DEST_PORT2

#define LAN9303_VID_DEST_PORT2   0x0002

Definition at line 61 of file lan9303_driver.h.

◆ LAN9303_VID_IGMP_PACKET

#define LAN9303_VID_IGMP_PACKET   0x0008

Definition at line 70 of file lan9303_driver.h.

◆ LAN9303_VID_PRIORITY

#define LAN9303_VID_PRIORITY   0x0380

Definition at line 66 of file lan9303_driver.h.

◆ LAN9303_VID_PRIORITY_EN

#define LAN9303_VID_PRIORITY_EN   0x0040

Definition at line 67 of file lan9303_driver.h.

◆ LAN9303_VID_SRC_PORT

#define LAN9303_VID_SRC_PORT   0x0003

Definition at line 71 of file lan9303_driver.h.

◆ LAN9303_VID_STATIC

#define LAN9303_VID_STATIC   0x0020

Definition at line 68 of file lan9303_driver.h.

◆ LAN9303_VID_STP_OVERRIDE [1/2]

#define LAN9303_VID_STP_OVERRIDE   0x0010

Definition at line 69 of file lan9303_driver.h.

◆ LAN9303_VID_STP_OVERRIDE [2/2]

#define LAN9303_VID_STP_OVERRIDE   0x0010

Definition at line 69 of file lan9303_driver.h.

◆ LAN9303_VID_VLAN_RULES

#define LAN9303_VID_VLAN_RULES   0x0040

Definition at line 56 of file lan9303_driver.h.

Function Documentation

◆ lan9303AddStaticFdbEntry()

error_t lan9303AddStaticFdbEntry ( NetInterface interface,
const SwitchFdbEntry entry 
)

Add a new entry to the static MAC table.

Parameters
[in]interfaceUnderlying network interface
[in]entryPointer to the forwarding database entry
Returns
Error code

Definition at line 894 of file lan9303_driver.c.

◆ lan9303DeleteStaticFdbEntry()

error_t lan9303DeleteStaticFdbEntry ( NetInterface interface,
const SwitchFdbEntry entry 
)

Remove an entry from the static MAC table.

Parameters
[in]interfaceUnderlying network interface
[in]entryForwarding database entry to remove from the table
Returns
Error code

Definition at line 999 of file lan9303_driver.c.

◆ lan9303DisableIrq()

void lan9303DisableIrq ( NetInterface interface)

Disable interrupts.

Parameters
[in]interfaceUnderlying network interface

Definition at line 271 of file lan9303_driver.c.

◆ lan9303DumpPhyReg()

void lan9303DumpPhyReg ( NetInterface interface,
uint8_t  port 
)

Dump PHY registers for debugging purpose.

Parameters
[in]interfaceUnderlying network interface
[in]portPort number

Definition at line 1406 of file lan9303_driver.c.

◆ lan9303DumpSysReg()

void lan9303DumpSysReg ( NetInterface interface)

Dump system CSR registers for debugging purpose.

Parameters
[in]interfaceUnderlying network interface

Definition at line 1519 of file lan9303_driver.c.

◆ lan9303EnableIrq()

void lan9303EnableIrq ( NetInterface interface)

Enable interrupts.

Parameters
[in]interfaceUnderlying network interface

Definition at line 261 of file lan9303_driver.c.

◆ lan9303EnableRsvdMcastTable()

void lan9303EnableRsvdMcastTable ( NetInterface interface,
bool_t  enable 
)

Enable reserved multicast table.

Parameters
[in]interfaceUnderlying network interface
[in]enableEnable or disable reserved group addresses

Definition at line 852 of file lan9303_driver.c.

◆ lan9303EventHandler()

void lan9303EventHandler ( NetInterface interface)

LAN9303 event handler.

Parameters
[in]interfaceUnderlying network interface

Definition at line 281 of file lan9303_driver.c.

◆ lan9303FlushDynamicFdbTable()

void lan9303FlushDynamicFdbTable ( NetInterface interface,
uint8_t  port 
)

Flush dynamic MAC table.

Parameters
[in]interfaceUnderlying network interface
[in]portPort number

Definition at line 1291 of file lan9303_driver.c.

◆ lan9303FlushStaticFdbTable()

void lan9303FlushStaticFdbTable ( NetInterface interface)

Flush static MAC table.

Parameters
[in]interfaceUnderlying network interface

Definition at line 1158 of file lan9303_driver.c.

◆ lan9303GetDuplexMode()

NicDuplexMode lan9303GetDuplexMode ( NetInterface interface,
uint8_t  port 
)

Get duplex mode.

Parameters
[in]interfaceUnderlying network interface
[in]portPort number
Returns
Duplex mode

Definition at line 655 of file lan9303_driver.c.

◆ lan9303GetDynamicFdbEntry()

error_t lan9303GetDynamicFdbEntry ( NetInterface interface,
uint_t  index,
SwitchFdbEntry entry 
)

Read an entry from the dynamic MAC table.

Parameters
[in]interfaceUnderlying network interface
[in]indexZero-based index of the entry to read
[out]entryPointer to the forwarding database entry
Returns
Error code

Definition at line 1193 of file lan9303_driver.c.

◆ lan9303GetLinkSpeed()

uint32_t lan9303GetLinkSpeed ( NetInterface interface,
uint8_t  port 
)

Get link speed.

Parameters
[in]interfaceUnderlying network interface
[in]portPort number
Returns
Link speed

Definition at line 605 of file lan9303_driver.c.

◆ lan9303GetLinkState()

bool_t lan9303GetLinkState ( NetInterface interface,
uint8_t  port 
)

Get link state.

Parameters
[in]interfaceUnderlying network interface
[in]portPort number
Returns
Link state

Definition at line 573 of file lan9303_driver.c.

◆ lan9303GetPortState()

SwitchPortState lan9303GetPortState ( NetInterface interface,
uint8_t  port 
)

Get port state.

Parameters
[in]interfaceUnderlying network interface
[in]portPort number
Returns
Port state

Definition at line 776 of file lan9303_driver.c.

◆ lan9303GetStaticFdbEntry()

error_t lan9303GetStaticFdbEntry ( NetInterface interface,
uint_t  index,
SwitchFdbEntry entry 
)

Read an entry from the static MAC table.

Parameters
[in]interfaceUnderlying network interface
[in]indexZero-based index of the entry to read
[out]entryPointer to the forwarding database entry
Returns
Error code

Definition at line 1049 of file lan9303_driver.c.

◆ lan9303Init()

error_t lan9303Init ( NetInterface interface)

LAN9303 Ethernet switch initialization.

Parameters
[in]interfaceUnderlying network interface
Returns
Error code

Definition at line 75 of file lan9303_driver.c.

◆ lan9303ReadPhyReg()

uint16_t lan9303ReadPhyReg ( NetInterface interface,
uint8_t  port,
uint8_t  address 
)

Read PHY register.

Parameters
[in]interfaceUnderlying network interface
[in]portPort number
[in]addressPHY register address
Returns
Register value

Definition at line 1380 of file lan9303_driver.c.

◆ lan9303ReadSwitchReg()

uint32_t lan9303ReadSwitchReg ( NetInterface interface,
uint16_t  address 
)

Read switch fabric CSR register.

Parameters
[in]interfaceUnderlying network interface
[in]addressSwitch fabric register address
Returns
Register value

Definition at line 1580 of file lan9303_driver.c.

◆ lan9303ReadSysReg()

uint32_t lan9303ReadSysReg ( NetInterface interface,
uint16_t  address 
)

Read system CSR register.

Parameters
[in]interfaceUnderlying network interface
[in]addressSystem register address
Returns
Register value

Definition at line 1474 of file lan9303_driver.c.

◆ lan9303SetAgingTime()

void lan9303SetAgingTime ( NetInterface interface,
uint32_t  agingTime 
)

Set aging time for dynamic filtering entries.

Parameters
[in]interfaceUnderlying network interface
[in]agingTimeAging time, in seconds

Definition at line 840 of file lan9303_driver.c.

◆ lan9303SetPortState()

void lan9303SetPortState ( NetInterface interface,
uint8_t  port,
SwitchPortState  state 
)

Set port state.

Parameters
[in]interfaceUnderlying network interface
[in]portPort number
[in]statePort state
Returns
Duplex mode

Definition at line 706 of file lan9303_driver.c.

◆ lan9303TagFrame()

error_t lan9303TagFrame ( NetInterface interface,
NetBuffer buffer,
size_t *  offset,
NetTxAncillary ancillary 
)

Add special VLAN tag to Ethernet frame.

Parameters
[in]interfaceUnderlying network interface
[in]bufferMulti-part buffer containing the payload
[in,out]offsetOffset to the first payload byte
[in]ancillaryAdditional options passed to the stack along with the packet
Returns
Error code

Definition at line 427 of file lan9303_driver.c.

◆ lan9303Tick()

void lan9303Tick ( NetInterface interface)

LAN9303 timer handler.

Parameters
[in]interfaceUnderlying network interface

Definition at line 191 of file lan9303_driver.c.

◆ lan9303UntagFrame()

error_t lan9303UntagFrame ( NetInterface interface,
uint8_t **  frame,
size_t *  length,
NetRxAncillary ancillary 
)

Decode special VLAN tag from incoming Ethernet frame.

Parameters
[in]interfaceUnderlying network interface
[in,out]framePointer to the received Ethernet frame
[in,out]lengthLength of the frame, in bytes
[in,out]ancillaryAdditional options passed to the stack along with the packet
Returns
Error code

Definition at line 505 of file lan9303_driver.c.

◆ lan9303WritePhyReg()

void lan9303WritePhyReg ( NetInterface interface,
uint8_t  port,
uint8_t  address,
uint16_t  data 
)

Write PHY register.

Parameters
[in]interfaceUnderlying network interface
[in]portPort number
[in]addressPHY register address
[in]dataRegister value

Definition at line 1357 of file lan9303_driver.c.

◆ lan9303WriteSwitchReg()

void lan9303WriteSwitchReg ( NetInterface interface,
uint16_t  address,
uint32_t  data 
)

Write switch fabric CSR register.

Parameters
[in]interfaceUnderlying network interface
[in]addressSwitch fabric register address
[in]dataRegister value

Definition at line 1543 of file lan9303_driver.c.

◆ lan9303WriteSysReg()

void lan9303WriteSysReg ( NetInterface interface,
uint16_t  address,
uint32_t  data 
)

Write system CSR register.

Parameters
[in]interfaceUnderlying network interface
[in]addressSystem register address
[in]dataRegister value

Definition at line 1430 of file lan9303_driver.c.

Variable Documentation

◆ lan9303SwitchDriver

const SwitchDriver lan9303SwitchDriver

LAN9303 Ethernet switch driver.

Definition at line 44 of file lan9303_driver.c.