Changes in uspace/srv/net/nil/eth/eth.c [1bc35b5:6d8455d] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/net/nil/eth/eth.c
r1bc35b5 r6d8455d 814 814 } 815 815 816 static int eth_received(nic_device_id_t device_id)817 {818 void *data;819 size_t size;820 int rc;821 822 rc = async_data_write_accept(&data, false, 0, 0, 0, &size);823 if (rc != EOK)824 return rc;825 826 packet_t *packet = packet_get_1_remote(eth_globals.net_sess, size);827 if (packet == NULL)828 return ENOMEM;829 830 void *pdata = packet_suffix(packet, size);831 memcpy(pdata, data, size);832 free(data);833 834 return nil_received_msg_local(device_id, packet);835 }836 837 816 static int eth_addr_changed(nic_device_id_t device_id) 838 817 { … … 947 926 return EOK; 948 927 case NET_NIL_RECEIVED: 949 rc = eth_received(IPC_GET_ARG1(*call)); 928 rc = packet_translate_remote(eth_globals.net_sess, &packet, 929 IPC_GET_ARG2(*call)); 930 if (rc == EOK) 931 rc = nil_received_msg_local(IPC_GET_ARG1(*call), packet); 932 950 933 async_answer_0(callid, (sysarg_t) rc); 951 934 return rc;
Note:
See TracChangeset
for help on using the changeset viewer.