On 4/28/25 11:51, Anton Johansson wrote:
On 24/04/25, Philippe Mathieu-Daudé wrote:
Restrict iotlb_to_section(), address_space_translate_for_iotlb()
and memory_region_section_get_iotlb() to TCG. Declare them in
the new "accel/tcg/iommu.h" header. Declare iotlb_to_section()
using the MemoryRegionSection typedef.
Signed-off-by: Philippe Mathieu-Daudé <phi...@linaro.org>
---
MAINTAINERS | 2 +-
include/accel/tcg/iommu.h | 41 +++++++++++++++++++++++++++++++++++++++
include/exec/exec-all.h | 26 -------------------------
accel/tcg/cputlb.c | 1 +
system/physmem.c | 5 +++++
5 files changed, 48 insertions(+), 27 deletions(-)
create mode 100644 include/accel/tcg/iommu.h
diff --git a/MAINTAINERS b/MAINTAINERS
index 661a47db5ac..3a37cc73af7 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -168,7 +168,7 @@ F: include/exec/helper*.h.inc
F: include/exec/helper-info.c.inc
F: include/exec/page-protection.h
F: include/system/tcg.h
-F: include/accel/tcg/cpu-ops.h
+F: include/accel/tcg/
F: host/include/*/host/cpuinfo.h
F: util/cpuinfo-*.c
F: include/tcg/
diff --git a/include/accel/tcg/iommu.h b/include/accel/tcg/iommu.h
new file mode 100644
index 00000000000..90cfd6c0ed1
--- /dev/null
+++ b/include/accel/tcg/iommu.h
@@ -0,0 +1,41 @@
+/*
+ * TCG IOMMU translations.
+ *
+ * Copyright (c) 2003 Fabrice Bellard
+ * SPDX-License-Identifier: LGPL-2.1-or-later
+ */
+#ifndef ACCEL_TCG_IOMMU_H
+#define ACCEL_TCG_IOMMU_H
+
+#ifdef CONFIG_USER_ONLY
+#error Cannot include accel/tcg/iommu.h from user emulation
+#endif
+
+#include "exec/hwaddr.h"
+#include "exec/memattrs.h"
Missing qemu/typedefs.h include
No, that's always done by qemu/osdep.h in the c file.
r~