|
iPXE
|
Go to the source code of this file.
Data Structures | |
| struct | w840_rx_desc |
| struct | w840_tx_desc |
| struct | winbond_private |
| struct | w89c840_bss |
Macros | |
| #define | USE_IO_OPS |
| #define | virt_to_le32desc(addr) |
| #define | le32desc_to_virt(addr) |
| #define | TX_RING_SIZE 2 |
| #define | RX_RING_SIZE 2 |
| #define | TX_FIFO_SIZE (2048) |
| #define | TX_BUG_FIFO_LIMIT (TX_FIFO_SIZE-1514-16) |
| #define | TX_TIMEOUT (10*1000) |
| #define | PKT_BUF_SZ 1536 /* Size of each temporary Rx buffer.*/ |
| #define | W840_FLAGS (PCI_USES_IO | PCI_ADDR0 | PCI_USES_MASTER) |
| #define | readb inb |
| #define | readw inw |
| #define | readl inl |
| #define | writeb outb |
| #define | writew outw |
| #define | writel outl |
| #define | PRIV_ALIGN 15 /* Required alignment mask */ |
| #define | PRIV_ALIGN_BYTES 32 |
| #define | w89c840_buf NIC_FAKE_BSS ( struct w89c840_bss ) |
| #define | PCI_VENDOR_ID_WINBOND2 0x1050 |
| #define | PCI_DEVICE_ID_WINBOND2_89C840 0x0840 |
| #define | PCI_VENDOR_ID_COMPEX 0x11f6 |
| #define | PCI_DEVICE_ID_COMPEX_RL100ATX 0x2011 |
| #define | eeprom_delay(ee_addr) |
| #define | mdio_delay(mdio_addr) |
| #define | MDIO_WRITE0 (MDIO_EnbOutput) |
| #define | MDIO_WRITE1 (MDIO_DataOut | MDIO_EnbOutput) |
Functions | |
| FILE_LICENCE (GPL2_OR_LATER) | |
| static int | eeprom_read (long ioaddr, int location) |
| static int | mdio_read (int base_address, int phy_id, int location) |
| static void | check_duplex (void) |
| static void | set_rx_mode (void) |
| static void | init_ring (void) |
| static void | w89c840_reset (struct nic *nic) |
| static int | w89c840_poll (struct nic *nic, int retrieve) |
| static void | w89c840_transmit (struct nic *nic, const char *d, unsigned int t, unsigned int s, const char *p) |
| static void | w89c840_disable (struct nic *nic, void *hwdev __unused) |
| static void | w89c840_irq (struct nic *nic __unused, irq_action_t action __unused) |
| PCI_DRIVER (w89c840_driver, w89c840_nics, PCI_NO_CLASS) | |
| static int | w89c840_probe (struct nic *nic, struct pci_device *p) |
| static void | mdio_sync (long mdio_addr) |
| DRIVER ("W89C840F", nic_driver, pci_driver, w89c840_driver, w89c840_probe, w89c840_disable, w89c840_buf) | |
Variables | |
| static const char * | w89c840_version = "driver Version 0.94 - December 12, 2003" |
| static u32 | driver_flags = CanHaveMII | HasBrokenTx |
| static struct winbond_private | w840private |
| static int | ioaddr |
| static unsigned short | eeprom [0x40] |
| static struct nic_operations | w89c840_operations |
| static struct pci_device_id | w89c840_nics [] |
| static char | mii_preamble_required = 1 |
| #define virt_to_le32desc | ( | addr | ) |
Definition at line 91 of file w89c840.c.
Referenced by init_ring(), and w89c840_transmit().
| #define le32desc_to_virt | ( | addr | ) |
| #define TX_BUG_FIFO_LIMIT (TX_FIFO_SIZE-1514-16) |
Definition at line 114 of file w89c840.c.
Referenced by w89c840_transmit().
| #define PKT_BUF_SZ 1536 /* Size of each temporary Rx buffer.*/ |
| #define W840_FLAGS (PCI_USES_IO | PCI_ADDR0 | PCI_USES_MASTER) |
| #define readb inb |
Definition at line 155 of file w89c840.c.
Referenced by amd8111e_get_mac_address(), ecam_read(), ehci_dump(), ehci_init(), icplus_check_link(), icplus_mii_read_bit(), icplus_mii_write_bit(), PROVIDE_IOAPI_INLINE(), realtek_check_link(), realtek_dump(), realtek_init_eeprom(), realtek_legacy_poll_rx(), realtek_probe(), realtek_reset(), realtek_spi_close_bit(), realtek_spi_open_bit(), realtek_spi_read_bit(), realtek_spi_write_bit(), rhine_check_link(), rhine_mii_autopoll(), rhine_mii_read(), rhine_mii_write(), rhine_poll(), rhine_probe(), skge_read8(), sky2_read8(), velocity_autopoll_start(), velocity_autopoll_stop(), velocity_check_link(), velocity_mii_read(), velocity_mii_write(), velocity_open(), velocity_poll(), velocity_probe(), velocity_reload_eeprom(), velocity_reset(), vpm_ioread8(), X86_READX(), xenstore_recv(), xhci_init(), xhci_legacy_claim(), and xhci_legacy_init().
| #define readw inw |
Definition at line 156 of file w89c840.c.
Referenced by assert(), b44_read_eeprom(), ecam_read(), ehci_dump(), hfa384x_getreg(), icplus_poll(), icplus_read_eeprom(), PROVIDE_IOAPI_INLINE(), rdc_mii_read(), rdc_mii_write(), rdc_poll(), rdc_probe(), rdc_reset(), realtek_detect(), realtek_legacy_poll_rx(), realtek_poll(), rhine_mii_read(), skge_read16(), sky2_read16(), velocity_mii_read(), vpm_ioread16(), X86_READX(), and xengrant_alloc().
| #define readl inl |
Definition at line 157 of file w89c840.c.
Referenced by __er32(), _efx_readl(), amd8111e_disable_interrupt(), amd8111e_enable_interrupt(), amd8111e_force_interrupt(), amd8111e_init_hw_default(), amd8111e_poll(), amd8111e_poll_link(), amd8111e_read_phy(), amd8111e_start(), amd8111e_transmit(), amd8111e_wait_link(), arbel_cmd(), arbel_cmd_wait(), ath5k_hw_reg_read(), ath9k_ioread32(), ath9k_reg_rmw(), bflush(), bnxt_er_get_reg_val(), bnxt_er_reg_read(), br32(), cgem_mii_read(), cgem_mii_wait(), cgem_probe(), cmdif_rev(), dwgpio_config(), dwgpio_dump(), dwgpio_in(), dwgpio_out(), dwgpio_probe(), dwmac_check_link(), dwmac_dump_dma(), dwmac_dump_mac(), dwmac_poll(), dwmac_probe(), dwmac_reset(), dwusb_probe(), ecam_read(), eeprom_read(), ehci_async_del(), ehci_bus_poll(), ehci_dump(), ehci_init(), ehci_reset(), ehci_root_disable(), ehci_root_enable(), ehci_root_open(), ehci_root_poll(), ehci_root_speed(), ehci_run(), ehci_stop(), ena_reset_wait(), exanic_check_link(), exanic_i2c_read_bit(), exanic_i2c_write_bit(), exanic_probe(), exanic_probe_port(), forcedeth_link_status(), forcedeth_open(), forcedeth_poll(), fw_rev_maj(), fw_rev_min(), fw_rev_sub(), golan_cmd_init(), gve_admin_wait(), gve_reset(), gve_watchdog(), hermon_cmd(), hermon_cmd_wait(), hvm_map_shared_info(), ice_dump_rx(), ice_dump_tx(), ice_probe(), icplus_init_phy(), icplus_poll(), icplus_reset(), intel_check_link(), intel_create_ring(), intel_diag(), intel_disable_ring(), intel_fetch_mac(), intel_init_eeprom(), intel_open(), intel_poll(), intel_read_eeprom(), intel_reset(), intelvf_mbox_msg(), intelvf_mbox_poll(), intelvf_mbox_read(), intelx_check_link(), intelx_close(), intelx_open(), intelx_poll(), intelx_reset(), intelx_try_fetch_mac(), intelxl_context_dump(), intelxl_context_line(), intelxl_disable_ring(), intelxl_enable_ring(), intelxl_probe(), intelxlvf_reset_wait_active(), intelxlvf_reset_wait_teardown(), intelxvf_check_link(), intelxvf_open(), intelxvf_poll(), intelxvf_stats(), jread32(), jwrite32f(), mdio_read(), mii_rw(), mlx_pci_mem_read_priv(), myson_poll(), myson_probe(), myson_reload_config(), myson_soft_reset(), myson_wait_idle(), natsemi_check_link(), natsemi_pmatch(), natsemi_poll(), natsemi_reload_config(), natsemi_reset(), natsemi_soft_reset(), natsemi_spi_read_bit(), natsemi_spi_write_bit(), nv_mac_reset(), nv_mgmt_acquire_sema(), nv_mgmt_get_version(), nv_mgmt_release_sema(), nv_setup_mac_addr(), nv_setup_phy(), nv_start_rx(), nv_start_tx(), nv_stop_rx(), nv_stop_tx(), nv_txrx_gate(), nv_update_linkspeed(), nv_update_pause(), pci_msix_control(), pci_msix_dump(), pci_push(), phantom_crb_access_128m(), phantom_crb_access_2m(), phantom_crb_access_32m(), phantom_readl(), phy_init(), PROVIDE_IOAPI_INLINE(), realtek_init_eeprom(), realtek_mii_read(), realtek_mii_write(), realtek_open(), realtek_poll_tx(), reg_delay(), skge_read32(), sky2_read32(), tg3_get_invariants(), tg3_read32_mbox_5906(), vmxnet3_check_version(), vmxnet3_command(), vpm_ioread32(), w89c840_poll(), X86_READX(), xenstore_recv(), xenstore_send(), xhci_abort(), xhci_command_free(), xhci_dump(), xhci_dump_port(), xhci_extended_capability(), xhci_init(), xhci_legacy_claim(), xhci_port_protocol(), xhci_port_psiv(), xhci_port_slot_type(), xhci_port_speed(), xhci_port_status(), xhci_reset(), xhci_root_disable(), xhci_root_enable(), xhci_root_open(), xhci_root_speed(), xhci_run(), xhci_stop(), and xhci_supported_protocol().
| #define writeb outb |
Definition at line 158 of file w89c840.c.
Referenced by amd8111e_start(), ecam_write(), exanic_open(), exanic_transmit(), icplus_mii_write_bit(), PROVIDE_IOAPI_INLINE(), realtek_close(), realtek_open(), realtek_reset(), realtek_spi_close_bit(), realtek_spi_open_bit(), realtek_spi_write_bit(), realtek_transmit(), rhine_close(), rhine_irq(), rhine_mii_autopoll(), rhine_mii_read(), rhine_mii_write(), rhine_open(), rhine_poll(), rhine_transmit(), skge_write8(), sky2_write8(), sundance_reset(), velocity_autopoll_start(), velocity_autopoll_stop(), velocity_close(), velocity_irq(), velocity_mii_read(), velocity_mii_write(), velocity_open(), velocity_reset(), vpm_iowrite8(), w89c840_reset(), X86_WRITEX(), xenstore_send(), xhci_legacy_claim(), and xhci_legacy_release().
| #define writew outw |
Definition at line 159 of file w89c840.c.
Referenced by amd8111e_init_hw_default(), amd8111e_start(), ecam_write(), exanic_open(), exanic_transmit(), hfa384x_setreg(), icplus_open(), icplus_poll(), icplus_read_eeprom(), icplus_refill_rx(), icplus_transmit(), PROVIDE_IOAPI_INLINE(), rdc_close(), rdc_create_ring(), rdc_destroy_ring(), rdc_irq(), rdc_mii_read(), rdc_mii_write(), rdc_open(), rdc_reset(), rdc_transmit(), realtek_detect(), realtek_irq(), realtek_legacy_poll_rx(), realtek_poll(), rhine_mii_write(), skge_write16(), sky2_write16(), velocity_alloc_rings(), velocity_close(), velocity_mii_write(), velocity_open(), velocity_poll(), velocity_refill_rx(), vpm_iowrite16(), X86_WRITEX(), and xengrant_alloc().
| #define writel outl |
Definition at line 160 of file w89c840.c.
Referenced by __ew32(), __vxge_hw_pio_mem_write32_lower(), __vxge_hw_pio_mem_write32_upper(), _efx_writel(), amd8111e_disable_interrupt(), amd8111e_enable_interrupt(), amd8111e_force_interrupt(), amd8111e_init_hw_default(), amd8111e_poll(), amd8111e_read_phy(), amd8111e_start(), amd8111e_transmit(), arbel_cmd(), arbel_poll_eq(), arbel_reset(), arbel_ring_doorbell(), ath5k_hw_reg_write(), ath9k_iowrite32(), ath9k_reg_rmw(), bios_mp_ipi(), bnxt_db_cq(), bnxt_db_nq(), bnxt_db_rx(), bnxt_db_tx(), bnxt_er_reg_read(), bnxt_er_reg_write(), bnxt_rst_reg_val(), bw32(), cgem_create_ring(), cgem_destroy_ring(), cgem_mii_read(), cgem_mii_write(), cgem_open(), cgem_reset(), cgem_transmit(), dwgpio_config(), dwgpio_out(), dwgpio_remove(), dwmac_create_ring(), dwmac_destroy_ring(), dwmac_dump_dma(), dwmac_open(), dwmac_refill_rx(), dwmac_reset(), dwmac_transmit(), dwusb_probe(), ecam_write(), eeprom_read(), ehci_async_del(), ehci_bus_open(), ehci_bus_poll(), ehci_reset(), ehci_root_close(), ehci_root_disable(), ehci_root_enable(), ehci_root_open(), ehci_root_poll(), ehci_root_speed(), ehci_run(), ehci_stop(), ena_admin(), ena_clear_caps(), ena_refill_rx(), ena_reset(), ena_set_base(), ena_set_caps(), ena_transmit(), exanic_clear_base(), exanic_close(), exanic_expired(), exanic_i2c_write_bit(), exanic_open(), exanic_probe(), exanic_reset(), exanic_transmit(), exanic_write_base(), forcedeth_link_status(), forcedeth_open(), forcedeth_poll(), forcedeth_probe(), forcedeth_transmit(), golan_cmd_init(), golan_eq_update_ci(), gve_admin(), gve_admin_enable(), gve_configure(), gve_create_queue(), gve_poll(), gve_refill_rx(), gve_reset(), gve_transmit(), gve_watchdog(), hermon_cmd(), hermon_poll_eq(), hermon_post_send(), hermon_reset(), hwrm_write_req(), ice_context_rx(), ice_dump_tx(), ice_probe(), icplus_open(), icplus_reset(), icplus_set_base(), if(), intel_close(), intel_create_ring(), intel_disable_ring(), intel_init_eeprom(), intel_irq(), intel_open(), intel_read_eeprom(), intel_refill_rx(), intel_reset(), intel_reset_ring(), intel_transmit(), intelvf_mbox_msg(), intelvf_mbox_poll(), intelvf_mbox_write(), intelx_close(), intelx_irq(), intelx_open(), intelx_reset(), intelxl_admin_command(), intelxl_alloc_ring(), intelxl_close(), intelxl_context_dump(), intelxl_context_line(), intelxl_disable_admin(), intelxl_disable_ring(), intelxl_enable_admin(), intelxl_enable_ring(), intelxl_open(), intelxl_poll(), intelxl_probe(), intelxl_refill_admin(), intelxl_refill_rx(), intelxl_transmit(), intelxvf_irq(), intelxvf_open(), intelxvf_reset(), jwrite32(), jwrite32f(), linda_writel(), mdio_read(), mdio_sync(), mii_rw(), mlx_pci_mem_write_priv(), myson_close(), myson_create_ring(), myson_destroy_ring(), myson_irq(), myson_open(), myson_poll(), myson_refill_rx(), myson_reload_config(), myson_reset(), myson_soft_reset(), myson_transmit(), natsemi_check_link(), natsemi_close(), natsemi_create_ring(), natsemi_destroy_ring(), natsemi_irq(), natsemi_open(), natsemi_pmatch(), natsemi_refill_rx(), natsemi_reload_config(), natsemi_reset(), natsemi_soft_reset(), natsemi_spi_write_bit(), natsemi_transmit(), nv_disable_hw_interrupts(), nv_enable_hw_interrupts(), nv_init_rings(), nv_mac_reset(), nv_mgmt_acquire_sema(), nv_mgmt_get_version(), nv_mgmt_release_sema(), nv_setup_phy(), nv_start_rx(), nv_start_tx(), nv_stop_rx(), nv_stop_tx(), nv_txrx_gate(), nv_txrx_reset(), nv_update_linkspeed(), nv_update_pause(), pci_msix_control(), pci_msix_map(), phantom_crb_access_128m(), phantom_crb_access_2m(), phantom_crb_access_32m(), phantom_writel(), phy_init(), PROVIDE_IOAPI_INLINE(), qib7322_writel(), realtek_create_buffer(), realtek_create_ring(), realtek_destroy_buffer(), realtek_destroy_ring(), realtek_mii_read(), realtek_mii_write(), realtek_open(), realtek_transmit(), rhine_create_ring(), rhine_destroy_ring(), send_command(), set_rx_mode(), skge_write32(), sky2_write32(), tg3_get_invariants(), tg3_write32_mbox_5906(), velocity_alloc_rings(), velocity_close(), vmxnet3_check_version(), vmxnet3_command(), vmxnet3_open(), vmxnet3_poll_events(), vmxnet3_refill_rx(), vmxnet3_set_ll_addr(), vmxnet3_transmit(), vpm_iowrite32(), w89c840_disable(), w89c840_probe(), w89c840_reset(), w89c840_transmit(), X86_WRITEX(), xengrant_zero(), xenstore_recv(), xenstore_send(), xhci_doorbell(), xhci_event_alloc(), xhci_event_free(), xhci_legacy_claim(), xhci_port_status(), xhci_reset(), xhci_root_disable(), xhci_root_enable(), xhci_root_open(), xhci_root_speed(), xhci_run(), xhci_stop(), and xhci_writeq().
| #define w89c840_buf NIC_FAKE_BSS ( struct w89c840_bss ) |
Definition at line 261 of file w89c840.c.
Referenced by DRIVER(), init_ring(), and w89c840_transmit().
| #define PCI_VENDOR_ID_WINBOND2 0x1050 |
Referenced by w89c840_probe().
| #define PCI_DEVICE_ID_WINBOND2_89C840 0x0840 |
Referenced by w89c840_probe().
| #define PCI_VENDOR_ID_COMPEX 0x11f6 |
Referenced by w89c840_probe().
| #define PCI_DEVICE_ID_COMPEX_RL100ATX 0x2011 |
Referenced by w89c840_probe().
| #define eeprom_delay | ( | ee_addr | ) |
| #define mdio_delay | ( | mdio_addr | ) |
Definition at line 785 of file w89c840.c.
Referenced by mdio_read(), and mdio_sync().
| #define MDIO_WRITE0 (MDIO_EnbOutput) |
| #define MDIO_WRITE1 (MDIO_DataOut | MDIO_EnbOutput) |
| enum w840_offsets |
| enum intr_status_bits |
| enum rx_mode_bits |
| enum mii_reg_bits |
| enum desc_status_bits |
| enum EEPROM_Ctrl_Bits |
| enum EEPROM_Cmds |
| FILE_LICENCE | ( | GPL2_OR_LATER | ) |
|
static |
Definition at line 747 of file w89c840.c.
References addr, EE_ChipSelect, EE_DataIn, EE_ReadCmd, EE_ShiftClk, EE_Write0, EE_Write1, EECtrl, eeprom_delay, read_cmd, readl, retval, and writel.
Referenced by w89c840_probe().
|
static |
Definition at line 810 of file w89c840.c.
References MDIO_DataIn, mdio_delay, MDIO_EnbIn, MDIO_ShiftClk, mdio_sync(), MDIO_WRITE0, MDIO_WRITE1, mii_preamble_required, MIICtrl, readl, retval, and writel.
Referenced by check_duplex(), and w89c840_probe().
|
static |
Definition at line 872 of file w89c840.c.
References ioaddr, mdio_read(), printf(), and w840private.
Referenced by sundance_probe(), and w89c840_reset().
|
static |
Definition at line 895 of file w89c840.c.
References AcceptBroadcast, AcceptMulticast, AcceptMyPhys, ioaddr, memset(), MulticastFilter0, MulticastFilter1, NetworkConfig, printf(), u32, w840private, and writel.
Referenced by w89c840_reset().
|
static |
Definition at line 921 of file w89c840.c.
References DescEndRing, DescIntr, DescOwn, PKT_BUF_SZ, RX_RING_SIZE, TX_RING_SIZE, virt_to_le32desc, w840private, and w89c840_buf.
Referenced by sundance_reset(), and w89c840_reset().
|
static |
Definition at line 302 of file w89c840.c.
References check_duplex(), ETH_ALEN, init_ring(), ioaddr, nic::node_addr, PCIBusCfg, printf(), RxRingPtr, RxStartDemand, set_rx_mode(), StationAddr, TxRingPtr, virt_to_bus(), w840private, writeb, and writel.
Referenced by w89c840_disable(), w89c840_poll(), and w89c840_probe().
|
static |
Definition at line 378 of file w89c840.c.
References desc, DescOwn, IntrStatus, ioaddr, le32desc_to_virt, memcpy(), nic::packet, nic::packetlen, pkt_len, printf(), readl, RX_RING_SIZE, status, u32, w840private, and w89c840_reset().
|
static |
Definition at line 483 of file w89c840.c.
References currticks(), DescEndRing, DescIntr, DescOwn, DescWholePkt, ETH_ALEN, ETH_HLEN, ETH_ZLEN, HasBrokenTx, ioaddr, memcpy(), nic::node_addr, printf(), TX_BUG_FIFO_LIMIT, TX_RING_SIZE, TX_TIMEOUT, TxStartDemand, u16, u32, virt_to_le32desc, w840private, w89c840_buf, and writel.
|
static |
Definition at line 583 of file w89c840.c.
References __unused, ioaddr, NetworkConfig, w840private, w89c840_reset(), and writel.
Referenced by DRIVER().
|
static |
| PCI_DRIVER | ( | w89c840_driver | , |
| w89c840_nics | , | ||
| PCI_NO_CLASS | ) |
References w89c840_nics.
|
static |
Definition at line 626 of file w89c840.c.
References adjust_pci_device(), CanHaveMII, DBG, pci_device::device, driver_flags, eeprom_read(), ETH_ALEN, eth_ntoa(), ioaddr, nic::ioaddr, pci_device::ioaddr, nic::irqno, mdio_read(), nic::nic_op, nic::node_addr, PCI_DEVICE_ID_COMPEX_RL100ATX, PCI_DEVICE_ID_WINBOND2_89C840, PCI_VENDOR_ID_COMPEX, PCI_VENDOR_ID_WINBOND2, PCIBusCfg, printf(), u16, value, pci_device::vendor, w840private, w89c840_operations, w89c840_reset(), w89c840_version, and writel.
Referenced by DRIVER().
|
static |
Definition at line 797 of file w89c840.c.
References bits, mdio_delay, MDIO_ShiftClk, MDIO_WRITE1, and writel.
Referenced by mdio_read().
| DRIVER | ( | "W89C840F" | , |
| nic_driver | , | ||
| pci_driver | , | ||
| w89c840_driver | , | ||
| w89c840_probe | , | ||
| w89c840_disable | , | ||
| w89c840_buf | ) |
References w89c840_buf, w89c840_disable(), and w89c840_probe().
|
static |
Definition at line 88 of file w89c840.c.
Referenced by w89c840_probe().
|
static |
Definition at line 142 of file w89c840.c.
Referenced by w89c840_probe().
|
static |
Referenced by check_duplex(), init_ring(), set_rx_mode(), w89c840_disable(), w89c840_poll(), w89c840_probe(), w89c840_reset(), and w89c840_transmit().
|
static |
Definition at line 608 of file w89c840.c.
Referenced by w89c840_probe().
|
static |
Definition at line 616 of file w89c840.c.
Referenced by PCI_DRIVER().
|
static |
Definition at line 790 of file w89c840.c.
Referenced by mdio_read().