The "size" property uses visit_type_size, not visit_type_int. The
"host-nodes" property uses visit_type_uint16List, not visit_type_int.

Fixes: e62834ca62a8 ("hostmem: Register TYPE_MEMORY_BACKEND properties as class 
properties")
Reviewed-by: Mark Cave-Ayland <[email protected]>
Signed-off-by: Marc-André Lureau <[email protected]>
---
 backends/hostmem.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/backends/hostmem.c b/backends/hostmem.c
index 5dd5fb155c47..02846b597d31 100644
--- a/backends/hostmem.c
+++ b/backends/hostmem.c
@@ -539,13 +539,13 @@ host_memory_backend_class_init(ObjectClass *oc, const 
void *data)
         object_property_allow_set_link, OBJ_PROP_LINK_STRONG);
     object_class_property_set_description(oc, "prealloc-context",
         "Context to use for creating CPU threads for preallocation");
-    object_class_property_add(oc, "size", "int",
+    object_class_property_add(oc, "size", "size",
         host_memory_backend_get_size,
         host_memory_backend_set_size,
         NULL, NULL);
     object_class_property_set_description(oc, "size",
         "Size of the memory region (ex: 500M)");
-    object_class_property_add(oc, "host-nodes", "int",
+    object_class_property_add(oc, "host-nodes", "[uint16]",
         host_memory_backend_get_host_nodes,
         host_memory_backend_set_host_nodes,
         NULL, NULL);

-- 
2.55.0.543.g5ebe2ebe4ea8


Reply via email to