qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] directly inject packet in vrings and not use NetClient APIs


From: Anshul Makkar
Subject: [Qemu-devel] directly inject packet in vrings and not use NetClient APIs
Date: Wed, 19 Nov 2014 16:53:28 +0100

Hi,

Vhost-net backend tap, implements read and write polls to listen for packets in guest vrings (implemented through ioeventfds)  and gives direct access to the guest vrings.
While transmitting the packet up to VM, tap backend uses "qemu_send_packet_async"/ NetClient APIs to transmit the packets to the virtio-net driver in guest which then delivers the packet to the app running in VM.

Vhost-user backend behaves differently. It gives 3rd party user mode app direct access to guest vrings. The app can directly receive packets after the guest has posted in the vrings (throught kicks). Vhost-user has no read and write poll and no ways of transferring the packet up to the VM.

I have implemented a usermode app that is using vhost-user backend and gets direct access to the guest vrings. I am able to receive packets but when I post directly to vring and issue kick, packets fails to reach the guest. (ifconfig eth0 RX counter is unchanged. tcpdump also doesn't detect any packets.) . I don't want to use any NetClient APIs and want to directly inject packets into the guest vring.

Please can you share if my approach and understanding is correct.

Thanks
Anshul Makkar


reply via email to

[Prev in Thread] Current Thread [Next in Thread]