summary refs log tree commit diff stats
path: root/hw/vfio/common.c
diff options
context:
space:
mode:
authorZhenzhong Duan <zhenzhong.duan@intel.com>2024-05-07 14:42:46 +0800
committerCédric Le Goater <clg@redhat.com>2024-05-16 16:59:20 +0200
commit33e4c22fd1dd2aa1e1e6f45e8e89c9b961fb72d1 (patch)
treebf531ba32b9347457b5f63dbf51b8871783a7482 /hw/vfio/common.c
parent35b25cf40e4228e922cc9830bd61a7341623023c (diff)
downloadfocaccia-qemu-33e4c22fd1dd2aa1e1e6f45e8e89c9b961fb72d1.tar.gz
focaccia-qemu-33e4c22fd1dd2aa1e1e6f45e8e89c9b961fb72d1.zip
vfio: Make VFIOIOMMUClass::add_window() and its wrapper return bool
Make VFIOIOMMUClass::add_window() and its wrapper function
vfio_container_add_section_window() return bool.

This is to follow the coding standand to return bool if 'Error **'
is used to pass error.

Suggested-by: Cédric Le Goater <clg@redhat.com>
Signed-off-by: Zhenzhong Duan <zhenzhong.duan@intel.com>
Reviewed-by: Cédric Le Goater <clg@redhat.com>
Signed-off-by: Cédric Le Goater <clg@redhat.com>
Diffstat (limited to 'hw/vfio/common.c')
-rw-r--r--hw/vfio/common.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hw/vfio/common.c b/hw/vfio/common.c
index c04a259ffd..f9619a1dfb 100644
--- a/hw/vfio/common.c
+++ b/hw/vfio/common.c
@@ -588,7 +588,7 @@ static void vfio_listener_region_add(MemoryListener *listener,
         return;
     }
 
-    if (vfio_container_add_section_window(bcontainer, section, &err)) {
+    if (!vfio_container_add_section_window(bcontainer, section, &err)) {
         goto fail;
     }