How the packet data reached the tap device?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I am looking through the virtio-net code in KVM-88. Trace along the
data send flow, I only find the code, responsible for getting data
from GuestOS's virtqueue and put it on VLAN packet send queue. But
when I try to find when the packet sent to tap device, which use
writev deliver data to host network, I am lost.

Following is the main functions called sequence I  collect.
1.virtio_net_handle_tx  -- the entry handler for send data
2. virtio_queue_set_notification -- mainly for notify switcher
3.virtio_net_flush_tx -- the really tx function
4.virtqueue_pop -- map data packet address in guest os
5.qemu_sendv_packet_async -- put the data into VLAN
6.qemu_enqueue_packet_iov -- copy sg data to packet struct
7.qemu_deliver_packet_iov -- traverse the VLAN send queue, and
callback function (receive) called. Then where is callback function
register? Is it  the function virtio_net_receive ? If so, I found none
code about calling tap device write.

Thanks,

-- 
BestRegards.
YangLiang
_____________________________________________
 Department of Computer Science .
 School of Electronics Engineering & Computer Science .
_____________________________________________
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux