DPDK patches and discussions
 help / color / Atom feed
* [dpdk-dev] vtap0 device creation (bug)?
@ 2019-11-08 23:44 Stephen Hemminger
  2019-11-11  8:15 ` Tiwei Bie
  0 siblings, 1 reply; 2+ messages in thread
From: Stephen Hemminger @ 2019-11-08 23:44 UTC (permalink / raw)
  To: Maxime Coquelin, Tiwei Bie, Zhihong Wang; +Cc: dev

When I create a virtio-user device with rte_hotplug it creates a kernel device (ie vtap0).
This is normal an the device has ifindex N.

But later when device is configured an started the original vtap0 device is deleted
and a new one is created (with ifindex N+1).  This seems like a bug, if nothing
else it unnecessary overhead and link flapping for routing daemons.

Noticed only while tracking down a bug where after vtap was created the
address was being set, but then disappearing.

Is this intentional? Is it documented?

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [dpdk-dev] vtap0 device creation (bug)?
  2019-11-08 23:44 [dpdk-dev] vtap0 device creation (bug)? Stephen Hemminger
@ 2019-11-11  8:15 ` Tiwei Bie
  0 siblings, 0 replies; 2+ messages in thread
From: Tiwei Bie @ 2019-11-11  8:15 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: Maxime Coquelin, Zhihong Wang, dev

On Fri, Nov 08, 2019 at 03:44:07PM -0800, Stephen Hemminger wrote:
> When I create a virtio-user device with rte_hotplug it creates a kernel device (ie vtap0).
> This is normal an the device has ifindex N.
> 
> But later when device is configured an started the original vtap0 device is deleted
> and a new one is created (with ifindex N+1).  This seems like a bug, if nothing
> else it unnecessary overhead and link flapping for routing daemons.
> 
> Noticed only while tracking down a bug where after vtap was created the
> address was being set, but then disappearing.
> 
> Is this intentional? Is it documented?

Thanks for catching this.
I think it's caused by the fact that tapfds will be closed
each time when the queue pairs are disabled [1]. We may need
a way to keep tapfds open to fix it.

[1] https://github.com/DPDK/dpdk/blob/6bbc5a923625/drivers/net/virtio/virtio_user/vhost_kernel.c#L333-L338

Thanks,
Tiwei

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-08 23:44 [dpdk-dev] vtap0 device creation (bug)? Stephen Hemminger
2019-11-11  8:15 ` Tiwei Bie

DPDK patches and discussions

Archives are clonable:
	git clone --mirror http://inbox.dpdk.org/dev/0 dev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dev dev/ http://inbox.dpdk.org/dev \
		dev@dpdk.org
	public-inbox-index dev


Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.dev


AGPL code for this site: git clone https://public-inbox.org/ public-inbox