diff options
author | Peter Maydell | 2011-05-20 17:50:00 +0200 |
---|---|---|
committer | Anthony Liguori | 2011-06-22 14:18:38 +0200 |
commit | 641f6eae757e5b2cf854fec14038ffd229e9adea (patch) | |
tree | 1b32fb73c2dfe487ad7af51d691b377cddbb1215 /net.c | |
parent | Revert "net: Improve the warnings for dubious command line option combinations" (diff) | |
download | qemu-641f6eae757e5b2cf854fec14038ffd229e9adea.tar.gz qemu-641f6eae757e5b2cf854fec14038ffd229e9adea.tar.xz qemu-641f6eae757e5b2cf854fec14038ffd229e9adea.zip |
net: Don't warn about the default network setup
Don't warn about the default network setup that you get if no command line
-net options are specified. There are two cases that we would otherwise
complain about:
(1) board doesn't support a NIC but the implicit "-net nic" requested one
(2) CONFIG_SLIRP not set, so the implicit "-net nic" sets up a nic that
isn't connected to anything
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Diffstat (limited to 'net.c')
-rw-r--r-- | net.c | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -1305,6 +1305,18 @@ void net_check_clients(void) VLANState *vlan; VLANClientState *vc; + /* Don't warn about the default network setup that you get if + * no command line -net or -netdev options are specified. There + * are two cases that we would otherwise complain about: + * (1) board doesn't support a NIC but the implicit "-net nic" + * requested one + * (2) CONFIG_SLIRP not set, in which case the implicit "-net nic" + * sets up a nic that isn't connected to anything. + */ + if (default_net) { + return; + } + QTAILQ_FOREACH(vlan, &vlans, next) { int has_nic = 0, has_host_dev = 0; |