qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v3 0/7] Improvements and clean-ups related to -n


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [PATCH v3 0/7] Improvements and clean-ups related to -net
Date: Wed, 21 Feb 2018 12:34:06 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0

On 21/02/2018 11:41, Mark Cave-Ayland wrote:
> 1) Does the new -nic syntax support multiple on-board NICs? I remember
> seeing this on some of the ARM boards I was studying when trying to
> implement something similar for SPARC.

Yes, but they will be in different subnets if you do "-nic user -nic
user".  If you want to put them on the same trunk, what you want is
(cut-and-pasted from an offlist email from Thomas):

     -netdev user,id=slirp \
     -netdev hubport,id=port,netdev=slirp,hubid=0 \
     -nic hubport,hubid=0 \
     -nic hubport,hubid=0

We could make id and hubid optional (id was already optional in -net so
the logic is there already, see assign_name in net/net.c), giving the
much nicer:

     -netdev user,id=slirp \
     -netdev hubport,netdev=slirp \
     -nic hubport \
     -nic hubport

Thanks,

Paolo

> 2) Is it possible to provide a convenient wrapper function to handle the
> logic related to determining whether a specified NIC is on-board or not?




reply via email to

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