HelenOS sources
nic 199 uspace/drv/nic/ar9271/ar9271.c static errno_t ar9271_on_multicast_mode_change(nic_t *nic,
nic 222 uspace/drv/nic/ar9271/ar9271.c static errno_t ar9271_on_unicast_mode_change(nic_t *nic, nic_unicast_mode_t mode,
nic 248 uspace/drv/nic/ar9271/ar9271.c static errno_t ar9271_on_broadcast_mode_change(nic_t *nic,
nic 77 uspace/drv/nic/ar9271/htc.c nic_t *nic =
nic 79 uspace/drv/nic/ar9271/htc.c nic_query_address(nic, &addr);
nic 164 uspace/drv/nic/ar9271/hw.c nic_t *nic = nic_get_from_ddf_dev(ar9271->ddf_dev);
nic 166 uspace/drv/nic/ar9271/hw.c errno_t rc = nic_report_address(nic, &ar9271_address);
nic 69 uspace/drv/nic/e1k/e1k.c #define DRIVER_DATA_NIC(nic) \
nic 70 uspace/drv/nic/e1k/e1k.c ((e1000_t *) nic_get_specific(nic))
nic 835 uspace/drv/nic/e1k/e1k.c static errno_t e1000_on_multicast_mode_change(nic_t *nic, nic_multicast_mode_t mode,
nic 838 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 847 uspace/drv/nic/e1k/e1k.c nic_report_hw_filtering(nic, -1, 1, -1);
nic 858 uspace/drv/nic/e1k/e1k.c nic_report_hw_filtering(nic, -1, 0, -1);
nic 862 uspace/drv/nic/e1k/e1k.c nic_report_hw_filtering(nic, -1, 1, -1);
nic 868 uspace/drv/nic/e1k/e1k.c nic_report_hw_filtering(nic, -1, 1, -1);
nic 889 uspace/drv/nic/e1k/e1k.c static errno_t e1000_on_unicast_mode_change(nic_t *nic, nic_unicast_mode_t mode,
nic 892 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 902 uspace/drv/nic/e1k/e1k.c nic_report_hw_filtering(nic, 1, -1, -1);
nic 908 uspace/drv/nic/e1k/e1k.c nic_report_hw_filtering(nic, 1, -1, -1);
nic 915 uspace/drv/nic/e1k/e1k.c nic_report_hw_filtering(nic, 0, -1, -1);
nic 919 uspace/drv/nic/e1k/e1k.c nic_report_hw_filtering(nic, 1, -1, -1);
nic 926 uspace/drv/nic/e1k/e1k.c nic_report_hw_filtering(nic, 1, -1, -1);
nic 945 uspace/drv/nic/e1k/e1k.c static errno_t e1000_on_broadcast_mode_change(nic_t *nic, nic_broadcast_mode_t mode)
nic 947 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1013 uspace/drv/nic/e1k/e1k.c static void e1000_on_vlan_mask_change(nic_t *nic,
nic 1016 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1097 uspace/drv/nic/e1k/e1k.c static void e1000_fill_new_rx_descriptor(nic_t *nic, size_t offset)
nic 1099 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1136 uspace/drv/nic/e1k/e1k.c static void e1000_clear_tx_descriptor(nic_t *nic, unsigned int offset)
nic 1138 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1173 uspace/drv/nic/e1k/e1k.c static void e1000_receive_frames(nic_t *nic)
nic 1175 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1188 uspace/drv/nic/e1k/e1k.c nic_frame_t *frame = nic_alloc_frame(nic, frame_size);
nic 1191 uspace/drv/nic/e1k/e1k.c nic_received_frame(nic, frame);
nic 1196 uspace/drv/nic/e1k/e1k.c e1000_fill_new_rx_descriptor(nic, next_tail);
nic 1237 uspace/drv/nic/e1k/e1k.c static void e1000_interrupt_handler_impl(nic_t *nic, uint32_t icr)
nic 1240 uspace/drv/nic/e1k/e1k.c e1000_receive_frames(nic);
nic 1252 uspace/drv/nic/e1k/e1k.c nic_t *nic = (nic_t *)arg;
nic 1253 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1255 uspace/drv/nic/e1k/e1k.c e1000_interrupt_handler_impl(nic, icr);
nic 1271 uspace/drv/nic/e1k/e1k.c inline static errno_t e1000_register_int_handler(nic_t *nic,
nic 1274 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1283 uspace/drv/nic/e1k/e1k.c errno_t rc = register_interrupt_handler(nic_get_ddf_dev(nic), e1000->irq,
nic 1284 uspace/drv/nic/e1k/e1k.c e1000_interrupt_handler, (void *)nic, &e1000_irq_code, handle);
nic 1295 uspace/drv/nic/e1k/e1k.c static void e1000_poll(nic_t *nic)
nic 1297 uspace/drv/nic/e1k/e1k.c assert(nic);
nic 1299 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = nic_get_specific(nic);
nic 1303 uspace/drv/nic/e1k/e1k.c e1000_interrupt_handler_impl(nic, icr);
nic 1327 uspace/drv/nic/e1k/e1k.c static errno_t e1000_poll_mode_change(nic_t *nic, nic_poll_mode_t mode,
nic 1330 uspace/drv/nic/e1k/e1k.c assert(nic);
nic 1332 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = nic_get_specific(nic);
nic 1381 uspace/drv/nic/e1k/e1k.c static errno_t e1000_initialize_rx_structure(nic_t *nic)
nic 1383 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1424 uspace/drv/nic/e1k/e1k.c e1000_fill_new_rx_descriptor(nic, i);
nic 1458 uspace/drv/nic/e1k/e1k.c static void e1000_uninitialize_rx_structure(nic_t *nic)
nic 1460 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1688 uspace/drv/nic/e1k/e1k.c static void e1000_clear_tx_ring(nic_t *nic)
nic 1694 uspace/drv/nic/e1k/e1k.c e1000_clear_tx_descriptor(nic, offset);
nic 1726 uspace/drv/nic/e1k/e1k.c static errno_t e1000_reset(nic_t *nic)
nic 1728 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1757 uspace/drv/nic/e1k/e1k.c static errno_t e1000_on_activating(nic_t *nic)
nic 1759 uspace/drv/nic/e1k/e1k.c assert(nic);
nic 1761 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1781 uspace/drv/nic/e1k/e1k.c e1000_clear_tx_ring(nic);
nic 1803 uspace/drv/nic/e1k/e1k.c static errno_t e1000_on_down_unlocked(nic_t *nic)
nic 1805 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1834 uspace/drv/nic/e1k/e1k.c static errno_t e1000_on_down(nic_t *nic)
nic 1836 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1842 uspace/drv/nic/e1k/e1k.c errno_t rc = e1000_on_down_unlocked(nic);
nic 1859 uspace/drv/nic/e1k/e1k.c static errno_t e1000_on_stopping(nic_t *nic)
nic 1861 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 1867 uspace/drv/nic/e1k/e1k.c errno_t rc = e1000_on_down_unlocked(nic);
nic 1869 uspace/drv/nic/e1k/e1k.c rc = e1000_reset(nic);
nic 1885 uspace/drv/nic/e1k/e1k.c nic_t *nic = nic_create_and_bind(dev);
nic 1886 uspace/drv/nic/e1k/e1k.c if (!nic)
nic 1898 uspace/drv/nic/e1k/e1k.c nic_set_specific(nic, e1000);
nic 1899 uspace/drv/nic/e1k/e1k.c nic_set_send_frame_handler(nic, e1000_send_frame);
nic 1900 uspace/drv/nic/e1k/e1k.c nic_set_state_change_handlers(nic, e1000_on_activating,
nic 1902 uspace/drv/nic/e1k/e1k.c nic_set_filtering_change_handlers(nic,
nic 1905 uspace/drv/nic/e1k/e1k.c nic_set_poll_handlers(nic, e1000_poll_mode_change, e1000_poll);
nic 2145 uspace/drv/nic/e1k/e1k.c nic_t *nic = ddf_dev_data_get(dev);
nic 2146 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 2167 uspace/drv/nic/e1k/e1k.c fun = ddf_fun_create(nic_get_ddf_dev(nic), fun_exposed, "port0");
nic 2170 uspace/drv/nic/e1k/e1k.c nic_set_ddf_fun(nic, fun);
nic 2174 uspace/drv/nic/e1k/e1k.c rc = e1000_register_int_handler(nic, &irq_handle);
nic 2179 uspace/drv/nic/e1k/e1k.c rc = e1000_initialize_rx_structure(nic);
nic 2185 uspace/drv/nic/e1k/e1k.c rc = nic_report_address(nic, &e1000_address);
nic 2192 uspace/drv/nic/e1k/e1k.c rc = nic_report_poll_mode(nic, NIC_POLL_PERIODIC, &period);
nic 2210 uspace/drv/nic/e1k/e1k.c e1000_uninitialize_rx_structure(nic);
nic 2215 uspace/drv/nic/e1k/e1k.c nic_set_ddf_fun(nic, NULL);
nic 2301 uspace/drv/nic/e1k/e1k.c nic_t *nic = NIC_DATA_FUN(fun);
nic 2302 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 2307 uspace/drv/nic/e1k/e1k.c errno_t rc = nic_report_address(nic, addr);
nic 2339 uspace/drv/nic/e1k/e1k.c static void e1000_send_frame(nic_t *nic, void *data, size_t size)
nic 2341 uspace/drv/nic/e1k/e1k.c assert(nic);
nic 2343 uspace/drv/nic/e1k/e1k.c e1000_t *e1000 = DRIVER_DATA_NIC(nic);
nic 79 uspace/drv/nic/virtio-net/virtio-net.c nic_t *nic = (nic_t *)arg;
nic 80 uspace/drv/nic/virtio-net/virtio-net.c virtio_net_t *virtio_net = nic_get_specific(nic);
nic 96 uspace/drv/nic/virtio-net/virtio-net.c nic_frame_t *frame = nic_alloc_frame(nic, len - sizeof(*hdr));
nic 99 uspace/drv/nic/virtio-net/virtio-net.c nic_received_frame(nic, frame);
nic 120 uspace/drv/nic/virtio-net/virtio-net.c nic_t *nic = ddf_dev_data_get(dev);
nic 121 uspace/drv/nic/virtio-net/virtio-net.c virtio_net_t *virtio_net = nic_get_specific(nic);
nic 127 uspace/drv/nic/virtio-net/virtio-net.c errno_t rc = nic_get_resources(nic, &res);
nic 171 uspace/drv/nic/virtio-net/virtio-net.c virtio_net_irq_handler, (void *)nic, &irq_code,
nic 177 uspace/drv/nic/virtio-net/virtio-net.c nic_t *nic = nic_create_and_bind(dev);
nic 178 uspace/drv/nic/virtio-net/virtio-net.c if (!nic)
nic 187 uspace/drv/nic/virtio-net/virtio-net.c nic_set_specific(nic, virtio_net);
nic 287 uspace/drv/nic/virtio-net/virtio-net.c rc = nic_report_address(nic, &nic_addr);
nic 322 uspace/drv/nic/virtio-net/virtio-net.c nic_t *nic = ddf_dev_data_get(dev);
nic 323 uspace/drv/nic/virtio-net/virtio-net.c virtio_net_t *virtio_net = (virtio_net_t *) nic_get_specific(nic);
nic 333 uspace/drv/nic/virtio-net/virtio-net.c static void virtio_net_send(nic_t *nic, void *data, size_t size)
nic 335 uspace/drv/nic/virtio-net/virtio-net.c virtio_net_t *virtio_net = nic_get_specific(nic);
nic 368 uspace/drv/nic/virtio-net/virtio-net.c static errno_t virtio_net_on_multicast_mode_change(nic_t *nic,
nic 374 uspace/drv/nic/virtio-net/virtio-net.c nic_report_hw_filtering(nic, -1, 0, -1);
nic 377 uspace/drv/nic/virtio-net/virtio-net.c nic_report_hw_filtering(nic, -1, 0, -1);
nic 380 uspace/drv/nic/virtio-net/virtio-net.c nic_report_hw_filtering(nic, -1, 0, -1);
nic 388 uspace/drv/nic/virtio-net/virtio-net.c static errno_t virtio_net_on_broadcast_mode_change(nic_t *nic,
nic 415 uspace/drv/nic/virtio-net/virtio-net.c nic_t *nic = ddf_dev_data_get(dev);
nic 416 uspace/drv/nic/virtio-net/virtio-net.c nic_set_ddf_fun(nic, fun);
nic 419 uspace/drv/nic/virtio-net/virtio-net.c nic_set_send_frame_handler(nic, virtio_net_send);
nic 420 uspace/drv/nic/virtio-net/virtio-net.c nic_set_filtering_change_handlers(nic, NULL,
nic 453 uspace/drv/nic/virtio-net/virtio-net.c nic_t *nic = nic_get_from_ddf_fun(fun);
nic 454 uspace/drv/nic/virtio-net/virtio-net.c if (!nic)
nic 550 uspace/lib/ieee80211/src/ieee80211.c static void ieee80211_send_frame(nic_t *nic, void *data, size_t size)
nic 553 uspace/lib/ieee80211/src/ieee80211.c nic_get_specific(nic);
nic 753 uspace/lib/ieee80211/src/ieee80211.c nic_t *nic = nic_create_and_bind(ddf_dev);
nic 754 uspace/lib/ieee80211/src/ieee80211.c if (!nic)
nic 757 uspace/lib/ieee80211/src/ieee80211.c nic_set_specific(nic, ieee80211_dev);
nic 783 uspace/lib/ieee80211/src/ieee80211.c nic_t *nic = nic_get_from_ddf_dev(ieee80211_dev->ddf_dev);
nic 786 uspace/lib/ieee80211/src/ieee80211.c nic_set_send_frame_handler(nic, ieee80211_send_frame);
nic 793 uspace/lib/ieee80211/src/ieee80211.c nic_set_ddf_fun(nic, fun);
nic 856 uspace/lib/ieee80211/src/ieee80211.c nic_t *nic = nic_get_from_ddf_dev(ieee80211_dev->ddf_dev);
nic 858 uspace/lib/ieee80211/src/ieee80211.c nic_query_address(nic, &nic_address);
nic 923 uspace/lib/ieee80211/src/ieee80211.c nic_t *nic = nic_get_from_ddf_dev(ieee80211_dev->ddf_dev);
nic 925 uspace/lib/ieee80211/src/ieee80211.c nic_query_address(nic, &nic_address);
nic 973 uspace/lib/ieee80211/src/ieee80211.c nic_t *nic = nic_get_from_ddf_dev(ieee80211_dev->ddf_dev);
nic 975 uspace/lib/ieee80211/src/ieee80211.c nic_query_address(nic, &nic_address);
nic 1066 uspace/lib/ieee80211/src/ieee80211.c nic_t *nic = nic_get_from_ddf_dev(ieee80211_dev->ddf_dev);
nic 1068 uspace/lib/ieee80211/src/ieee80211.c nic_query_address(nic, &nic_address);
nic 1446 uspace/lib/ieee80211/src/ieee80211.c nic_t *nic = nic_get_from_ddf_dev(ieee80211_dev->ddf_dev);
nic 1448 uspace/lib/ieee80211/src/ieee80211.c nic_query_address(nic, &nic_address);
nic 1575 uspace/lib/ieee80211/src/ieee80211.c ieee80211_send_frame(nic, output_buffer, output_size);
nic 1643 uspace/lib/ieee80211/src/ieee80211.c nic_t *nic = nic_get_from_ddf_dev(ieee80211_dev->ddf_dev);
nic 1666 uspace/lib/ieee80211/src/ieee80211.c nic_frame_t *frame = nic_alloc_frame(nic, frame_size);
nic 1685 uspace/lib/ieee80211/src/ieee80211.c nic_received_frame(nic, frame);
nic 49 uspace/lib/nic/include/nic.h struct nic;
nic 50 uspace/lib/nic/include/nic.h typedef struct nic nic_t;
nic 1047 uspace/lib/nic/src/nic_driver.c nic_t *nic = data;
nic 1048 uspace/lib/nic/src/nic_driver.c struct sw_poll_info *info = &nic->sw_poll_info;
nic 1050 uspace/lib/nic/src/nic_driver.c fibril_rwlock_read_lock(&nic->main_lock);
nic 1053 uspace/lib/nic/src/nic_driver.c struct timespec remaining = nic->poll_period;
nic 1054 uspace/lib/nic/src/nic_driver.c fibril_rwlock_read_unlock(&nic->main_lock);
nic 1093 uspace/lib/nic/src/nic_driver.c fibril_rwlock_read_lock(&nic->main_lock);
nic 1095 uspace/lib/nic/src/nic_driver.c nic->on_poll_request(nic);
nic 1097 uspace/lib/nic/src/nic_driver.c fibril_rwlock_read_unlock(&nic->main_lock);
nic 197 uspace/lib/nic/src/nic_impl.c nic_t *nic = nic_get_from_ddf_fun(fun);
nic 198 uspace/lib/nic/src/nic_impl.c fibril_rwlock_write_lock(&nic->main_lock);
nic 200 uspace/lib/nic/src/nic_impl.c nic->client_session = async_callback_receive(EXCHANGE_SERIALIZE);
nic 201 uspace/lib/nic/src/nic_impl.c if (nic->client_session == NULL) {
nic 202 uspace/lib/nic/src/nic_impl.c fibril_rwlock_write_unlock(&nic->main_lock);
nic 206 uspace/lib/nic/src/nic_impl.c fibril_rwlock_write_unlock(&nic->main_lock);
nic 53 uspace/srv/net/ethip/arp.c static errno_t arp_send_packet(ethip_nic_t *nic, arp_eth_packet_t *packet);
nic 55 uspace/srv/net/ethip/arp.c void arp_received(ethip_nic_t *nic, eth_frame_t *frame)
nic 70 uspace/srv/net/ethip/arp.c ethip_link_addr_t *laddr = ethip_nic_addr_find(nic, &addr);
nic 88 uspace/srv/net/ethip/arp.c reply.sender_hw_addr = nic->mac_addr;
nic 93 uspace/srv/net/ethip/arp.c arp_send_packet(nic, &reply);
nic 97 uspace/srv/net/ethip/arp.c errno_t arp_translate(ethip_nic_t *nic, addr32_t src_addr, addr32_t ip_addr,
nic 113 uspace/srv/net/ethip/arp.c packet.sender_hw_addr = nic->mac_addr;
nic 118 uspace/srv/net/ethip/arp.c rc = arp_send_packet(nic, &packet);
nic 125 uspace/srv/net/ethip/arp.c static errno_t arp_send_packet(ethip_nic_t *nic, arp_eth_packet_t *packet)
nic 153 uspace/srv/net/ethip/arp.c rc = ethip_nic_send(nic, fdata, fsize);
nic 99 uspace/srv/net/ethip/ethip.c errno_t ethip_iplink_init(ethip_nic_t *nic)
nic 109 uspace/srv/net/ethip/ethip.c iplink_srv_init(&nic->iplink);
nic 110 uspace/srv/net/ethip/ethip.c nic->iplink.ops = ðip_iplink_ops;
nic 111 uspace/srv/net/ethip/ethip.c nic->iplink.arg = nic;
nic 125 uspace/srv/net/ethip/ethip.c nic->iplink_sid = sid;
nic 149 uspace/srv/net/ethip/ethip.c ethip_nic_t *nic;
nic 154 uspace/srv/net/ethip/ethip.c nic = ethip_nic_find_by_iplink_sid(sid);
nic 155 uspace/srv/net/ethip/ethip.c if (nic == NULL) {
nic 160 uspace/srv/net/ethip/ethip.c iplink_conn(icall, &nic->iplink);
nic 179 uspace/srv/net/ethip/ethip.c ethip_nic_t *nic = (ethip_nic_t *) srv->arg;
nic 182 uspace/srv/net/ethip/ethip.c errno_t rc = arp_translate(nic, sdu->src, sdu->dest, &frame.dest);
nic 189 uspace/srv/net/ethip/ethip.c frame.src = nic->mac_addr;
nic 200 uspace/srv/net/ethip/ethip.c rc = ethip_nic_send(nic, data, size);
nic 210 uspace/srv/net/ethip/ethip.c ethip_nic_t *nic = (ethip_nic_t *) srv->arg;
nic 214 uspace/srv/net/ethip/ethip.c frame.src = nic->mac_addr;
nic 225 uspace/srv/net/ethip/ethip.c rc = ethip_nic_send(nic, data, size);
nic 234 uspace/srv/net/ethip/ethip.c ethip_nic_t *nic = (ethip_nic_t *) srv->arg;
nic 249 uspace/srv/net/ethip/ethip.c arp_received(nic, &frame);
nic 256 uspace/srv/net/ethip/ethip.c rc = iplink_ev_recv(&nic->iplink, &sdu, ip_v4);
nic 263 uspace/srv/net/ethip/ethip.c rc = iplink_ev_recv(&nic->iplink, &sdu, ip_v6);
nic 285 uspace/srv/net/ethip/ethip.c ethip_nic_t *nic = (ethip_nic_t *) srv->arg;
nic 286 uspace/srv/net/ethip/ethip.c *mac = nic->mac_addr;
nic 295 uspace/srv/net/ethip/ethip.c ethip_nic_t *nic = (ethip_nic_t *) srv->arg;
nic 296 uspace/srv/net/ethip/ethip.c nic->mac_addr = *mac;
nic 303 uspace/srv/net/ethip/ethip.c ethip_nic_t *nic = (ethip_nic_t *) srv->arg;
nic 305 uspace/srv/net/ethip/ethip.c return ethip_nic_addr_add(nic, addr);
nic 310 uspace/srv/net/ethip/ethip.c ethip_nic_t *nic = (ethip_nic_t *) srv->arg;
nic 312 uspace/srv/net/ethip/ethip.c return ethip_nic_addr_remove(nic, addr);
nic 87 uspace/srv/net/ethip/ethip_nic.c list_foreach(ethip_nic_list, link, ethip_nic_t, nic) {
nic 88 uspace/srv/net/ethip/ethip_nic.c if (nic->svc_id == svcs[i]) {
nic 109 uspace/srv/net/ethip/ethip_nic.c ethip_nic_t *nic = calloc(1, sizeof(ethip_nic_t));
nic 110 uspace/srv/net/ethip/ethip_nic.c if (nic == NULL) {
nic 116 uspace/srv/net/ethip/ethip_nic.c link_initialize(&nic->link);
nic 117 uspace/srv/net/ethip/ethip_nic.c list_initialize(&nic->addr_list);
nic 119 uspace/srv/net/ethip/ethip_nic.c return nic;
nic 137 uspace/srv/net/ethip/ethip_nic.c static void ethip_nic_delete(ethip_nic_t *nic)
nic 139 uspace/srv/net/ethip/ethip_nic.c if (nic->svc_name != NULL)
nic 140 uspace/srv/net/ethip/ethip_nic.c free(nic->svc_name);
nic 142 uspace/srv/net/ethip/ethip_nic.c free(nic);
nic 156 uspace/srv/net/ethip/ethip_nic.c ethip_nic_t *nic = ethip_nic_new();
nic 157 uspace/srv/net/ethip/ethip_nic.c if (nic == NULL)
nic 160 uspace/srv/net/ethip/ethip_nic.c errno_t rc = loc_service_get_name(sid, &nic->svc_name);
nic 166 uspace/srv/net/ethip/ethip_nic.c nic->sess = loc_service_connect(sid, INTERFACE_DDF, 0);
nic 167 uspace/srv/net/ethip/ethip_nic.c if (nic->sess == NULL) {
nic 168 uspace/srv/net/ethip/ethip_nic.c log_msg(LOG_DEFAULT, LVL_ERROR, "Failed connecting '%s'", nic->svc_name);
nic 172 uspace/srv/net/ethip/ethip_nic.c nic->svc_id = sid;
nic 174 uspace/srv/net/ethip/ethip_nic.c rc = nic_callback_create(nic->sess, ethip_nic_cb_conn, nic);
nic 177 uspace/srv/net/ethip/ethip_nic.c "from '%s'", nic->svc_name);
nic 181 uspace/srv/net/ethip/ethip_nic.c log_msg(LOG_DEFAULT, LVL_DEBUG, "Opened NIC '%s'", nic->svc_name);
nic 182 uspace/srv/net/ethip/ethip_nic.c list_append(&nic->link, ðip_nic_list);
nic 185 uspace/srv/net/ethip/ethip_nic.c rc = ethip_iplink_init(nic);
nic 189 uspace/srv/net/ethip/ethip_nic.c rc = nic_get_address(nic->sess, &nic_address);
nic 192 uspace/srv/net/ethip/ethip_nic.c nic->svc_name);
nic 196 uspace/srv/net/ethip/ethip_nic.c eth_addr_decode(nic_address.address, &nic->mac_addr);
nic 198 uspace/srv/net/ethip/ethip_nic.c rc = nic_set_state(nic->sess, NIC_STATE_ACTIVE);
nic 201 uspace/srv/net/ethip/ethip_nic.c nic->svc_name);
nic 205 uspace/srv/net/ethip/ethip_nic.c rc = nic_broadcast_set_mode(nic->sess, NIC_BROADCAST_ACCEPTED);
nic 208 uspace/srv/net/ethip/ethip_nic.c "reception of broadcast frames on '%s'.", nic->svc_name);
nic 218 uspace/srv/net/ethip/ethip_nic.c list_remove(&nic->link);
nic 220 uspace/srv/net/ethip/ethip_nic.c if (nic->sess != NULL)
nic 221 uspace/srv/net/ethip/ethip_nic.c async_hangup(nic->sess);
nic 223 uspace/srv/net/ethip/ethip_nic.c ethip_nic_delete(nic);
nic 232 uspace/srv/net/ethip/ethip_nic.c static void ethip_nic_addr_changed(ethip_nic_t *nic, ipc_call_t *call)
nic 245 uspace/srv/net/ethip/ethip_nic.c eth_addr_decode(addr, &nic->mac_addr);
nic 246 uspace/srv/net/ethip/ethip_nic.c eth_addr_format(&nic->mac_addr, &saddr);
nic 251 uspace/srv/net/ethip/ethip_nic.c rc = iplink_ev_change_addr(&nic->iplink, &nic->mac_addr);
nic 261 uspace/srv/net/ethip/ethip_nic.c static void ethip_nic_received(ethip_nic_t *nic, ipc_call_t *call)
nic 267 uspace/srv/net/ethip/ethip_nic.c log_msg(LOG_DEFAULT, LVL_DEBUG, "ethip_nic_received() nic=%p", nic);
nic 279 uspace/srv/net/ethip/ethip_nic.c rc = ethip_received(&nic->iplink, data, size);
nic 287 uspace/srv/net/ethip/ethip_nic.c static void ethip_nic_device_state(ethip_nic_t *nic, ipc_call_t *call)
nic 295 uspace/srv/net/ethip/ethip_nic.c ethip_nic_t *nic = (ethip_nic_t *)arg;
nic 310 uspace/srv/net/ethip/ethip_nic.c ethip_nic_addr_changed(nic, &call);
nic 313 uspace/srv/net/ethip/ethip_nic.c ethip_nic_received(nic, &call);
nic 316 uspace/srv/net/ethip/ethip_nic.c ethip_nic_device_state(nic, &call);
nic 342 uspace/srv/net/ethip/ethip_nic.c list_foreach(ethip_nic_list, link, ethip_nic_t, nic) {
nic 344 uspace/srv/net/ethip/ethip_nic.c if (nic->iplink_sid == iplink_sid) {
nic 345 uspace/srv/net/ethip/ethip_nic.c log_msg(LOG_DEFAULT, LVL_DEBUG, "ethip_nic_find_by_iplink_sid - found %p", nic);
nic 346 uspace/srv/net/ethip/ethip_nic.c return nic;
nic 354 uspace/srv/net/ethip/ethip_nic.c errno_t ethip_nic_send(ethip_nic_t *nic, void *data, size_t size)
nic 358 uspace/srv/net/ethip/ethip_nic.c rc = nic_send_frame(nic->sess, data, size);
nic 369 uspace/srv/net/ethip/ethip_nic.c static errno_t ethip_nic_setup_multicast(ethip_nic_t *nic)
nic 377 uspace/srv/net/ethip/ethip_nic.c list_foreach(nic->addr_list, link, ethip_link_addr_t, laddr) {
nic 384 uspace/srv/net/ethip/ethip_nic.c return nic_multicast_set_mode(nic->sess, NIC_MULTICAST_BLOCKED,
nic 395 uspace/srv/net/ethip/ethip_nic.c list_foreach(nic->addr_list, link, ethip_link_addr_t, laddr) {
nic 429 uspace/srv/net/ethip/ethip_nic.c errno_t rc = nic_multicast_set_mode(nic->sess, NIC_MULTICAST_LIST,
nic 436 uspace/srv/net/ethip/ethip_nic.c errno_t ethip_nic_addr_add(ethip_nic_t *nic, inet_addr_t *addr)
nic 444 uspace/srv/net/ethip/ethip_nic.c list_append(&laddr->link, &nic->addr_list);
nic 446 uspace/srv/net/ethip/ethip_nic.c return ethip_nic_setup_multicast(nic);
nic 449 uspace/srv/net/ethip/ethip_nic.c errno_t ethip_nic_addr_remove(ethip_nic_t *nic, inet_addr_t *addr)
nic 453 uspace/srv/net/ethip/ethip_nic.c ethip_link_addr_t *laddr = ethip_nic_addr_find(nic, addr);
nic 460 uspace/srv/net/ethip/ethip_nic.c return ethip_nic_setup_multicast(nic);
nic 463 uspace/srv/net/ethip/ethip_nic.c ethip_link_addr_t *ethip_nic_addr_find(ethip_nic_t *nic,
nic 468 uspace/srv/net/ethip/ethip_nic.c list_foreach(nic->addr_list, link, ethip_link_addr_t, laddr) {
HelenOS homepage, sources at GitHub