Changeset 2dac5a9 in mainline
- Timestamp:
- 2024-12-13T08:32:55Z (10 months ago)
- Children:
- 91042127
- Parents:
- a270026
- git-author:
- Nataliia Korop <n.corop08@…> (2024-02-24 19:54:31)
- git-committer:
- Nataliia Korop <n.corop08@…> (2024-12-13 08:32:55)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/nic/virtio-net/virtio-net.c
ra270026 r2dac5a9 43 43 44 44 #include <virtio-pci.h> 45 45 #include "pcapdump_iface.h" 46 #include "pcap_iface.h" 46 47 #define NAME "virtio-net" 47 48 … … 97 98 if (frame) { 98 99 memcpy(frame->data, &hdr[1], len - sizeof(*hdr)); 100 pcapdump_packet(nic_get_pcap_iface(nic), frame->data, frame->size); 99 101 nic_received_frame(nic, frame); 100 102 } else { … … 357 359 /* Copy packet data into the buffer just past the header */ 358 360 memcpy(&hdr[1], data, size); 359 361 pcapdump_packet(nic_get_pcap_iface(nic), data, size); 360 362 /* 361 363 * Set the descriptor, put it into the virtqueue and notify the device … … 437 439 ddf_dev_get_name(dev)); 438 440 441 errno_t pcap_rc = pcapdump_init(nic_get_pcap_iface(nic)); 442 443 if (pcap_rc != EOK) { 444 printf("Failed creating pcapdump port\n"); 445 } 446 rc = ddf_fun_add_to_category(fun, "pcap"); 447 if (rc != EOK) 448 goto unbind; 449 439 450 return EOK; 440 451
Note:
See TracChangeset
for help on using the changeset viewer.