All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: qemu-devel@nongnu.org
Cc: "Markus Armbruster" <armbru@redhat.com>,
	"Daniel P. Berrangé" <berrange@redhat.com>
Subject: [PATCH 6/8] qapi: reverse arg order in compat_policy_security_ok
Date: Wed, 28 Oct 2026 13:36:01 +0000	[thread overview]
Message-ID: <20261028133603.1893289-7-berrange@redhat.com> (raw)
In-Reply-To: <20261028133603.1893289-1-berrange@redhat.com>

Match the compat_policy_input_ok design more closely by having
the "relevant facts" being checked as the 2nd argument.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
---
 include/qapi/compat-policy.h | 2 +-
 qapi/qapi-util.c             | 2 +-
 qom/object.c                 | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/include/qapi/compat-policy.h b/include/qapi/compat-policy.h
index b7b543ffe74..53c96ce1a26 100644
--- a/include/qapi/compat-policy.h
+++ b/include/qapi/compat-policy.h
@@ -25,8 +25,8 @@ bool compat_policy_input_ok(const CompatPolicy *policy,
                             Error **errp);
 
 bool compat_policy_security_ok(const CompatPolicy *policy,
-                               const char *typename,
                                bool is_secure,
+                               const char *typename,
                                Error **errp);
 
 /*
diff --git a/qapi/qapi-util.c b/qapi/qapi-util.c
index f78d45a1a51..c845cadbdf2 100644
--- a/qapi/qapi-util.c
+++ b/qapi/qapi-util.c
@@ -64,8 +64,8 @@ bool compat_policy_input_ok(const CompatPolicy *policy,
 }
 
 bool compat_policy_security_ok(const CompatPolicy *policy,
-                               const char *typename,
                                bool is_secure,
+                               const char *typename,
                                Error **errp)
 {
     if (is_secure) {
diff --git a/qom/object.c b/qom/object.c
index ceb8e9eebec..30699f91279 100644
--- a/qom/object.c
+++ b/qom/object.c
@@ -3277,8 +3277,8 @@ void object_class_property_set_description(ObjectClass *klass,
 bool object_class_check_security(ObjectClass *klass, Error **errp)
 {
     return compat_policy_security_ok(&compat_policy,
-                                     object_class_get_name(klass),
                                      object_class_is_secure(klass),
+                                     object_class_get_name(klass),
                                      errp);
 }
 
-- 
2.56.0



  parent reply	other threads:[~2026-10-28 13:38 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-28 13:35 [PATCH 0/8] qapi: last minute improvements/changes to -compat insecure-types Daniel P. Berrangé
2026-10-28 13:35 ` [PATCH 1/8] qapi: make 'CompatPolicy' the first arg in compat_policy_input_ok Daniel P. Berrangé
2026-10-28 13:35 ` [PATCH 2/8] qapi: add 'warn' option to CompatPolicyInput Daniel P. Berrangé
2026-10-29  6:56   ` Markus Armbruster
2026-10-29 10:48     ` Daniel P. Berrangé
2026-10-28 13:35 ` [PATCH 3/8] qapi: rename 'insecure-types' to 'insecure-input' Daniel P. Berrangé
2026-10-28 13:35 ` [PATCH 4/8] qapi: drop CompatPolicySecurity and use CompatPolicyInput Daniel P. Berrangé
2026-10-29  6:15   ` Markus Armbruster
2026-10-29 10:48     ` Daniel P. Berrangé
2026-10-28 13:36 ` [PATCH 5/8] qapi: rename compat_policy_check_security method Daniel P. Berrangé
2026-10-28 13:36 ` Daniel P. Berrangé [this message]
2026-10-28 13:36 ` [PATCH 7/8] qemu-options: document -compat insecure-input parameter Daniel P. Berrangé
2026-10-29  6:52   ` Markus Armbruster
2026-10-29 10:56     ` Daniel P. Berrangé
2026-10-29 14:13       ` Markus Armbruster
2026-10-29 14:44         ` Daniel P. Berrangé
2026-10-28 13:36 ` [PATCH 8/8] qapi: print a message before aborting for -compat violations Daniel P. Berrangé

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=20261028133603.1893289-7-berrange@redhat.com \
    --to=berrange@redhat.com \
    --cc=armbru@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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.