Go to the documentation of this file.
49 #define DRIVER_NAME "et131x"
50 #define DRIVER_VERSION "v2.0"
55 #define LBCIF_DWORD0_GROUP 0xAC
56 #define LBCIF_DWORD1_GROUP 0xB0
59 #define LBCIF_ADDRESS_REGISTER 0xAC
60 #define LBCIF_DATA_REGISTER 0xB0
61 #define LBCIF_CONTROL_REGISTER 0xB1
62 #define LBCIF_STATUS_REGISTER 0xB2
65 #define LBCIF_CONTROL_SEQUENTIAL_READ 0x01
66 #define LBCIF_CONTROL_PAGE_WRITE 0x02
67 #define LBCIF_CONTROL_EEPROM_RELOAD 0x08
68 #define LBCIF_CONTROL_TWO_BYTE_ADDR 0x20
69 #define LBCIF_CONTROL_I2C_WRITE 0x40
70 #define LBCIF_CONTROL_LBCIF_ENABLE 0x80
73 #define LBCIF_STATUS_PHY_QUEUE_AVAIL 0x01
74 #define LBCIF_STATUS_I2C_IDLE 0x02
75 #define LBCIF_STATUS_ACK_ERROR 0x04
76 #define LBCIF_STATUS_GENERAL_ERROR 0x08
77 #define LBCIF_STATUS_CHECKSUM_ERROR 0x40
78 #define LBCIF_STATUS_EEPROM_PRESENT 0x80
106 #define ET_PM_PHY_SW_COMA 0x40
107 #define ET_PMCSR_INIT 0x38
113 #define ET_INTR_TXDMA_ISR 0x00000008
114 #define ET_INTR_TXDMA_ERR 0x00000010
115 #define ET_INTR_RXDMA_XFR_DONE 0x00000020
116 #define ET_INTR_RXDMA_FB_R0_LOW 0x00000040
117 #define ET_INTR_RXDMA_FB_R1_LOW 0x00000080
118 #define ET_INTR_RXDMA_STAT_LOW 0x00000100
119 #define ET_INTR_RXDMA_ERR 0x00000200
120 #define ET_INTR_WATCHDOG 0x00004000
121 #define ET_INTR_WOL 0x00008000
122 #define ET_INTR_PHY 0x00010000
123 #define ET_INTR_TXMAC 0x00020000
124 #define ET_INTR_RXMAC 0x00040000
125 #define ET_INTR_MAC_STAT 0x00080000
126 #define ET_INTR_SLV_TIMEOUT 0x00100000
156 #define ET_MSI_VECTOR 0x0000001F
157 #define ET_MSI_TC 0x00070000
163 #define ET_LOOP_MAC 0x00000001
164 #define ET_LOOP_DMA 0x00000002
195 #define ET_TXDMA_CSR_HALT 0x00000001
196 #define ET_TXDMA_DROP_TLP 0x00000002
197 #define ET_TXDMA_CACHE_THRS 0x000000F0
198 #define ET_TXDMA_CACHE_SHIFT 4
199 #define ET_TXDMA_SNGL_EPKT 0x00000100
200 #define ET_TXDMA_CLASS 0x00001E00
222 #define ET_DMA12_MASK 0x0FFF
223 #define ET_DMA12_WRAP 0x1000
224 #define ET_DMA10_MASK 0x03FF
225 #define ET_DMA10_WRAP 0x0400
226 #define ET_DMA4_MASK 0x000F
227 #define ET_DMA4_WRAP 0x0010
229 #define INDEX12(x) ((x) & ET_DMA12_MASK)
230 #define INDEX10(x) ((x) & ET_DMA10_MASK)
231 #define INDEX4(x) ((x) & ET_DMA4_MASK)
718 #define ET_WOL_LO_SA3_SHIFT 24
719 #define ET_WOL_LO_SA4_SHIFT 16
720 #define ET_WOL_LO_SA5_SHIFT 8
731 #define ET_WOL_HI_SA1_SHIFT 8
749 #define ET_UNI_PF_ADDR1_3_SHIFT 24
750 #define ET_UNI_PF_ADDR1_4_SHIFT 16
751 #define ET_UNI_PF_ADDR1_5_SHIFT 8
763 #define ET_UNI_PF_ADDR2_3_SHIFT 24
764 #define ET_UNI_PF_ADDR2_4_SHIFT 16
765 #define ET_UNI_PF_ADDR2_5_SHIFT 8
777 #define ET_UNI_PF_ADDR2_1_SHIFT 24
778 #define ET_UNI_PF_ADDR2_2_SHIFT 16
779 #define ET_UNI_PF_ADDR1_1_SHIFT 8
935 #define CFG1_LOOPBACK 0x00000100
936 #define CFG1_RX_FLOW 0x00000020
937 #define CFG1_TX_FLOW 0x00000010
938 #define CFG1_RX_ENABLE 0x00000004
939 #define CFG1_TX_ENABLE 0x00000001
940 #define CFG1_WAIT 0x0000000A
1028 #define MII_ADDR(phy, reg) ((phy) << 8 | (reg))
1053 #define MGMT_BUSY 0x00000001
1054 #define MGMT_WAIT 0x00000005
1106 #define ET_MAC_STATION_ADDR1_OC6_SHIFT 24
1107 #define ET_MAC_STATION_ADDR1_OC5_SHIFT 16
1108 #define ET_MAC_STATION_ADDR1_OC4_SHIFT 8
1119 #define ET_MAC_STATION_ADDR2_OC2_SHIFT 24
1120 #define ET_MAC_STATION_ADDR2_OC1_SHIFT 16
1368 #define ET_MMC_ENABLE 1
1369 #define ET_MMC_ARB_DISABLE 2
1370 #define ET_MMC_RXMAC_DISABLE 4
1371 #define ET_MMC_TXMAC_DISABLE 8
1372 #define ET_MMC_TXDMA_DISABLE 16
1373 #define ET_MMC_RXDMA_DISABLE 32
1374 #define ET_MMC_FORCE_CE 64
1381 #define ET_SRAM_REQ_ACCESS 1
1382 #define ET_SRAM_WR_ACCESS 2
1383 #define ET_SRAM_IS_CTRL 4
1447 #define PHY_INDEX_REG 0x10
1448 #define PHY_DATA_REG 0x11
1449 #define PHY_MPHY_CONTROL_REG 0x12
1452 #define PHY_LOOPBACK_CONTROL 0x13
1454 #define PHY_REGISTER_MGMT_CONTROL 0x15
1455 #define PHY_CONFIG 0x16
1456 #define PHY_PHY_CONTROL 0x17
1457 #define PHY_INTERRUPT_MASK 0x18
1458 #define PHY_INTERRUPT_STATUS 0x19
1459 #define PHY_PHY_STATUS 0x1A
1460 #define PHY_LED_1 0x1B
1461 #define PHY_LED_2 0x1C
1466 #define ET_1000BT_MSTR_SLV 0x4000
1506 #define ET_PHY_CONFIG_TX_FIFO_DEPTH 0x3000
1508 #define ET_PHY_CONFIG_FIFO_DEPTH_8 0x0000
1509 #define ET_PHY_CONFIG_FIFO_DEPTH_16 0x1000
1510 #define ET_PHY_CONFIG_FIFO_DEPTH_32 0x2000
1511 #define ET_PHY_CONFIG_FIFO_DEPTH_64 0x3000
1541 #define ET_PHY_INT_MASK_AUTONEGSTAT 0x0100
1542 #define ET_PHY_INT_MASK_LINKSTAT 0x0004
1543 #define ET_PHY_INT_MASK_ENABLE 0x0001
1575 #define ET_PHY_AUTONEG_STATUS 0x1000
1576 #define ET_PHY_POLARITY_STATUS 0x0400
1577 #define ET_PHY_SPEED_STATUS 0x0300
1578 #define ET_PHY_DUPLEX_STATUS 0x0080
1579 #define ET_PHY_LSTATUS 0x0040
1580 #define ET_PHY_AUTONEG_ENABLE 0x0020
1599 #define ET_LED2_LED_LINK 0xF000
1600 #define ET_LED2_LED_TXRX 0x0F00
1601 #define ET_LED2_LED_100TX 0x00F0
1602 #define ET_LED2_LED_1000T 0x000F
1605 #define LED_VAL_1000BT 0x0
1606 #define LED_VAL_100BTX 0x1
1607 #define LED_VAL_10BT 0x2
1608 #define LED_VAL_1000BT_100BTX 0x3
1609 #define LED_VAL_LINKON 0x4
1610 #define LED_VAL_TX 0x5
1611 #define LED_VAL_RX 0x6
1612 #define LED_VAL_TXRX 0x7
1613 #define LED_VAL_DUPLEXFULL 0x8
1614 #define LED_VAL_COLLISION 0x9
1615 #define LED_VAL_LINKON_ACTIVE 0xA
1616 #define LED_VAL_LINKON_RECV 0xB
1617 #define LED_VAL_DUPLEXFULL_COLLISION 0xC
1618 #define LED_VAL_BLINK 0xD
1619 #define LED_VAL_ON 0xE
1620 #define LED_VAL_OFF 0xF
1622 #define LED_LINK_SHIFT 12
1623 #define LED_TXRX_SHIFT 8
1624 #define LED_100TX_SHIFT 4
1631 #define TRUEPHY_BIT_CLEAR 0
1632 #define TRUEPHY_BIT_SET 1
1633 #define TRUEPHY_BIT_READ 2
1636 #ifndef TRUEPHY_READ
1637 #define TRUEPHY_READ 0
1638 #define TRUEPHY_WRITE 1
1639 #define TRUEPHY_MASK 2
1643 #define TRUEPHY_CFG_SLAVE 0
1644 #define TRUEPHY_CFG_MASTER 1
1647 #define TRUEPHY_MDI 0
1648 #define TRUEPHY_MDIX 1
1649 #define TRUEPHY_AUTO_MDI_MDIX 2
1652 #define TRUEPHY_POLARITY_NORMAL 0
1653 #define TRUEPHY_POLARITY_INVERTED 1
1656 #define TRUEPHY_ANEG_NOT_COMPLETE 0
1657 #define TRUEPHY_ANEG_COMPLETE 1
1658 #define TRUEPHY_ANEG_DISABLED 2
1661 #define TRUEPHY_ADV_DUPLEX_NONE 0x00
1662 #define TRUEPHY_ADV_DUPLEX_FULL 0x01
1663 #define TRUEPHY_ADV_DUPLEX_HALF 0x02
1664 #define TRUEPHY_ADV_DUPLEX_BOTH \
1665 (TRUEPHY_ADV_DUPLEX_FULL | TRUEPHY_ADV_DUPLEX_HALF)