Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'remotes/armbru/tags/pull-qapi-2021-03-1…
…6-v4' into staging QAPI patches patches for 2021-03-16 # gpg: Signature made Fri 19 Mar 2021 15:06:52 GMT # gpg: using RSA key 354BC8B3D7EB2A6B68674E5F3870B400EB918653 # gpg: issuer "armbru@redhat.com" # gpg: Good signature from "Markus Armbruster <armbru@redhat.com>" [full] # gpg: aka "Markus Armbruster <armbru@pond.sub.org>" [full] # Primary key fingerprint: 354B C8B3 D7EB 2A6B 6867 4E5F 3870 B400 EB91 8653 * remotes/armbru/tags/pull-qapi-2021-03-16-v4: qapi: New -compat deprecated-input=crash qapi: Implement deprecated-input=reject for QMP command arguments qapi: Implement deprecated-input=reject for QMP commands test-util-sockets: Add stub for monitor_set_cur() qapi: Implement deprecated-output=hide for QMP introspection monitor: Drop query-qmp-schema 'gen': false hack qapi: Implement deprecated-output=hide for QMP event data qapi: Implement deprecated-output=hide for QMP events qapi: Implement deprecated-output=hide for QMP command results qemu-options: New -compat to set policy for deprecated interfaces qemuutil: remove qemu_set_fd_handler duplicate symbol Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
- Loading branch information
Showing
31 changed files
with
549 additions
and
64 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
/* | ||
* Policy for handling "funny" management interfaces | ||
* | ||
* Copyright (C) 2020 Red Hat, Inc. | ||
* | ||
* Authors: | ||
* Markus Armbruster <armbru@redhat.com> | ||
* | ||
* This work is licensed under the terms of the GNU GPL, version 2 or | ||
* later. See the COPYING file in the top-level directory. | ||
*/ | ||
|
||
#ifndef QAPI_COMPAT_POLICY_H | ||
#define QAPI_COMPAT_POLICY_H | ||
|
||
#include "qapi/qapi-types-compat.h" | ||
|
||
extern CompatPolicy compat_policy; | ||
|
||
/* | ||
* Create a QObject input visitor for @obj for use with QMP | ||
* | ||
* This is like qobject_input_visitor_new(), except it obeys the | ||
* policy for handling deprecated management interfaces set with | ||
* -compat. | ||
*/ | ||
Visitor *qobject_input_visitor_new_qmp(QObject *obj); | ||
|
||
/* | ||
* Create a QObject output visitor for @obj for use with QMP | ||
* | ||
* This is like qobject_output_visitor_new(), except it obeys the | ||
* policy for handling deprecated management interfaces set with | ||
* -compat. | ||
*/ | ||
Visitor *qobject_output_visitor_new_qmp(QObject **result); | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# -*- Mode: Python -*- | ||
|
||
## | ||
# = Compatibility policy | ||
## | ||
|
||
## | ||
# @CompatPolicyInput: | ||
# | ||
# Policy for handling "funny" input. | ||
# | ||
# @accept: Accept silently | ||
# @reject: Reject with an error | ||
# @crash: abort() the process | ||
# | ||
# Since: 6.0 | ||
## | ||
{ 'enum': 'CompatPolicyInput', | ||
'data': [ 'accept', 'reject', 'crash' ] } | ||
|
||
## | ||
# @CompatPolicyOutput: | ||
# | ||
# Policy for handling "funny" output. | ||
# | ||
# @accept: Pass on unchanged | ||
# @hide: Filter out | ||
# | ||
# Since: 6.0 | ||
## | ||
{ 'enum': 'CompatPolicyOutput', | ||
'data': [ 'accept', 'hide' ] } | ||
|
||
## | ||
# @CompatPolicy: | ||
# | ||
# Policy for handling deprecated management interfaces. | ||
# | ||
# This is intended for testing users of the management interfaces. | ||
# | ||
# Limitation: covers only syntactic aspects of QMP, i.e. stuff tagged | ||
# with feature 'deprecated'. We may want to extend it to cover | ||
# semantic aspects, CLI, and experimental features. | ||
# | ||
# @deprecated-input: how to handle deprecated input (default 'accept') | ||
# @deprecated-output: how to handle deprecated output (default 'accept') | ||
# | ||
# Since: 6.0 | ||
## | ||
{ 'struct': 'CompatPolicy', | ||
'data': { '*deprecated-input': 'CompatPolicyInput', | ||
'*deprecated-output': 'CompatPolicyOutput' } } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,6 +25,7 @@ qapi_all_modules = [ | |
'block-export', | ||
'char', | ||
'common', | ||
'compat', | ||
'control', | ||
'crypto', | ||
'dump', | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.