[dpdk-dev] [PATCH v2 5/7] net/virtio_user: add vhost kernel support

Tan, Jianfeng jianfeng.tan at intel.com
Wed Jan 11 03:30:46 CET 2017

Hi Jason,

On 1/9/2017 12:39 PM, Jason Wang wrote:
>> +    if (!enable) {
>> +        if (dev->tapfds[pair_idx]) {
>> +            close(dev->tapfds[pair_idx]);
>> +            dev->tapfds[pair_idx] = -1;
>> +        }
>> +        return vhost_kernel_set_backend(vhostfd, -1);
> If this is used to for thing like ethtool -L in guest, we should use 

To make it clear, why we need to ioctl(..., TUNSETQUEUE, ...) here. 
According to Linux/Documentation/networking/tuntap.txt,
     "A new ioctl(TUNSETQUEUE) were introduced to enable or disable a 
queue. When
     calling it with IFF_DETACH_QUEUE flag, the queue were disabled. And 
     calling it with IFF_ATTACH_QUEUE flag, the queue were enabled. The 
queue were
     enabled by default after it was created through TUNSETIFF."

As it's enabled by default, do you still see the necessity to call it 


More information about the dev mailing list