From: Stefan Reiter <s.reiter@proxmox.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [PATCH v3 qemu 1/2] PVE: add query_proxmox_support QMP command
Date: Wed, 8 Jul 2020 11:57:53 +0200 [thread overview]
Message-ID: <20200708095754.14429-1-s.reiter@proxmox.com> (raw)
Generic interface for future use, currently used for PBS and
dirty-bitmap backup support.
Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
---
v2:
* include 'pbs' feature
pve-backup.c | 8 ++++++++
qapi/block-core.json | 24 ++++++++++++++++++++++++
2 files changed, 32 insertions(+)
diff --git a/pve-backup.c b/pve-backup.c
index 46191bb328..d90010a4fe 100644
--- a/pve-backup.c
+++ b/pve-backup.c
@@ -1044,3 +1044,11 @@ BackupStatus *qmp_query_backup(Error **errp)
return info;
}
+
+ProxmoxSupportStatus *qmp_query_proxmox_support(Error **errp)
+{
+ ProxmoxSupportStatus *ret = g_malloc0(sizeof(*ret));
+ ret->pbs = true;
+ ret->pbs_dirty_bitmap = true;
+ return ret;
+}
diff --git a/qapi/block-core.json b/qapi/block-core.json
index 2c83734b04..d04d5e9f48 100644
--- a/qapi/block-core.json
+++ b/qapi/block-core.json
@@ -861,6 +861,30 @@
##
{ 'command': 'backup-cancel' }
+##
+# @ProxmoxSupportStatus:
+#
+# Contains info about supported features added by Proxmox.
+#
+# @pbs: True if backing up to Proxmox Backup Server is supported.
+#
+# @pbs-dirty-bitmap: True if dirty-bitmap-incremental backups to PBS are
+# supported.
+#
+##
+{ 'struct': 'ProxmoxSupportStatus',
+ 'data': { 'pbs': 'bool', 'pbs-dirty-bitmap': 'bool' } }
+
+##
+# @query-proxmox-support:
+#
+# Returns information about supported features added by Proxmox.
+#
+# Returns: @ProxmoxSupportStatus
+#
+##
+{ 'command': 'query-proxmox-support', 'returns': 'ProxmoxSupportStatus' }
+
##
# @BlockDeviceTimedStats:
#
--
2.20.1
next reply other threads:[~2020-07-08 9:58 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-08 9:57 Stefan Reiter [this message]
2020-07-08 9:57 ` [pve-devel] [PATCH v3 qemu-server 2/2] backup: detect PBS features and use only supported Stefan Reiter
2020-07-09 11:54 ` [pve-devel] applied: Re: [PATCH v3 qemu 1/2] PVE: add query_proxmox_support QMP command Thomas Lamprecht
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200708095754.14429-1-s.reiter@proxmox.com \
--to=s.reiter@proxmox.com \
--cc=pve-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.