Lines Matching defs:tg3
1 /* $Id: tg3.c,v 1.5 2003/03/19 21:26:20 gbaum Exp $
2 * tg3.c: Broadcom Tigon3 ethernet driver.
18 #include "tg3.h"
26 struct tg3 tg3;
100 pci_write_config_dword(tg3.pdev, TG3PCI_REG_BASE_ADDR, off);
101 pci_write_config_dword(tg3.pdev, TG3PCI_REG_DATA, val);
105 #define tw32_mailbox(reg, val) writel(((val) & 0xffffffff), tg3.regs + (reg))
106 #define tw16(reg,val) writew(((val) & 0xffff), tg3.regs + (reg))
107 #define tw8(reg,val) writeb(((val) & 0xff), tg3.regs + (reg))
108 #define tr32(reg) readl(tg3.regs + (reg))
109 #define tr16(reg) readw(tg3.regs + (reg))
110 #define tr8(reg) readb(tg3.regs + (reg))
127 pci_write_config_dword(tg3.pdev, TG3PCI_MEM_WIN_BASE_ADDR, off);
128 pci_write_config_dword(tg3.pdev, TG3PCI_MEM_WIN_DATA, val);
131 pci_write_config_dword(tg3.pdev, TG3PCI_MEM_WIN_BASE_ADDR, 0);
136 pci_write_config_dword(tg3.pdev, TG3PCI_MEM_WIN_BASE_ADDR, off);
137 pci_read_config_dword(tg3.pdev, TG3PCI_MEM_WIN_DATA, val);
140 pci_write_config_dword(tg3.pdev, TG3PCI_MEM_WIN_BASE_ADDR, 0);
143 static void tg3_disable_ints(struct tg3 *tp)
150 static void tg3_switch_clocks(struct tg3 *tp)
172 static int tg3_readphy(struct tg3 *tp, int reg, uint32_t *val)
212 static int tg3_writephy(struct tg3 *tp, int reg, uint32_t val)
248 static int tg3_writedsp(struct tg3 *tp, uint16_t addr, uint16_t val)
257 static void tg3_phy_set_wirespeed(struct tg3 *tp)
269 static int tg3_bmcr_reset(struct tg3 *tp)
300 static int tg3_wait_macro_done(struct tg3 *tp)
317 static int tg3_phy_write_and_check_testpat(struct tg3 *tp, int *resetp)
383 static int tg3_phy_reset_chanpat(struct tg3 *tp)
403 static int tg3_phy_reset_5703_4_5(struct tg3 *tp)
469 static int tg3_phy_reset(struct tg3 *tp)
495 static void tg3_set_power_state_0(struct tg3 *tp)
519 static void tg3_link_report(struct tg3 *tp)
540 static void tg3_setup_flow_control(struct tg3 *tp, uint32_t local_adv, uint32_t remote_adv)
581 struct tg3 *tp __unused, uint32_t val, uint8_t *speed, uint8_t *duplex)
599 static int tg3_phy_copper_begin(struct tg3 *tp)
654 static int tg3_init_5401phy_dsp(struct tg3 *tp)
672 static int tg3_setup_copper_phy(struct tg3 *tp)
952 static int tg3_fiber_aneg_smachine(struct tg3 *tp,
1196 static int tg3_setup_fiber_phy(struct tg3 *tp)
1381 static int tg3_setup_phy(struct tg3 *tp)
1412 static int tg3_stop_block(struct tg3 *tp, unsigned long ofs, uint32_t enable_bit)
1453 static int tg3_abort_hw(struct tg3 *tp)
1513 static void tg3_chip_reset(struct tg3 *tp)
1582 static void tg3_stop_fw(struct tg3 *tp)
1602 static int tg3_restart_fw(struct tg3 *tp, uint32_t state)
1629 static int tg3_halt(struct tg3 *tp)
1637 static void __tg3_set_mac_addr(struct tg3 *tp)
1671 static void tg3_set_bdinfo(struct tg3 *tp, uint32_t bdinfo_addr,
1690 static void tg3_init_rings(struct tg3 *tp)
1694 /* Zero out the tg3 variables */
1741 /* initialize/reset the tg3 */
1742 static int tg3_setup_hw(struct tg3 *tp)
2214 static void tg3_nvram_init(struct tg3 *tp)
2247 struct tg3 *tp __unused, uint32_t offset, uint32_t *val)
2282 static int tg3_nvram_read(struct tg3 *tp, uint32_t offset, uint32_t *val)
2374 static int tg3_phy_probe(struct tg3 *tp)
2556 static void tg3_read_partno(struct tg3 *tp)
2620 static int tg3_get_invariants(struct tg3 *tp)
2714 /* Etherboot does not ask the tg3 to do checksums */
2715 /* Etherboot does not ask the tg3 to do jumbo frames */
2716 /* Ehterboot does not ask the tg3 to use WakeOnLan. */
2811 static int tg3_get_device_address(struct tg3 *tp)
2860 static int tg3_setup_dma(struct tg3 *tp)
2913 static void tg3_init_link_config(struct tg3 *tp)
2927 static const char * tg3_phy_string(struct tg3 *tp)
2946 static void tg3_poll_link(struct tg3 *tp)
2971 static void tg3_ack_irqs(struct tg3 *tp)
2998 struct tg3 *tp = &tg3;
3038 static void tg3_set_txd(struct tg3 *tp, int entry,
3068 struct tg3 *tp;
3073 tp = &tg3;
3120 struct tg3 *tp = &tg3;
3159 struct tg3 *tp = &tg3;
3288 PCI_ROM(0x14e4, 0x1644, "tg3-5700", "Broadcom Tigon 3 5700"),
3289 PCI_ROM(0x14e4, 0x1645, "tg3-5701", "Broadcom Tigon 3 5701"),
3290 PCI_ROM(0x14e4, 0x1646, "tg3-5702", "Broadcom Tigon 3 5702"),
3291 PCI_ROM(0x14e4, 0x1647, "tg3-5703", "Broadcom Tigon 3 5703"),
3292 PCI_ROM(0x14e4, 0x1648, "tg3-5704", "Broadcom Tigon 3 5704"),
3293 PCI_ROM(0x14e4, 0x164d, "tg3-5702FE", "Broadcom Tigon 3 5702FE"),
3294 PCI_ROM(0x14e4, 0x1653, "tg3-5705", "Broadcom Tigon 3 5705"),
3295 PCI_ROM(0x14e4, 0x1654, "tg3-5705_2", "Broadcom Tigon 3 5705_2"),
3296 PCI_ROM(0x14e4, 0x165d, "tg3-5705M", "Broadcom Tigon 3 5705M"),
3297 PCI_ROM(0x14e4, 0x165e, "tg3-5705M_2", "Broadcom Tigon 3 5705M_2"),
3298 PCI_ROM(0x14e4, 0x1696, "tg3-5782", "Broadcom Tigon 3 5782"),
3299 PCI_ROM(0x14e4, 0x169c, "tg3-5788", "Broadcom Tigon 3 5788"),
3300 PCI_ROM(0x14e4, 0x16a6, "tg3-5702X", "Broadcom Tigon 3 5702X"),
3301 PCI_ROM(0x14e4, 0x16a7, "tg3-5703X", "Broadcom Tigon 3 5703X"),
3302 PCI_ROM(0x14e4, 0x16a8, "tg3-5704S", "Broadcom Tigon 3 5704S"),
3303 PCI_ROM(0x14e4, 0x16c6, "tg3-5702A3", "Broadcom Tigon 3 5702A3"),
3304 PCI_ROM(0x14e4, 0x16c7, "tg3-5703A3", "Broadcom Tigon 3 5703A3"),
3305 PCI_ROM(0x14e4, 0x170d, "tg3-5901", "Broadcom Tigon 3 5901"),
3306 PCI_ROM(0x14e4, 0x170e, "tg3-5901_2", "Broadcom Tigon 3 5901_2"),
3307 PCI_ROM(0x1148, 0x4400, "tg3-9DXX", "Syskonnect 9DXX"),
3308 PCI_ROM(0x1148, 0x4500, "tg3-9MXX", "Syskonnect 9MXX"),
3309 PCI_ROM(0x173b, 0x03e8, "tg3-ac1000", "Altima AC1000"),
3310 PCI_ROM(0x173b, 0x03e9, "tg3-ac1001", "Altima AC1001"),
3311 PCI_ROM(0x173b, 0x03ea, "tg3-ac9100", "Altima AC9100"),
3312 PCI_ROM(0x173b, 0x03eb, "tg3-ac1003", "Altima AC1003"),