aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--net/net.c4
-rw-r--r--qemu-deprecated.texi5
2 files changed, 9 insertions, 0 deletions
diff --git a/net/net.c b/net/net.c
index 2a3133990c..cdcd5cf634 100644
--- a/net/net.c
+++ b/net/net.c
@@ -984,6 +984,10 @@ static int net_client_init1(const void *object, bool is_netdev, Error **errp)
/* missing optional values have been initialized to "all bits zero" */
name = net->has_id ? net->id : net->name;
+ if (net->has_name) {
+ warn_report("The 'name' parameter is deprecated, use 'id' instead");
+ }
+
/* Map the old options to the new flat type */
switch (opts->type) {
case NET_LEGACY_OPTIONS_TYPE_NONE:
diff --git a/qemu-deprecated.texi b/qemu-deprecated.texi
index 2283fc52c3..4ac5c6a6f0 100644
--- a/qemu-deprecated.texi
+++ b/qemu-deprecated.texi
@@ -83,6 +83,11 @@ The 'file' driver for drives is no longer appropriate for character or host
devices and will only accept regular files (S_IFREG). The correct driver
for these file types is 'host_cdrom' or 'host_device' as appropriate.
+@subsection -net ...,name=@var{name} (since 3.1)
+
+The @option{name} parameter of the @option{-net} option is a synonym
+for the @option{id} parameter, which should now be used instead.
+
@section QEMU Machine Protocol (QMP) commands
@subsection block-dirty-bitmap-add "autoload" parameter (since 2.12.0)