qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] net: Next steps to deprecate -net (was: [RFC PATCH] Ena


From: Stefan Hajnoczi
Subject: Re: [Qemu-devel] net: Next steps to deprecate -net (was: [RFC PATCH] Enable vlans and dump for -netdev, too)
Date: Fri, 17 Jul 2015 09:16:25 +0100
User-agent: Mutt/1.5.23 (2014-03-12)

On Fri, Jul 17, 2015 at 08:53:08AM +0200, Thomas Huth wrote:
> On 05/26/2015 04:29 PM, Markus Armbruster wrote:
> > Stefan Hajnoczi <address@hidden> writes:
> [...]
> >> We thought the QEMU "vlan" concept would be dropped completely in the
> >> future, so it was never added to -netdev.  No patches to do that have
> >> been posted over the years, so I think it was more of a conceptual goal
> >> than a concrete requirement.
> > 
> > Well, patches to do that first need to replace the VLAN-only dump
> > feature.
> > 
> > To fully deprecate -net, we also have to replace -net nic for
> > configuring onboard NICs.
> > 
> > Prior discussion:
> > http://lists.nongnu.org/archive/html/qemu-devel/2013-02/msg03743.html
> > 
> > We haven't really tried either.
> 
> Ok, assuming that my "Network traffic dumping for -netdev devices" patch
> series is going to solve the dumping-for-netdev problem, how do we
> tackle the remaining problems that we have to solve before we can
> deprecate -net? Does anybody have a survey of the (onboard) NICs that
> can only be configured with -net but not with -device? Could they
> nowadays be changed to work with -device, too, or are there still major
> obstacles to solve first?

Take a look at nd_table[] and nb_nics.  That's the array of -net nic
devices.  The boards look into the array to grab NICs.

The default NIC is set in net_init_clients() as a "-net nic" option.

The weird thing about "-net nic" is that the device is not created in
net/net.c by the "-net nic" command-line option.  It just adds the
information to the nd_table[] array.

It's the board that has to instantiate nd_table[] entries.  For example,
pc_nic_init() adds devices for x86 guests.

That's about all I know or have thought about so far.  It would be nice
to get rid of -net but it will take some work and is a QEMU 3.0 feature
since it breaks backwards compatibility.

Attachment: pgppszYFXs_oN.pgp
Description: PGP signature


reply via email to

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