#
0165daae |
| 01-Jul-2020 |
Cindy Lu <lulu@redhat.com> |
net: introduce qemu_get_peer
This is a small function that can get the peer from given NetClientState and queue_index
Signed-off-by: Cindy Lu <lulu@redhat.com> Message-Id: <20200701145538.22333-2-l
net: introduce qemu_get_peer
This is a small function that can get the peer from given NetClientState and queue_index
Signed-off-by: Cindy Lu <lulu@redhat.com> Message-Id: <20200701145538.22333-2-lulu@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com> Acked-by: Jason Wang <jasowang@redhat.com>
show more ...
|
Revision tags: v4.2.1 |
|
#
71830d84 |
| 18-May-2020 |
Thomas Huth <thuth@redhat.com> |
net: Drop the NetLegacy structure, always use Netdev instead
Now that the "name" parameter is gone, there is hardly any difference between NetLegacy and Netdev anymore, so we can drop NetLegacy and
net: Drop the NetLegacy structure, always use Netdev instead
Now that the "name" parameter is gone, there is hardly any difference between NetLegacy and Netdev anymore, so we can drop NetLegacy and always use Netdev to simplify the code quite a bit.
The only two differences that were really left between Netdev and NetLegacy:
1) NetLegacy does not allow a "hubport" type. We can continue to block this with a simple check in net_client_init1() for this type.
2) The "id" parameter was optional in NetLegacy (and an internal id was chosen via assign_name() during initialization), but it is mandatory for Netdev. To avoid that the visitor code bails out here, we have to add an internal id to the QemuOpts already earlier now.
Signed-off-by: Thomas Huth <thuth@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
show more ...
|
#
9d903f30 |
| 18-May-2020 |
Thomas Huth <thuth@redhat.com> |
net: Drop the legacy "name" parameter from the -net option
It's been deprecated since QEMU v3.1, so it's time to finally remove it. The "id" parameter can simply be used instead.
Reviewed-by: Eric
net: Drop the legacy "name" parameter from the -net option
It's been deprecated since QEMU v3.1, so it's time to finally remove it. The "id" parameter can simply be used instead.
Reviewed-by: Eric Blake <eblake@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
show more ...
|
#
5fe19fb8 |
| 11-May-2020 |
Jason Wang <jasowang@redhat.com> |
net: use peer when purging queue in qemu_flush_or_purge_queue_packets()
The sender of packet will be checked in the qemu_net_queue_purge() but we use NetClientState not its peer when trying to purge
net: use peer when purging queue in qemu_flush_or_purge_queue_packets()
The sender of packet will be checked in the qemu_net_queue_purge() but we use NetClientState not its peer when trying to purge the incoming queue in qemu_flush_or_purge_packets(). This will trigger the assert in virtio_net_reset since we can't pass the sender check:
hw/net/virtio-net.c:533: void virtio_net_reset(VirtIODevice *): Assertion `!virtio_net_get_subqueue(nc)->async_tx.elem' failed. #9 0x55a33fa31b78 in virtio_net_reset hw/net/virtio-net.c:533:13 #10 0x55a33fc88412 in virtio_reset hw/virtio/virtio.c:1919:9 #11 0x55a341d82764 in virtio_bus_reset hw/virtio/virtio-bus.c:95:9 #12 0x55a341dba2de in virtio_pci_reset hw/virtio/virtio-pci.c:1824:5 #13 0x55a341db3e02 in virtio_pci_common_write hw/virtio/virtio-pci.c:1252:13 #14 0x55a33f62117b in memory_region_write_accessor memory.c:496:5 #15 0x55a33f6205e4 in access_with_adjusted_size memory.c:557:18 #16 0x55a33f61e177 in memory_region_dispatch_write memory.c:1488:16
Reproducer: https://www.mail-archive.com/qemu-devel@nongnu.org/msg701914.html
Fix by using the peer.
Reported-by: "Alexander Bulekov" <alxndr@bu.edu> Acked-by: Alexander Bulekov <alxndr@bu.edu> Fixes: ca77d85e1dbf9 ("net: complete all queued packets on VM stop") Cc: qemu-stable@nongnu.org Signed-off-by: Jason Wang <jasowang@redhat.com>
show more ...
|
#
0561dfac |
| 18-May-2020 |
Thomas Huth <thuth@redhat.com> |
net: Do not include a newline in the id of -nic devices
The '\n' sneaked in by accident here, an "id" string should really not contain a newline character at the end.
Fixes: 78cd6f7bf6b ('net: Add
net: Do not include a newline in the id of -nic devices
The '\n' sneaked in by accident here, an "id" string should really not contain a newline character at the end.
Fixes: 78cd6f7bf6b ('net: Add a new convenience option "--nic" ...') Signed-off-by: Thomas Huth <thuth@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20200518074352.23125-1-thuth@redhat.com> Signed-off-by: Laurent Vivier <laurent@vivier.eu>
show more ...
|
Revision tags: v5.0.0, v5.0.0-rc4, v5.0.0-rc3, v5.0.0-rc2, v5.0.0-rc1, v5.0.0-rc0 |
|
#
08712fcb |
| 17-Mar-2020 |
Eric Blake <eblake@redhat.com> |
net: Track netdevs in NetClientState rather than QemuOpt
As mentioned in the previous patch, our use of QemuOpt group "netdev" has two purposes: collect the CLI arguments, and serve as a witness for
net: Track netdevs in NetClientState rather than QemuOpt
As mentioned in the previous patch, our use of QemuOpt group "netdev" has two purposes: collect the CLI arguments, and serve as a witness for monitor hotplug actions. As the latter didn't use anything but an id, it felt rather unclean to have to touch QemuOpts at all when going through QMP, so let's instead track things with a bool field in NetClientState.
Suggested-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Eric Blake <eblake@redhat.com> Message-Id: <20200317201711.322764-3-eblake@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com>
show more ...
|
#
db2a380c |
| 17-Mar-2020 |
Eric Blake <eblake@redhat.com> |
net: Complete qapi-fication of netdev_add
We've had all the required pieces for doing a type-safe representation of netdev_add as a flat union for quite some time now (since 0e55c381f6 in v2.7.0, re
net: Complete qapi-fication of netdev_add
We've had all the required pieces for doing a type-safe representation of netdev_add as a flat union for quite some time now (since 0e55c381f6 in v2.7.0, released in 2016), but did not make the final switch to using it because of concern about whether a command-line regression in accepting "1" in place of 1 for integer arguments would be problematic. Back then, we did not have the deprecation cycle to allow us to make progress. But now that we have waited so long, other problems have crept in: for example, our desire to add qemu-storage-daemon is hampered by the inability to express net objects, and we are unable to introspect what we actually accept. Additionally, our round-trip through QemuOpts silently eats any argument that expands to an array, rendering dnssearch, hostfwd, and guestfwd useless through QMP:
{"execute": "netdev_add", "arguments": { "id": "netdev0", "type": "user", "dnssearch": [ { "str": "8.8.8.8" }, { "str": "8.8.4.4" } ]}}
So without further ado, let's turn on proper QAPI. netdev_add() was a trivial wrapper around net_client_init(), which did a few steps prior to calling net_client_init1(); with this patch, we now skip directly to net_client_init1(). In addition to fixing array parameters, the following additional differences occur:
- {"execute": "netdev_add", "arguments": {"type": "help"}} no longer attempts to print help to stdout and exit. Bug fix, broken in 547203ead4 'net: List available netdevs with "-netdev help"', v2.12.0.
- {"execute": "netdev_add", "arguments': {... "ipv6-net": "..." }} no longer attempts to desugar the undocumented ipv6-net magic string into the proper "ipv6-prefix" and "ipv6-prefixlen". Undocumented misfeature, introduced in commit 7aac531ef2 "qapi-schema, qemu-options & slirp: Adding Qemu options for IPv6 addresses", v2.6.0.
- {'execute':'netdev_add', 'arguments':{'id':'net2', 'type':'hubport', 'hubid':"2"}} {"error": {"class": "GenericError", "desc": "Invalid parameter type for 'hubid', expected: integer"}} Used to succeed: since our command line treats everything as strings, our not-so-round-trip conversion from QAPI -> QemuOpts -> QAPI lost the original typing and turned everything into a string; now that we skip the QemuOpts, the JSON input has to match the exact QAPI type. But this stricter QMP is desirable, and introspection is sufficient for any affected applications to make sure they use it correctly.
In qmp_netdev_add(), we still have to create a QemuOpts object so that qmp_netdev_del() will be able to remove a hotplugged network device; but the opts->head remains empty since we now manage all parsing through the QAPI object rather than QemuOpts; a separate patch will address the abuse of QemuOpts as a witness for whether a NetClientState is a netdev. In the meantime, our argument that we are okay requires auditing all uses of option group "netdev":
- qemu_netdev_opts: option group definition, empty .desc[] - CLI (CLI netdev parsing ends before monitors start, so while monitors can mess with CLI netdevs, CLI cannot mess with monitor netdevs): - main() case QEMU_OPTION_netdev: store CLI definition - main() case QEMU_OPTION_readconfig, case QEMU_OPTION_writeconfig: similar, dealing only with CLI - net_init_clients(): Pass CLI to net_client_init() - Monitor: - hmp_netdev_add(): straightforward parse into net_client_init() - qmp_netdev_add(): subject of this patch, used to add full object to option group, now just adds bare-bones id - qmp_netdev_del(), netdev_del_completion(): check the option group solely for id, as a 'is this a netdev' predicate
Reported-by: Alex Kirillov <lekiravi@yandex-team.ru> Signed-off-by: Eric Blake <eblake@redhat.com> Message-Id: <20200317201711.322764-2-eblake@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> [Commit message typo fixed] Signed-off-by: Markus Armbruster <armbru@redhat.com>
show more ...
|
Revision tags: v4.2.0, v4.2.0-rc5 |
|
#
33c9642f |
| 05-Dec-2019 |
Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> |
net/net: Clean up variable shadowing in net_client_init()
Variable int err in inner scope shadows Error *err in outer scope.
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> R
net/net: Clean up variable shadowing in net_client_init()
Variable int err in inner scope shadows Error *err in outer scope.
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20191205174635.18758-3-vsementsov@virtuozzo.com> Signed-off-by: Markus Armbruster <armbru@redhat.com>
show more ...
|
Revision tags: v4.2.0-rc4, v4.2.0-rc3, v4.2.0-rc2, v4.1.1, v4.2.0-rc1, v4.2.0-rc0, v4.0.1, v3.1.1.1, v4.1.0, v4.1.0-rc5 |
|
#
54d31236 |
| 12-Aug-2019 |
Markus Armbruster <armbru@redhat.com> |
sysemu: Split sysemu/runstate.h off sysemu/sysemu.h
sysemu/sysemu.h is a rather unfocused dumping ground for stuff related to the system-emulator. Evidence:
* It's included widely: in my "build ev
sysemu: Split sysemu/runstate.h off sysemu/sysemu.h
sysemu/sysemu.h is a rather unfocused dumping ground for stuff related to the system-emulator. Evidence:
* It's included widely: in my "build everything" tree, changing sysemu/sysemu.h still triggers a recompile of some 1100 out of 6600 objects (not counting tests and objects that don't depend on qemu/osdep.h, down from 5400 due to the previous two commits).
* It pulls in more than a dozen additional headers.
Split stuff related to run state management into its own header sysemu/runstate.h.
Touching sysemu/sysemu.h now recompiles some 850 objects. qemu/uuid.h also drops from 1100 to 850, and qapi/qapi-types-run-state.h from 4400 to 4200. Touching new sysemu/runstate.h recompiles some 500 objects.
Since I'm touching MAINTAINERS to add sysemu/runstate.h anyway, also add qemu/main-loop.h.
Suggested-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20190812052359.30071-30-armbru@redhat.com> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> [Unbreak OS-X build]
show more ...
|
#
a27bd6c7 |
| 12-Aug-2019 |
Markus Armbruster <armbru@redhat.com> |
Include hw/qdev-properties.h less
In my "build everything" tree, changing hw/qdev-properties.h triggers a recompile of some 2700 out of 6600 objects (not counting tests and objects that don't depend
Include hw/qdev-properties.h less
In my "build everything" tree, changing hw/qdev-properties.h triggers a recompile of some 2700 out of 6600 objects (not counting tests and objects that don't depend on qemu/osdep.h).
Many places including hw/qdev-properties.h (directly or via hw/qdev.h) actually need only hw/qdev-core.h. Include hw/qdev-core.h there instead.
hw/qdev.h is actually pointless: all it does is include hw/qdev-core.h and hw/qdev-properties.h, which in turn includes hw/qdev-core.h. Replace the remaining uses of hw/qdev.h by hw/qdev-properties.h.
While there, delete a few superfluous inclusions of hw/qdev-core.h.
Touching hw/qdev-properties.h now recompiles some 1200 objects.
Cc: Paolo Bonzini <pbonzini@redhat.com> Cc: "Daniel P. Berrangé" <berrange@redhat.com> Cc: Eduardo Habkost <ehabkost@redhat.com> Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Eduardo Habkost <ehabkost@redhat.com> Message-Id: <20190812052359.30071-22-armbru@redhat.com>
show more ...
|
Revision tags: v4.1.0-rc4, v3.1.1, v4.1.0-rc3, v4.1.0-rc2, v4.1.0-rc1, v4.1.0-rc0 |
|
#
4623027d |
| 17-May-2019 |
Stefano Garzarella <sgarzare@redhat.com> |
net: remove unused get_str_sep() function
Since the get_str_sep() function is no longer used in net/net.c, we can remove it.
Signed-off-by: Stefano Garzarella <sgarzare@redhat.com> Reviewed-by: Mar
net: remove unused get_str_sep() function
Since the get_str_sep() function is no longer used in net/net.c, we can remove it.
Signed-off-by: Stefano Garzarella <sgarzare@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
show more ...
|
#
add99347 |
| 17-May-2019 |
Stefano Garzarella <sgarzare@redhat.com> |
net: use g_strsplit() for parsing host address and port
Use the glib function to split host address and port in the parse_host_port() function.
Suggested-by: Markus Armbruster <armbru@redhat.com> S
net: use g_strsplit() for parsing host address and port
Use the glib function to split host address and port in the parse_host_port() function.
Suggested-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Stefano Garzarella <sgarzare@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
show more ...
|
#
c1112b2d |
| 17-May-2019 |
Stefano Garzarella <sgarzare@redhat.com> |
net: avoid using variable length array in net_client_init()
net_client_init() uses a variable length array to store the prefix of 'ipv6-net' parameter (e.g. if ipv6-net=fec0::0/64, the prefix is 'fe
net: avoid using variable length array in net_client_init()
net_client_init() uses a variable length array to store the prefix of 'ipv6-net' parameter (e.g. if ipv6-net=fec0::0/64, the prefix is 'fec0::0'). This patch introduces g_strsplit() to split the 'ipv6-net' parameter, so we can remove the variable length array.
Suggested-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Stefano Garzarella <sgarzare@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
show more ...
|
#
21c520d0 |
| 17-May-2019 |
Stefano Garzarella <sgarzare@redhat.com> |
net: fix assertion failure when ipv6-prefixlen is not a number
If 'ipv6-prefixlen' is not a number, the current behaviour produces an assertion failure: $ qemu-system-x86_64 -net user,ipv6-net=f
net: fix assertion failure when ipv6-prefixlen is not a number
If 'ipv6-prefixlen' is not a number, the current behaviour produces an assertion failure: $ qemu-system-x86_64 -net user,ipv6-net=feca::0/a qemu-system-x86_64: qemu/util/qemu-option.c:1175: qemu_opts_foreach: Assertion `!errp || !*errp' failed. Aborted (core dumped)
This patch fixes it, jumping to the end of the function when 'ipv6-prefixlen' is not a number, and printing the more friendly message: $ qemu-system-x86_64 -net user,ipv6-net=feca::0/a qemu-system-x86_64: Parameter 'ipv6-prefixlen' expects a number
Signed-off-by: Stefano Garzarella <sgarzare@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
show more ...
|
#
856dfd8a |
| 23-May-2019 |
Markus Armbruster <armbru@redhat.com> |
qemu-common: Move qemu_isalnum() etc. to qemu/ctype.h
Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20190523143508.25387-3-armbru@redhat.com> Reviewed-by: Richard Henderson <rich
qemu-common: Move qemu_isalnum() etc. to qemu/ctype.h
Signed-off-by: Markus Armbruster <armbru@redhat.com> Message-Id: <20190523143508.25387-3-armbru@redhat.com> Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
show more ...
|
Revision tags: v4.0.0 |
|
#
7b71e03a |
| 23-Apr-2019 |
Thomas Huth <thuth@redhat.com> |
net: Print output of "-net nic, model=help" to stdout instead of stderr
We are printing all other help output to stdout already (e.g. "-help", "-cpu help" and "-machine help" output). So the "-net n
net: Print output of "-net nic, model=help" to stdout instead of stderr
We are printing all other help output to stdout already (e.g. "-help", "-cpu help" and "-machine help" output). So the "-net nic,model=help" output should go to stdout instead of stderr, too. And while we're at it, also print the NICs line by line, like we do it e.g. with the "-cpu help" or "-M help" output, too.
Buglink: https://bugs.launchpad.net/qemu/+bug/1574327 Signed-off-by: Thomas Huth <thuth@redhat.com> Reviewed-by: Eric Blake <eblake@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <20190423160608.7519-1-thuth@redhat.com> Signed-off-by: Laurent Vivier <laurent@vivier.eu>
show more ...
|
Revision tags: v4.0.0-rc4, v3.0.1, v4.0.0-rc3, v4.0.0-rc2, v4.0.0-rc1, v4.0.0-rc0 |
|
#
56f41de7 |
| 14-Feb-2019 |
Paolo Bonzini <pbonzini@redhat.com> |
vhost-net-user: add stubs for when no virtio-net device is present
hw/net/vhost_net.c needs functions that are declared in net/vhost-user.c: the vhost-user code is always compiled into QEMU, only th
vhost-net-user: add stubs for when no virtio-net device is present
hw/net/vhost_net.c needs functions that are declared in net/vhost-user.c: the vhost-user code is always compiled into QEMU, only the constructor net_init_vhost_user is unreachable. Also, net/vhost-user.c needs functions declared in hw/virtio/vhost-stub.c even if no virtio device exists.
Break this dependency. First, add a minimal version of net/vhost-user.c, with no functionality and no dependency on vhost code. Second, #ifdef out the calls back to net/vhost-user.c from hw/net/vhost_net.c.
While at it, this patch fixes the CONFIG_VHOST_NET_USE*D* typo.
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Message-Id: <1543851204-41186-3-git-send-email-pbonzini@redhat.com> Reviewed-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Message-Id: <1550165756-21617-3-git-send-email-pbonzini@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
show more ...
|
#
625a526b |
| 17-Jan-2019 |
Marc-André Lureau <marcandre.lureau@redhat.com> |
slirp: improve send_packet() callback
Use a more descriptive name for the callback.
Reuse the SlirpWriteCb type. Wrap it to check that all data has been written.
Return a ssize_t for potential err
slirp: improve send_packet() callback
Use a more descriptive name for the callback.
Reuse the SlirpWriteCb type. Wrap it to check that all data has been written.
Return a ssize_t for potential error handling and data-loss reporting.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
show more ...
|
Revision tags: v3.1.0, v3.1.0-rc5 |
|
#
eae3eb3e |
| 06-Dec-2018 |
Paolo Bonzini <pbonzini@redhat.com> |
qemu/queue.h: simplify reverse access to QTAILQ
The new definition of QTAILQ does not require passing the headname, remove it.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
|
Revision tags: v3.1.0-rc4 |
|
#
25c01bd1 |
| 04-Dec-2018 |
Jason Wang <jasowang@redhat.com> |
net: drop too large packet early
We try to detect and drop too large packet (>INT_MAX) in 1592a9947036 ("net: ignore packet size greater than INT_MAX") during packet delivering. Unfortunately, this
net: drop too large packet early
We try to detect and drop too large packet (>INT_MAX) in 1592a9947036 ("net: ignore packet size greater than INT_MAX") during packet delivering. Unfortunately, this is not sufficient as we may hit another integer overflow when trying to queue such large packet in qemu_net_queue_append_iov():
- size of the allocation may overflow on 32bit - packet->size is integer which may overflow even on 64bit
Fixing this by moving the check to qemu_sendv_packet_async() which is the entrance of all networking codes and reduce the limit to NET_BUFSIZE to be more conservative. This works since:
- For the callers that call qemu_sendv_packet_async() directly, they only care about if zero is returned to determine whether to prevent the source from producing more packets. A callback will be triggered if peer can accept more then source could be enabled. This is usually used by high speed networking implementation like virtio-net or netmap. - For the callers that call qemu_sendv_packet() that calls qemu_sendv_packet_async() indirectly, they often ignore the return value. In this case qemu will just the drop packets if peer can't receive.
Qemu will copy the packet if it was queued. So it was safe for both kinds of the callers to assume the packet was sent.
Since we move the check from qemu_deliver_packet_iov() to qemu_sendv_packet_async(), it would be safer to make qemu_deliver_packet_iov() static to prevent any external user in the future.
This is a revised patch of CVE-2018-17963.
Cc: qemu-stable@nongnu.org Cc: Li Qiang <liq3ea@163.com> Fixes: 1592a9947036 ("net: ignore packet size greater than INT_MAX") Reported-by: Li Qiang <liq3ea@gmail.com> Reviewed-by: Li Qiang <liq3ea@gmail.com> Signed-off-by: Jason Wang <jasowang@redhat.com> Reviewed-by: Thomas Huth <thuth@redhat.com> Message-id: 20181204035347.6148-2-jasowang@redhat.com Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
show more ...
|
Revision tags: v3.1.0-rc3, v3.1.0-rc2, v3.1.0-rc1, v3.1.0-rc0, v3.0.0, v3.0.0-rc4, v2.12.1, v3.0.0-rc3, v3.0.0-rc2, v3.0.0-rc1, v3.0.0-rc0, v2.11.2 |
|
#
1592a994 |
| 30-May-2018 |
Jason Wang <jasowang@redhat.com> |
net: ignore packet size greater than INT_MAX
There should not be a reason for passing a packet size greater than INT_MAX. It's usually a hint of bug somewhere, so ignore packet size greater than INT
net: ignore packet size greater than INT_MAX
There should not be a reason for passing a packet size greater than INT_MAX. It's usually a hint of bug somewhere, so ignore packet size greater than INT_MAX in qemu_deliver_packet_iov()
CC: qemu-stable@nongnu.org Reported-by: Daniel Shapira <daniel@twistlock.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
show more ...
|
#
5fbba3d6 |
| 03-Sep-2018 |
Zhang Chen <zhangckid@gmail.com> |
filter: Add handle_event method for NetFilterClass
Filter needs to process the event of checkpoint/failover or other event passed by COLO frame.
Signed-off-by: zhanghailiang <zhang.zhanghailiang@hu
filter: Add handle_event method for NetFilterClass
Filter needs to process the event of checkpoint/failover or other event passed by COLO frame.
Signed-off-by: zhanghailiang <zhang.zhanghailiang@huawei.com> Signed-off-by: Zhang Chen <zhangckid@gmail.com> Signed-off-by: Zhang Chen <chen.zhang@intel.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
show more ...
|
#
101625a4 |
| 20-Sep-2018 |
Thomas Huth <thuth@redhat.com> |
net: Deprecate the "name" parameter of -net
In early times, network backends were specified by a "vlan" and "name" tuple. With the introduction of netdevs, the "name" was replaced by an "id" (which
net: Deprecate the "name" parameter of -net
In early times, network backends were specified by a "vlan" and "name" tuple. With the introduction of netdevs, the "name" was replaced by an "id" (which is supposed to be unique), but the "name" parameter stayed as an alias which could be used instead of "id". Unfortunately, we miss the duplication check for "name":
$ qemu-system-x86_64 -net user,name=n1 -net user,name=n1
... starts without an error, while "id" correctly complains:
$ qemu-system-x86_64 -net user,id=n1 -net user,id=n1 qemu-system-x86_64: -net user,id=n1: Duplicate ID 'n1' for net
Instead of trying to fix the code for the legacy "name" parameter, let's rather get rid of this old interface and deprecate the "name" parameter now - this will also be less confusing for the users in the long run.
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
show more ...
|
#
8b43f964 |
| 11-Jun-2018 |
Lin Ma <lma@suse.com> |
net: Fix a potential segfault
If user forgets to provide any backend types for '-netdev' in qemu CLI, It triggers seg fault.
e.g.
Expected: $ qemu -netdev id=net0 qemu-system-x86_64: Parameter 'ty
net: Fix a potential segfault
If user forgets to provide any backend types for '-netdev' in qemu CLI, It triggers seg fault.
e.g.
Expected: $ qemu -netdev id=net0 qemu-system-x86_64: Parameter 'type' is missing
Actual: $ qemu -netdev id=net0 Segmentation fault (core dumped)
Fixes: 547203ead4327 ("net: List available netdevs with "-netdev help") Reviewed-by: Thomas Huth <thuth@redhat.com> Cc: qemu-stable@nongnu.org Signed-off-by: Lin Ma <lma@suse.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
show more ...
|
#
af1a5c3e |
| 30-Apr-2018 |
Thomas Huth <thuth@redhat.com> |
net: Remove the deprecated "vlan" parameter
It's been marked as deprecated since QEMU v2.9.0, so that should have been enough time for everybody to either just drop unnecessary "vlan=0" parameters,
net: Remove the deprecated "vlan" parameter
It's been marked as deprecated since QEMU v2.9.0, so that should have been enough time for everybody to either just drop unnecessary "vlan=0" parameters, to switch to the modern -device + -netdev syntax for connecting guest NICs with host network backends, or to switch to the "hubport" netdev in case hubs are really wanted instead.
Buglink: https://bugs.launchpad.net/qemu/+bug/658904 Signed-off-by: Thomas Huth <thuth@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
show more ...
|