From nobody Fri Dec 12 14:07:48 2025 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass header.i=@intel.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass(p=none dis=none) header.from=intel.com ARC-Seal: i=1; a=rsa-sha256; t=1764693707; cv=none; d=zohomail.com; s=zohoarc; b=Sz6cnaqOmihZY0r2LE3RsBGDUo+/X2Dj5DugUTUBHQfLFeNc67xgjViJzzgIN5CB9Oi66X6aH/eIR6Ztsq6GDkpycg5ti0jALk39VpvQUwrpce0zDrYcEgQSgabdj8cYMfKdoif0nQ8uJBdA1Fx5PngLbwMhwYdVS21CVMDlO8Q= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1764693707; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=e9+8qmuZpg0DehQTgkOFK4FDYxm/f3otODecthCuhL8=; b=bzNxZfW/UCQPqsU1zcBdPvHlNEfktS9G2qQPnjaFLCHNuTYDMNcyV0/1HpU0XwDV84l3AQeCUlxMe5XG0SEReH7imiDN8i7wlncS5Dg331usR1TegUiRDb6wXLZni9cLXRzVH6ehsUOc/YRYrnnoLzRsbIHqqXYZeIFPEmYDNjM= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=@intel.com; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1764693707666842.9116680281605; Tue, 2 Dec 2025 08:41:47 -0800 (PST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1vQTQh-0000xU-A0; Tue, 02 Dec 2025 11:40:43 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1vQTQX-0000wq-RK for qemu-devel@nongnu.org; Tue, 02 Dec 2025 11:40:34 -0500 Received: from mgamail.intel.com ([192.198.163.17]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1vQTQW-0001lq-0b for qemu-devel@nongnu.org; Tue, 02 Dec 2025 11:40:33 -0500 Received: from orviesa001.jf.intel.com ([10.64.159.141]) by fmvoesa111.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 02 Dec 2025 08:40:29 -0800 Received: from liuzhao-optiplex-7080.sh.intel.com ([10.239.160.39]) by orviesa001.jf.intel.com with ESMTP; 02 Dec 2025 08:40:26 -0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1764693631; x=1796229631; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=Ri+hE0aEh63QaQ4qr99LpLC5VPDanP5Ow2vhQA4wQY4=; b=ZQEles1fx1bj9wKn7G3WH/FjpM3qGxjfCWDi1KeCrpp8u+wnp5WtSpwd mFB7W054a8R4qpp5OXlOx9Qc51HdCoXA4xdEyFq8fAUyccP7j3EHWT83Z oTaty8MrefP572eVMRYCNkoArZfnlMBL4fiJbiXug0fUOYZcSinF0CJIi 8IRwaS8tQ4VxZuilS6ZGnUkbFhSSY6HvW3fFKeGhHr8n1PP/Q1ODtoVzy YaVtOFqJhb85HfK5/iuhnuilM1yqkjHMUQ+4dZ+GjBf/VYZD81D0I9+/T Nhf5boBPAmhLpXEWiVxI/ug4v0WqG7/WaGVQbfAmRlYToTlQTjNd660F1 g==; X-CSE-ConnectionGUID: g5yqNmrXSgSgTocTNlBW5g== X-CSE-MsgGUID: DAANyP1DQs+FDJq/cVOGgg== X-IronPort-AV: E=McAfee;i="6800,10657,11630"; a="66555296" X-IronPort-AV: E=Sophos;i="6.20,243,1758610800"; d="scan'208";a="66555296" X-CSE-ConnectionGUID: PWHPbr76TMmUfIXFdpdFPg== X-CSE-MsgGUID: 1maLxthjSC6dnbTfwtI+ZA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.20,243,1758610800"; d="scan'208";a="231751216" From: Zhao Liu To: Paolo Bonzini , =?UTF-8?q?Daniel=20P=20=2E=20Berrang=C3=A9?= , Eduardo Habkost , Markus Armbruster , Thomas Huth , Igor Mammedov , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Cc: qemu-devel@nongnu.org, Peter Maydell , "Michael S . Tsirkin" , BALATON Zoltan , Mark Cave-Ayland , devel@lists.libvirt.org, Zhao Liu Subject: [RFC 01/10] qom: Rename ObjectPropertyFlags to ObjectPropertyAccessorFlags Date: Wed, 3 Dec 2025 01:04:53 +0800 Message-Id: <20251202170502.3228625-2-zhao1.liu@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20251202170502.3228625-1-zhao1.liu@intel.com> References: <20251202170502.3228625-1-zhao1.liu@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=192.198.163.17; envelope-from=zhao1.liu@intel.com; helo=mgamail.intel.com X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 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_MED=-2.3, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @intel.com) X-ZM-MESSAGEID: 1764693708911019200 Content-Type: text/plain; charset="utf-8" At present, ObjectPropertyFlags is used to select accessors and such flags won't be stored in ObjectProperty itself. So it's not proper to extend this ObjectPropertyFlags for "deprecated" or "internal" flags. Therefore, rename ObjectPropertyFlags to ObjectPropertyAccessorFlags, and then the original name ObjectPropertyFlags can be used for other cases. Signed-off-by: Zhao Liu --- include/qom/object.h | 28 ++++++++++++++-------------- qom/object.c | 16 ++++++++-------- 2 files changed, 22 insertions(+), 22 deletions(-) diff --git a/include/qom/object.h b/include/qom/object.h index 26df6137b911..3f807a03f5aa 100644 --- a/include/qom/object.h +++ b/include/qom/object.h @@ -1846,14 +1846,14 @@ typedef enum { OBJ_PROP_FLAG_WRITE =3D 1 << 1, /* Automatically add a getter and a setter to the property */ OBJ_PROP_FLAG_READWRITE =3D (OBJ_PROP_FLAG_READ | OBJ_PROP_FLAG_WRITE), -} ObjectPropertyFlags; +} ObjectPropertyAccessorFlags; =20 /** * object_property_add_uint8_ptr: * @obj: the object to add a property to * @name: the name of the property * @v: pointer to value - * @flags: bitwise-or'd ObjectPropertyFlags + * @flags: bitwise-or'd ObjectPropertyAccessorFlags * * Add an integer property in memory. This function will add a * property of type 'uint8'. @@ -1861,20 +1861,20 @@ typedef enum { * Returns: The newly added property on success, or %NULL on failure. */ ObjectProperty *object_property_add_uint8_ptr(Object *obj, const char *nam= e, - const uint8_t *v, - ObjectPropertyFlags flags); + const uint8_t *v, + ObjectPropertyAccessorFlags flags); =20 ObjectProperty *object_class_property_add_uint8_ptr(ObjectClass *klass, const char *name, const uint8_t *v, - ObjectPropertyFlags flags); + ObjectPropertyAccessorFlags flags= ); =20 /** * object_property_add_uint16_ptr: * @obj: the object to add a property to * @name: the name of the property * @v: pointer to value - * @flags: bitwise-or'd ObjectPropertyFlags + * @flags: bitwise-or'd ObjectPropertyAccessorFlags * * Add an integer property in memory. This function will add a * property of type 'uint16'. @@ -1883,19 +1883,19 @@ ObjectProperty *object_class_property_add_uint8_ptr= (ObjectClass *klass, */ ObjectProperty *object_property_add_uint16_ptr(Object *obj, const char *na= me, const uint16_t *v, - ObjectPropertyFlags flags); + ObjectPropertyAccessorFlags flags); =20 ObjectProperty *object_class_property_add_uint16_ptr(ObjectClass *klass, const char *name, const uint16_t *v, - ObjectPropertyFlags flags); + ObjectPropertyAccessorFlags flag= s); =20 /** * object_property_add_uint32_ptr: * @obj: the object to add a property to * @name: the name of the property * @v: pointer to value - * @flags: bitwise-or'd ObjectPropertyFlags + * @flags: bitwise-or'd ObjectPropertyAccessorFlags * * Add an integer property in memory. This function will add a * property of type 'uint32'. @@ -1904,19 +1904,19 @@ ObjectProperty *object_class_property_add_uint16_pt= r(ObjectClass *klass, */ ObjectProperty *object_property_add_uint32_ptr(Object *obj, const char *na= me, const uint32_t *v, - ObjectPropertyFlags flags); + ObjectPropertyAccessorFlags flags); =20 ObjectProperty *object_class_property_add_uint32_ptr(ObjectClass *klass, const char *name, const uint32_t *v, - ObjectPropertyFlags flags); + ObjectPropertyAccessorFlags flag= s); =20 /** * object_property_add_uint64_ptr: * @obj: the object to add a property to * @name: the name of the property * @v: pointer to value - * @flags: bitwise-or'd ObjectPropertyFlags + * @flags: bitwise-or'd ObjectPropertyAccessorFlags * * Add an integer property in memory. This function will add a * property of type 'uint64'. @@ -1925,12 +1925,12 @@ ObjectProperty *object_class_property_add_uint32_pt= r(ObjectClass *klass, */ ObjectProperty *object_property_add_uint64_ptr(Object *obj, const char *na= me, const uint64_t *v, - ObjectPropertyFlags flags); + ObjectPropertyAccessorFlags flags); =20 ObjectProperty *object_class_property_add_uint64_ptr(ObjectClass *klass, const char *name, const uint64_t *v, - ObjectPropertyFlags flags); + ObjectPropertyAccessorFlags flag= s); =20 /** * object_property_add_alias: diff --git a/qom/object.c b/qom/object.c index 4f32c1aba7d7..85d31bb64b36 100644 --- a/qom/object.c +++ b/qom/object.c @@ -2636,7 +2636,7 @@ static void property_set_uint64_ptr(Object *obj, Visi= tor *v, const char *name, ObjectProperty * object_property_add_uint8_ptr(Object *obj, const char *name, const uint8_t *v, - ObjectPropertyFlags flags) + ObjectPropertyAccessorFlags flags) { ObjectPropertyAccessor *getter =3D NULL; ObjectPropertyAccessor *setter =3D NULL; @@ -2656,7 +2656,7 @@ object_property_add_uint8_ptr(Object *obj, const char= *name, ObjectProperty * object_class_property_add_uint8_ptr(ObjectClass *klass, const char *name, const uint8_t *v, - ObjectPropertyFlags flags) + ObjectPropertyAccessorFlags flags) { ObjectPropertyAccessor *getter =3D NULL; ObjectPropertyAccessor *setter =3D NULL; @@ -2676,7 +2676,7 @@ object_class_property_add_uint8_ptr(ObjectClass *klas= s, const char *name, ObjectProperty * object_property_add_uint16_ptr(Object *obj, const char *name, const uint16_t *v, - ObjectPropertyFlags flags) + ObjectPropertyAccessorFlags flags) { ObjectPropertyAccessor *getter =3D NULL; ObjectPropertyAccessor *setter =3D NULL; @@ -2696,7 +2696,7 @@ object_property_add_uint16_ptr(Object *obj, const cha= r *name, ObjectProperty * object_class_property_add_uint16_ptr(ObjectClass *klass, const char *name, const uint16_t *v, - ObjectPropertyFlags flags) + ObjectPropertyAccessorFlags flags) { ObjectPropertyAccessor *getter =3D NULL; ObjectPropertyAccessor *setter =3D NULL; @@ -2716,7 +2716,7 @@ object_class_property_add_uint16_ptr(ObjectClass *kla= ss, const char *name, ObjectProperty * object_property_add_uint32_ptr(Object *obj, const char *name, const uint32_t *v, - ObjectPropertyFlags flags) + ObjectPropertyAccessorFlags flags) { ObjectPropertyAccessor *getter =3D NULL; ObjectPropertyAccessor *setter =3D NULL; @@ -2736,7 +2736,7 @@ object_property_add_uint32_ptr(Object *obj, const cha= r *name, ObjectProperty * object_class_property_add_uint32_ptr(ObjectClass *klass, const char *name, const uint32_t *v, - ObjectPropertyFlags flags) + ObjectPropertyAccessorFlags flags) { ObjectPropertyAccessor *getter =3D NULL; ObjectPropertyAccessor *setter =3D NULL; @@ -2756,7 +2756,7 @@ object_class_property_add_uint32_ptr(ObjectClass *kla= ss, const char *name, ObjectProperty * object_property_add_uint64_ptr(Object *obj, const char *name, const uint64_t *v, - ObjectPropertyFlags flags) + ObjectPropertyAccessorFlags flags) { ObjectPropertyAccessor *getter =3D NULL; ObjectPropertyAccessor *setter =3D NULL; @@ -2776,7 +2776,7 @@ object_property_add_uint64_ptr(Object *obj, const cha= r *name, ObjectProperty * object_class_property_add_uint64_ptr(ObjectClass *klass, const char *name, const uint64_t *v, - ObjectPropertyFlags flags) + ObjectPropertyAccessorFlags flags) { ObjectPropertyAccessor *getter =3D NULL; ObjectPropertyAccessor *setter =3D NULL; --=20 2.34.1