/external/syslinux/gpxe/src/net/ |
D | netdevice.c | 61 void netdev_link_down ( struct net_device *netdev ) { in netdev_link_down() argument 63 switch ( netdev->link_rc ) { in netdev_link_down() 66 netdev->link_rc = -ENOTCONN; in netdev_link_down() 125 int netdev_tx ( struct net_device *netdev, struct io_buffer *iobuf ) { in netdev_tx() argument 128 DBGC ( netdev, "NETDEV %p transmitting %p (%p+%zx)\n", in netdev_tx() 129 netdev, iobuf, iobuf->data, iob_len ( iobuf ) ); in netdev_tx() 131 list_add_tail ( &iobuf->list, &netdev->tx_queue ); in netdev_tx() 133 if ( ! ( netdev->state & NETDEV_OPEN ) ) { in netdev_tx() 138 if ( ( rc = netdev->op->transmit ( netdev, iobuf ) ) != 0 ) in netdev_tx() 144 netdev_tx_complete_err ( netdev, iobuf, rc ); in netdev_tx() [all …]
|
D | ipv6.c | 31 struct net_device *netdev; member 56 add_ipv6_miniroute ( struct net_device *netdev, struct in6_addr prefix, in add_ipv6_miniroute() argument 64 miniroute->netdev = netdev_get ( netdev ); in add_ipv6_miniroute() 87 netdev_put ( miniroute->netdev ); in del_ipv6_miniroute() 100 int add_ipv6_address ( struct net_device *netdev, struct in6_addr prefix, in add_ipv6_address() argument 106 del_ipv6_address ( netdev ); in add_ipv6_address() 109 miniroute = add_ipv6_miniroute ( netdev, prefix, prefix_len, address, in add_ipv6_address() 122 void del_ipv6_address ( struct net_device *netdev ) { in del_ipv6_address() argument 126 if ( miniroute->netdev == netdev ) { in del_ipv6_address() 181 struct net_device *netdev, in ipv6_tx() argument [all …]
|
D | ipv4.c | 47 add_ipv4_miniroute ( struct net_device *netdev, struct in_addr address, in add_ipv4_miniroute() argument 55 DBG ( "via %s\n", netdev->name ); in add_ipv4_miniroute() 65 miniroute->netdev = netdev_get ( netdev ); in add_ipv4_miniroute() 93 DBG ( "via %s\n", miniroute->netdev->name ); in del_ipv4_miniroute() 95 netdev_put ( miniroute->netdev ); in del_ipv4_miniroute() 121 if ( ! ( miniroute->netdev->state & NETDEV_OPEN ) ) in ipv4_route() 271 struct net_device *netdev, uint8_t *ll_dest ) { in ipv4_ll_addr() argument 272 struct ll_protocol *ll_protocol = netdev->ll_protocol; in ipv4_ll_addr() 276 memcpy ( ll_dest, netdev->ll_broadcast, in ipv4_ll_addr() 283 return arp_resolve ( netdev, &ipv4_protocol, &dest, in ipv4_ll_addr() [all …]
|
D | netdev_settings.c | 58 struct net_device *netdev = container_of ( settings, struct net_device, in netdev_store() local 62 if ( len != netdev->ll_protocol->ll_addr_len ) in netdev_store() 64 memcpy ( netdev->ll_addr, data, len ); in netdev_store() 82 struct net_device *netdev = container_of ( settings, struct net_device, in netdev_fetch() local 84 struct device_description *desc = &netdev->dev->desc; in netdev_fetch() 88 if ( len > netdev->ll_protocol->ll_addr_len ) in netdev_fetch() 89 len = netdev->ll_protocol->ll_addr_len; in netdev_fetch() 90 memcpy ( data, netdev->ll_addr, len ); in netdev_fetch() 91 return netdev->ll_protocol->ll_addr_len; in netdev_fetch()
|
D | ethernet.c | 53 static int eth_push ( struct net_device *netdev __unused, in eth_push() 76 static int eth_pull ( struct net_device *netdev __unused, in eth_pull() 184 struct net_device *netdev; in alloc_etherdev() local 186 netdev = alloc_netdev ( priv_size ); in alloc_etherdev() 187 if ( netdev ) { in alloc_etherdev() 188 netdev->ll_protocol = ðernet_protocol; in alloc_etherdev() 189 netdev->ll_broadcast = eth_broadcast; in alloc_etherdev() 190 netdev->max_pkt_len = ETH_FRAME_LEN; in alloc_etherdev() 192 return netdev; in alloc_etherdev()
|
D | ndp.c | 69 add_ndp_entry ( struct net_device *netdev, struct in6_addr *in6, in add_ndp_entry() argument 75 ndp->ll_protocol = netdev->ll_protocol; in add_ndp_entry() 78 memcpy ( ndp->ll_addr, ll_addr, netdev->ll_protocol->ll_addr_len ); in add_ndp_entry() 80 memset ( ndp->ll_addr, 0, netdev->ll_protocol->ll_addr_len ); in add_ndp_entry() 84 inet6_ntoa ( ndp->in6 ), netdev->ll_protocol->name, in add_ndp_entry() 85 netdev->ll_protocol->ntoa ( ndp->ll_addr ) ); in add_ndp_entry() 102 int ndp_resolve ( struct net_device *netdev, struct in6_addr *dest, in ndp_resolve() argument 104 struct ll_protocol *ll_protocol = netdev->ll_protocol; in ndp_resolve() 133 add_ndp_entry ( netdev, dest, NULL, NDP_STATE_INCOMPLETE ); in ndp_resolve() 136 if ( ( rc = icmp6_send_solicit ( netdev, src, dest ) ) != 0 ) { in ndp_resolve()
|
/external/syslinux/gpxe/src/include/gpxe/ |
D | netdevice.h | 64 int ( * rx ) ( struct io_buffer *iobuf, struct net_device *netdev, 105 int ( * push ) ( struct net_device *netdev, struct io_buffer *iobuf, 118 int ( * pull ) ( struct net_device *netdev, struct io_buffer *iobuf, 181 int ( * open ) ( struct net_device *netdev ); 189 void ( * close ) ( struct net_device *netdev ); 209 int ( * transmit ) ( struct net_device *netdev, 222 void ( * poll ) ( struct net_device *netdev ); 228 void ( * irq ) ( struct net_device *netdev, int enable ); 354 static inline void netdev_init ( struct net_device *netdev, in netdev_init() argument 356 netdev->op = op; in netdev_init() [all …]
|
/external/syslinux/gpxe/src/drivers/net/ |
D | eepro100.c | 173 struct net_device *netdev; in ifec_pci_probe() local 182 netdev = alloc_etherdev ( sizeof(*priv) ); in ifec_pci_probe() 183 if ( !netdev ) in ifec_pci_probe() 186 netdev_init ( netdev, &ifec_operations ); in ifec_pci_probe() 187 priv = netdev->priv; in ifec_pci_probe() 189 pci_set_drvdata ( pci, netdev ); in ifec_pci_probe() 190 netdev->dev = &pci->dev; in ifec_pci_probe() 200 ifec_reset ( netdev ); in ifec_pci_probe() 203 ifec_init_eeprom ( netdev ); in ifec_pci_probe() 206 nvs_read ( &priv->eeprom.nvs, EEPROM_ADDR_MAC_0, netdev->hw_addr, in ifec_pci_probe() [all …]
|
D | legacy.c | 26 static int legacy_transmit ( struct net_device *netdev, struct io_buffer *iobuf ) { in legacy_transmit() argument 27 struct nic *nic = netdev->priv; in legacy_transmit() 37 netdev_tx_complete ( netdev, iobuf ); in legacy_transmit() 41 static void legacy_poll ( struct net_device *netdev ) { in legacy_poll() argument 42 struct nic *nic = netdev->priv; in legacy_poll() 53 netdev_rx ( netdev, iobuf ); in legacy_poll() 59 static int legacy_open ( struct net_device *netdev __unused ) { in legacy_open() 64 static void legacy_close ( struct net_device *netdev __unused ) { in legacy_close() 68 static void legacy_irq ( struct net_device *netdev __unused, int enable ) { in legacy_irq() 69 struct nic *nic = netdev->priv; in legacy_irq() [all …]
|
D | pnic.c | 117 static void pnic_poll ( struct net_device *netdev ) { in pnic_poll() argument 118 struct pnic *pnic = netdev->priv; in pnic_poll() 134 netdev_rx_err ( netdev, NULL, -ENOMEM ); in pnic_poll() 140 netdev_rx_err ( netdev, iobuf, -EIO ); in pnic_poll() 144 netdev_rx ( netdev, iobuf ); in pnic_poll() 151 static int pnic_transmit ( struct net_device *netdev, struct io_buffer *iobuf ) { in pnic_transmit() argument 152 struct pnic *pnic = netdev->priv; in pnic_transmit() 161 netdev_tx_complete ( netdev, iobuf ); in pnic_transmit() 168 static int pnic_open ( struct net_device *netdev __unused ) { in pnic_open() 176 static void pnic_close ( struct net_device *netdev __unused ) { in pnic_close() [all …]
|
D | ipoib.c | 53 struct net_device *netdev; member 195 static int ipoib_push ( struct net_device *netdev __unused, in ipoib_push() 227 static int ipoib_pull ( struct net_device *netdev, in ipoib_pull() argument 230 struct ipoib_device *ipoib = netdev->priv; in ipoib_pull() 385 struct net_device *netdev; in alloc_ipoibdev() local 387 netdev = alloc_netdev ( priv_size ); in alloc_ipoibdev() 388 if ( netdev ) { in alloc_ipoibdev() 389 netdev->ll_protocol = &ipoib_protocol; in alloc_ipoibdev() 390 netdev->ll_broadcast = ( uint8_t * ) &ipoib_broadcast; in alloc_ipoibdev() 391 netdev->max_pkt_len = IB_MAX_PAYLOAD_SIZE; in alloc_ipoibdev() [all …]
|
D | rtl8139.c | 269 static void rtl_init_eeprom ( struct net_device *netdev ) { in rtl_init_eeprom() argument 270 struct rtl8139_nic *rtl = netdev->priv; in rtl_init_eeprom() 297 &netdev->refcnt ); in rtl_init_eeprom() 308 static void rtl_reset ( struct net_device *netdev ) { in rtl_reset() argument 309 struct rtl8139_nic *rtl = netdev->priv; in rtl_reset() 324 static int rtl_open ( struct net_device *netdev ) { in rtl_open() argument 325 struct rtl8139_nic *rtl = netdev->priv; in rtl_open() 330 outb ( netdev->ll_addr[i], rtl->ioaddr + MAC0 + i ); in rtl_open() 358 static void rtl_close ( struct net_device *netdev ) { in rtl_close() argument 359 struct rtl8139_nic *rtl = netdev->priv; in rtl_close() [all …]
|
D | natsemi.c | 87 static void natsemi_reset (struct net_device *netdev); 88 static int natsemi_open (struct net_device *netdev); 89 static int natsemi_transmit (struct net_device *netdev, struct io_buffer *iobuf); 90 static void natsemi_poll (struct net_device *netdev); 91 static void natsemi_close (struct net_device *netdev); 92 static void natsemi_irq (struct net_device *netdev, int enable); 173 struct net_device *netdev; in natsemi_probe() local 183 netdev = alloc_etherdev (sizeof (*np)); in natsemi_probe() 184 if (! netdev) in natsemi_probe() 187 netdev_init (netdev, &natsemi_operations); in natsemi_probe() [all …]
|
D | myri10ge.c | 298 static void myri10ge_interrupt_handler ( struct net_device *netdev ) in myri10ge_interrupt_handler() argument 304 priv = myri10ge_priv ( netdev ); in myri10ge_interrupt_handler() 346 netdev_tx_complete ( netdev, iob ); in myri10ge_interrupt_handler() 359 netdev_link_up ( netdev ); in myri10ge_interrupt_handler() 361 netdev_link_down ( netdev ); in myri10ge_interrupt_handler() 513 struct net_device *netdev; in myri10ge_pci_probe() local 518 netdev = alloc_etherdev ( sizeof ( *priv ) ); in myri10ge_pci_probe() 519 if ( !netdev ) { in myri10ge_pci_probe() 525 netdev_init ( netdev, &myri10ge_operations ); in myri10ge_pci_probe() 526 priv = myri10ge_priv ( netdev ); in myri10ge_pci_probe() [all …]
|
D | 3c90x.c | 278 static void a3c90x_process_tx_packets(struct net_device *netdev) in a3c90x_process_tx_packets() argument 280 struct INF_3C90X *p = netdev_priv(netdev); in a3c90x_process_tx_packets() 298 netdev_tx_complete(netdev, p->tx_iobuf[p->tx_tail]); in a3c90x_process_tx_packets() 325 static int a3c90x_transmit(struct net_device *netdev, in a3c90x_transmit() argument 328 struct INF_3C90X *inf_3c90x = netdev_priv(netdev); in a3c90x_transmit() 521 static void a3c90x_process_rx_packets(struct net_device *netdev) in a3c90x_process_rx_packets() argument 525 struct INF_3C90X *p = netdev_priv(netdev); in a3c90x_process_rx_packets() 542 netdev_rx_err(netdev, p->rx_iobuf[p->rx_cur], in a3c90x_process_rx_packets() 554 netdev_rx(netdev, p->rx_iobuf[p->rx_cur]); in a3c90x_process_rx_packets() 572 static void a3c90x_poll(struct net_device *netdev) in a3c90x_poll() argument [all …]
|
D | b44.c | 350 b44_set_rx_mode(bp->netdev); in b44_init_hw() 574 b44_cam_write(bp, bp->netdev->ll_addr, 0); in b44_set_mac_addr() 597 bp->netdev->hw_addr[0] = eeprom[79]; in b44_load_mac_and_phy_addr() 598 bp->netdev->hw_addr[1] = eeprom[78]; in b44_load_mac_and_phy_addr() 599 bp->netdev->hw_addr[2] = eeprom[81]; in b44_load_mac_and_phy_addr() 600 bp->netdev->hw_addr[3] = eeprom[80]; in b44_load_mac_and_phy_addr() 601 bp->netdev->hw_addr[4] = eeprom[83]; in b44_load_mac_and_phy_addr() 602 bp->netdev->hw_addr[5] = eeprom[82]; in b44_load_mac_and_phy_addr() 609 static void b44_set_rx_mode(struct net_device *netdev) in b44_set_rx_mode() argument 611 struct b44_private *bp = netdev_priv(netdev); in b44_set_rx_mode() [all …]
|
D | atl1e.c | 129 struct net_device *netdev = adapter->netdev; in atl1e_check_link() local 139 if (netdev_link_ok(netdev)) { /* old link state: Up */ in atl1e_check_link() 147 DBG("atl1e: %s link is down\n", netdev->name); in atl1e_check_link() 148 netdev_link_down(netdev); in atl1e_check_link() 164 netdev->name, adapter->link_speed, in atl1e_check_link() 167 netdev_link_up(netdev); in atl1e_check_link() 173 static int atl1e_mdio_read(struct net_device *netdev, int phy_id __unused, in atl1e_mdio_read() argument 176 struct atl1e_adapter *adapter = netdev_priv(netdev); in atl1e_mdio_read() 183 static void atl1e_mdio_write(struct net_device *netdev, int phy_id __unused, in atl1e_mdio_write() argument 186 struct atl1e_adapter *adapter = netdev_priv(netdev); in atl1e_mdio_write() [all …]
|
/external/syslinux/gpxe/src/usr/ |
D | ifmgmt.c | 44 int ifopen ( struct net_device *netdev ) { in ifopen() argument 47 if ( ( rc = netdev_open ( netdev ) ) != 0 ) { in ifopen() 49 netdev->name, strerror ( rc ) ); in ifopen() 61 void ifclose ( struct net_device *netdev ) { in ifclose() argument 62 netdev_close ( netdev ); in ifclose() 89 void ifstat ( struct net_device *netdev ) { in ifstat() argument 92 netdev->name, netdev_addr ( netdev ), netdev->dev->name, in ifstat() 93 ( ( netdev->state & NETDEV_OPEN ) ? "open" : "closed" ), in ifstat() 94 ( netdev_link_ok ( netdev ) ? "up" : "down" ), in ifstat() 95 netdev->tx_stats.good, netdev->tx_stats.bad, in ifstat() [all …]
|
D | dhcpmgmt.c | 39 int dhcp ( struct net_device *netdev ) { in dhcp() argument 46 if ( ( rc = ifopen ( netdev ) ) != 0 ) in dhcp() 50 if ( ( rc = iflinkwait ( netdev, LINK_WAIT_MS ) ) != 0 ) in dhcp() 54 chaddr = dhcp_chaddr ( netdev, &hlen, &flags ); in dhcp() 55 printf ( "DHCP (%s ", netdev->name ); in dhcp() 59 if ( ( rc = start_dhcp ( &monojob, netdev ) ) == 0 ) { in dhcp() 69 int pxebs ( struct net_device *netdev, unsigned int pxe_type ) { in pxebs() argument 73 printf ( "PXEBS (%s type %d)", netdev->name, pxe_type ); in pxebs() 74 if ( ( rc = start_pxebs ( &monojob, netdev, pxe_type ) ) == 0 ) in pxebs()
|
D | autoboot.c | 131 static int netboot ( struct net_device *netdev ) { in netboot() argument 144 if ( ( rc = ifopen ( netdev ) ) != 0 ) in netboot() 146 ifstat ( netdev ); in netboot() 149 if ( ( rc = dhcp ( netdev ) ) != 0 ) in netboot() 163 return pxe_menu_boot ( netdev ); in netboot() 205 struct net_device *netdev; in close_all_netdevs() local 207 for_each_netdev ( netdev ) { in close_all_netdevs() 208 ifclose ( netdev ); in close_all_netdevs() 217 struct net_device *netdev; in autoboot() local 225 for_each_netdev ( netdev ) { in autoboot() [all …]
|
/external/syslinux/gpxe/src/interface/efi/ |
D | efi_snp.c | 47 struct net_device *netdev; member 120 struct net_device *netdev = snpdev->netdev; in efi_snp_set_mode() local 122 struct ll_protocol *ll_protocol = netdev->ll_protocol; in efi_snp_set_mode() 127 mode->MaxPacketSize = netdev->max_pkt_len; in efi_snp_set_mode() 132 memcpy ( &mode->CurrentAddress, netdev->ll_addr, ll_addr_len ); in efi_snp_set_mode() 133 memcpy ( &mode->BroadcastAddress, netdev->ll_broadcast, ll_addr_len ); in efi_snp_set_mode() 134 ll_protocol->init_addr ( netdev->hw_addr, &mode->PermanentAddress ); in efi_snp_set_mode() 138 mode->MediaPresent = ( netdev_link_ok ( netdev ) ? TRUE : FALSE ); in efi_snp_set_mode() 155 list_for_each_entry ( iobuf, &snpdev->netdev->rx_queue, list ) in efi_snp_poll() 157 netdev_poll ( snpdev->netdev ); in efi_snp_poll() [all …]
|
/external/syslinux/gpxe/src/arch/i386/drivers/net/ |
D | undinet.c | 64 static void undinet_close ( struct net_device *netdev ); 168 static int undinet_transmit ( struct net_device *netdev, in undinet_transmit() argument 208 netdev_tx_complete ( netdev, iobuf ); in undinet_transmit() 244 static void undinet_poll ( struct net_device *netdev ) { in undinet_poll() argument 245 struct undi_nic *undinic = netdev->priv; in undinet_poll() 291 netdev_rx_err ( netdev, NULL, -EINVAL ); in undinet_poll() 301 netdev_rx_err ( netdev, NULL, -ENOMEM ); in undinet_poll() 317 netdev_rx ( netdev, iob_disown ( iobuf ) ); in undinet_poll() 344 netdev_rx_err ( netdev, iobuf, -EINVAL ); in undinet_poll() 354 static int undinet_open ( struct net_device *netdev ) { in undinet_open() argument [all …]
|
/external/syslinux/gpxe/src/hci/commands/ |
D | ifmgmt_cmd.c | 61 struct net_device *netdev; in ifcommon_do_all() local 65 for_each_netdev ( netdev ) { in ifcommon_do_all() 66 if ( payload ( netdev ) != 0 ) in ifcommon_do_all() 81 struct net_device *netdev; in ifcommon_do_list() local 86 netdev = find_netdev ( netdev_name ); in ifcommon_do_list() 87 if ( ! netdev ) { in ifcommon_do_list() 92 if ( payload ( netdev ) != 0 ) in ifcommon_do_list() 135 static int ifopen_payload ( struct net_device *netdev ) { in ifopen_payload() argument 136 return ifopen ( netdev ); in ifopen_payload() 145 static int ifclose_payload ( struct net_device *netdev ) { in ifclose_payload() argument [all …]
|
D | dhcp_cmd.c | 67 struct net_device *netdev; in dhcp_exec() local 91 netdev = find_netdev ( netdev_txt ); in dhcp_exec() 92 if ( ! netdev ) { in dhcp_exec() 98 if ( ( rc = dhcp ( netdev ) ) != 0 ) { in dhcp_exec() 99 printf ( "Could not configure %s: %s\n", netdev->name, in dhcp_exec() 134 struct net_device *netdev; in pxebs_exec() local 159 netdev = find_netdev ( netdev_txt ); in pxebs_exec() 160 if ( ! netdev ) { in pxebs_exec() 171 if ( ( rc = pxebs ( netdev, pxe_type ) ) != 0 ) { in pxebs_exec() 173 netdev->name, strerror ( rc ) ); in pxebs_exec()
|
/external/syslinux/gpxe/src/core/ |
D | gdbudp.c | 45 static struct net_device *netdev; variable 50 static void gdbudp_ensure_netdev_open ( struct net_device *netdev ) { in gdbudp_ensure_netdev_open() argument 52 assert ( netdev ); in gdbudp_ensure_netdev_open() 53 netdev_open ( netdev ); in gdbudp_ensure_netdev_open() 66 gdbudp_ensure_netdev_open ( netdev ); in gdbudp_recv() 69 netdev_poll ( netdev ); in gdbudp_recv() 70 while ( ( iob = netdev_rx_dequeue ( netdev ) ) != NULL ) { in gdbudp_recv() 95 memcpy ( arp_sender_ha ( arphdr ), netdev->ll_addr, ETH_ALEN ); in gdbudp_recv() 100 memcpy ( ethhdr->h_source, netdev->ll_addr, ETH_ALEN ); in gdbudp_recv() 102 netdev_tx ( netdev, iob ); in gdbudp_recv() [all …]
|