qapi/qom: Drop deprecated 'props' from object-add
authorKevin Wolf <kwolf@redhat.com>
Fri, 27 Nov 2020 17:11:02 +0000 (18:11 +0100)
committerKevin Wolf <kwolf@redhat.com>
Fri, 19 Mar 2021 09:17:12 +0000 (10:17 +0100)
The option has been deprecated in QEMU 5.0, remove it.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Acked-by: Paolo Bonzini <pbonzini@redhat.com>
Acked-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
docs/system/deprecated.rst
docs/system/removed-features.rst
qapi/qom.json
qom/qom-qmp-cmds.c

index d5e80d66eb78901bbff53f5294e89aa2ed75affc..491daf43afe38e6f244d4f6357bcc8f25b454f71 100644 (file)
@@ -186,11 +186,6 @@ Use argument value ``null`` instead.
 
 Use arguments ``base-node`` and ``top-node`` instead.
 
-``object-add`` option ``props`` (since 5.0)
-'''''''''''''''''''''''''''''''''''''''''''
-
-Specify the properties for the object as top-level arguments instead.
-
 ``nbd-server-add`` and ``nbd-server-remove`` (since 5.2)
 ''''''''''''''''''''''''''''''''''''''''''''''''''''''''
 
index bff16b7b05d2a59dcaa4350df68c0e2599d632dd..d0244fb22e25fb9dc8fa6f21ae2723b46606b0de 100644 (file)
@@ -143,6 +143,11 @@ field of the ``BlockDeviceInfo`` struct should be used instead, which is the
 type of the ``inserted`` field in query-block replies, as well as the
 type of array items in query-named-block-nodes.
 
+``object-add`` option ``props`` (removed in 6.0)
+''''''''''''''''''''''''''''''''''''''''''''''''
+
+Specify the properties for the object as top-level arguments instead.
+
 Human Monitor Protocol (HMP) commands
 -------------------------------------
 
index 0b0b92944ba0376a79adce0a17b5b761df80c3db..96c91c1faf6b55e173fbbed6d52ec4558cf2b965 100644 (file)
 #
 # @id: the name of the new object
 #
-# @props: a dictionary of properties to be passed to the backend. Deprecated
-#         since 5.0, specify the properties on the top level instead. It is an
-#         error to specify the same option both on the top level and in @props.
-#
 # Additional arguments depend on qom-type and are passed to the backend
 # unchanged.
 #
 #
 ##
 { 'command': 'object-add',
-  'data': {'qom-type': 'str', 'id': 'str', '*props': 'any'},
+  'data': {'qom-type': 'str', 'id': 'str'},
   'gen': false } # so we can get the additional arguments
 
 ##
index b40ac39f3008c814e1168d8f89f684f06d40aa71..19fd5e117f034783911116b7fe1292150b33488e 100644 (file)
@@ -225,27 +225,6 @@ ObjectPropertyInfoList *qmp_qom_list_properties(const char *typename,
 
 void qmp_object_add(QDict *qdict, QObject **ret_data, Error **errp)
 {
-    QObject *props;
-    QDict *pdict;
-
-    props = qdict_get(qdict, "props");
-    if (props) {
-        pdict = qobject_to(QDict, props);
-        if (!pdict) {
-            error_setg(errp, QERR_INVALID_PARAMETER_TYPE, "props", "dict");
-            return;
-        }
-        qobject_ref(pdict);
-        qdict_del(qdict, "props");
-        qdict_join(qdict, pdict, false);
-        if (qdict_size(pdict) != 0) {
-            error_setg(errp, "Option in 'props' conflicts with top level");
-            qobject_unref(pdict);
-            return;
-        }
-        qobject_unref(pdict);
-    }
-
     user_creatable_add_dict(qdict, false, errp);
 }