summaryrefslogtreecommitdiffstats
path: root/hw/ppc/spapr_iommu.c
diff options
context:
space:
mode:
authorPaolo Bonzini2013-06-25 12:32:25 +0200
committerPaolo Bonzini2013-07-04 17:42:47 +0200
commit84af6d9f97bb144bbebe688364431804a190074a (patch)
tree087992e9d48a83dc43716bd80d9bae7a5c8599bd /hw/ppc/spapr_iommu.c
parentvfio: pass device to vfio_mmap_bar and use it to set owner (diff)
downloadqemu-84af6d9f97bb144bbebe688364431804a190074a.tar.gz
qemu-84af6d9f97bb144bbebe688364431804a190074a.tar.xz
qemu-84af6d9f97bb144bbebe688364431804a190074a.zip
spapr_iommu: pass device to spapr_tce_new_table and use it to set owner
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/ppc/spapr_iommu.c')
-rw-r--r--hw/ppc/spapr_iommu.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/ppc/spapr_iommu.c b/hw/ppc/spapr_iommu.c
index 3976af62df..89b33a5478 100644
--- a/hw/ppc/spapr_iommu.c
+++ b/hw/ppc/spapr_iommu.c
@@ -116,7 +116,7 @@ static MemoryRegionIOMMUOps spapr_iommu_ops = {
.translate = spapr_tce_translate_iommu,
};
-sPAPRTCETable *spapr_tce_new_table(uint32_t liobn, size_t window_size)
+sPAPRTCETable *spapr_tce_new_table(DeviceState *owner, uint32_t liobn, size_t window_size)
{
sPAPRTCETable *tcet;
@@ -151,7 +151,7 @@ sPAPRTCETable *spapr_tce_new_table(uint32_t liobn, size_t window_size)
"table @ %p, fd=%d\n", tcet, liobn, tcet->table, tcet->fd);
#endif
- memory_region_init_iommu(&tcet->iommu, NULL, &spapr_iommu_ops,
+ memory_region_init_iommu(&tcet->iommu, OBJECT(owner), &spapr_iommu_ops,
"iommu-spapr", UINT64_MAX);
QLIST_INSERT_HEAD(&spapr_tce_tables, tcet, list);