From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists1p.gnu.org (lists1p.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 0DB3CC624D3 for ; Fri, 4 Sep 2026 20:02:22 +0000 (UTC) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists1p.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1x2a3n-0005xs-7h; Fri, 04 Sep 2026 15:58:51 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists1p.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1x2a3c-0005gv-MG for qemu-devel@nongnu.org; Fri, 04 Sep 2026 15:58:40 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.129.124]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1x2a3b-0007ru-3n for qemu-devel@nongnu.org; Fri, 04 Sep 2026 15:58:40 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1788551918; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=wA5ZYh8MpPrdHBifS5Sy8EfpUvGUk61xfShZ6xpVkIk=; b=FefUj7MVK6Bc9VPtacRDWaOhYUvo/0z47lyct21Y+SLVWnO7yRvFZoGW28IDYTvnRsurwq Q0OOeYh9KIXOjVDippw8J7Wze8xrcf0JD/fHaCaOzX0XmmjDOfL9/mm2SiULKl1RZKiYsj IRroYueB4ptAx0NH334IbjRJyjQhWi0= Received: from mx-prod-mc-05.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-357-765msNDrOTWNPddZSZdkFQ-1; Fri, 04 Sep 2026 15:58:34 -0400 X-MC-Unique: 765msNDrOTWNPddZSZdkFQ-1 X-Mimecast-MFC-AGG-ID: 765msNDrOTWNPddZSZdkFQ_1788551913 Received: from mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.12]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-05.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id CC60E18D6358; Fri, 4 Sep 2026 19:58:33 +0000 (UTC) Received: from localhost (headnet05.pony-001.prod.iad2.dc.redhat.com [10.2.32.117]) by mx-prod-int-03.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id B0ED61955F0D; Fri, 4 Sep 2026 19:58:32 +0000 (UTC) From: =?utf-8?q?Marc-Andr=C3=A9_Lureau?= Date: Fri, 04 Sep 2026 23:57:50 +0400 Subject: [PATCH v4 07/75] qom: add qapi_type field to ObjectProperty MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Message-Id: <20260904-qom-qapi-v4-7-a985f168e938@redhat.com> References: <20260904-qom-qapi-v4-0-a985f168e938@redhat.com> In-Reply-To: <20260904-qom-qapi-v4-0-a985f168e938@redhat.com> To: qemu-devel@nongnu.org Cc: Markus Armbruster , Paolo Bonzini , =?utf-8?q?Daniel_P=2E_Berrang=C3=A9?= , =?utf-8?q?Marc-Andr=C3=A9_Lureau?= , Michael Roth , Pierrick Bouvier , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Developer-Signature: v=1; a=openpgp-sha256; l=1476; i=marcandre.lureau@redhat.com; h=from:subject:message-id; bh=rBD21kRNCndFYKRVvLYoL4BXy2V04K02YlZGAo0wzbo=; b=owEBbQKS/ZANAwAKAdro4Ql1lpzlAcsmYgBqmyLIDJzBTlZ4gA0G5vw6qppSU2IsAuGFk5RS8 9pI8sz+r3yJAjMEAAEKAB0WIQSHqb2TP4fGBtJ29i3a6OEJdZac5QUCapsiyAAKCRDa6OEJdZac 5aXfD/9HmV1kikj7tiH/YtVFasTsbncoTk5SeFaG8ScOP+Sxn4w1nwdni8Y6wBOt5ywh4EFD6LB LtP9FrxEBxk5opEYiL75UDUUtZxieY81Ssj0/q5HPDEVM5tZHVIdOamahZ0Xw07RYviYGIM/0fC Jsue4dTPwfHxLIbfdof5qYK5IBq6PJGHgRqeAiCbQcbF5AojCekfiOaePRNoIoAPFrgQhSmb4ED orAv55DZYH9uSGg9cQ9N69klex80dAf74DhRiIJQmKK+FdXVQubOdlYE3IlqwxuXJjDX9CjmCEf VBT+SJp57uAzW84PHGaiNCMwzQ7AkIrNU+rpI8e9wDR8T15Q2fa5ReKNNOf67H/L9k95kgBoQSS mm5OXLFy4wwaTcxnlrSlNGFTUcC/ZrlWe4TCL/7xaUu1RweOLJs/DXfwkXxpB5jLW/Zx1lonHvt voK1s6GVfR26oKjMa51xGf+412SsdLUG3eNOF3AQxjQNpHCRvvUMrQKbPQBBiGt1wEsSUu66Ff8 uWvW4Q5rXx1WTFokG/LILpm/qiTBkY2UZVJnmqj1em7cze/qwBc51XZAXAFb2r/kA3I5qVcFp2o m8S2X3JvBU3ime4p1TyR6sezy9RBWgBXAU6kjI+Q6g+9XMqwtoXwlHz1JKMbh5zffb3oUPclRQc bHj34d0vTQ4vN/g== X-Developer-Key: i=marcandre.lureau@redhat.com; a=openpgp; fpr=87A9BD933F87C606D276F62DDAE8E10975969CE5 X-Scanned-By: MIMEDefang 3.0 on 10.30.177.12 Received-SPF: pass client-ip=170.10.129.124; envelope-from=marcandre.lureau@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: 12 X-Spam_score: 1.2 X-Spam_bar: + X-Spam_report: (1.2 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-0.001, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=0.001, RCVD_IN_SBL_CSS=3.335, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: qemu development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Add a const pointer to QAPITypeInfo in ObjectProperty. NULL for now, but future patches will add means to make it non-null. The QAPITypeInfo will then be used by QOM introspection to tie the property to a QAPI type. Signed-off-by: Marc-André Lureau --- include/qom/object.h | 2 ++ qom/object.c | 1 + 2 files changed, 3 insertions(+) diff --git a/include/qom/object.h b/include/qom/object.h index 7ecd0f210fb6..7c7e69a2a1bb 100644 --- a/include/qom/object.h +++ b/include/qom/object.h @@ -15,6 +15,7 @@ #define QEMU_OBJECT_H #include "qapi/qapi-builtin-types.h" +#include "qapi/qapi-type-info.h" #include "qemu/module.h" struct TypeImpl; @@ -91,6 +92,7 @@ struct ObjectProperty char *name; char *type; char *description; + const QAPITypeInfo *qapi_type; ObjectPropertyAccessor *get; ObjectPropertyAccessor *set; ObjectPropertyResolve *resolve; diff --git a/qom/object.c b/qom/object.c index b1834a57cc9b..f782e21f1a30 100644 --- a/qom/object.c +++ b/qom/object.c @@ -3112,6 +3112,7 @@ object_property_add_alias(Object *obj, const char *name, property_release_alias, prop); op->resolve = property_resolve_alias; + op->qapi_type = target_prop->qapi_type; if (target_prop->defval) { op->defval = qobject_ref(target_prop->defval); } -- 2.55.0.543.g5ebe2ebe4ea8