]> git.ipfire.org Git - thirdparty/qemu.git/commitdiff
ppc/spapr_pci_vfio.c: use QOM casts where appropriate
authorMark Cave-Ayland <mark.caveayland@nutanix.com>
Tue, 15 Jul 2025 09:25:45 +0000 (10:25 +0100)
committerCédric Le Goater <clg@redhat.com>
Mon, 8 Sep 2025 14:46:31 +0000 (16:46 +0200)
Use a QOM cast to convert to VFIOContainer instead of accessing bcontainer
directly.

Signed-off-by: Mark Cave-Ayland <mark.caveayland@nutanix.com>
Reviewed-by: Cédric Le Goater <clg@redhat.com>
Reviewed-by: Harsh Prateek Bora <harshpb@linux.ibm.com>
Link: https://lore.kernel.org/qemu-devel/20250715093110.107317-6-mark.caveayland@nutanix.com
Signed-off-by: Cédric Le Goater <clg@redhat.com>
hw/ppc/spapr_pci_vfio.c

index e318d0d912f3e90d1289e4bc2195bf68418e5206..7e1c71ef59d5c4d4449769b726c8c0053e607097 100644 (file)
@@ -106,7 +106,7 @@ static VFIOContainer *vfio_eeh_as_container(AddressSpace *as)
 
 out:
     vfio_address_space_put(space);
-    return container_of(bcontainer, VFIOContainer, bcontainer);
+    return VFIO_IOMMU_LEGACY(bcontainer);
 }
 
 static bool vfio_eeh_as_ok(AddressSpace *as)