On 02.07.19 16:36, Pratyush Yadav wrote:
The SMMU driver needs access to guest paging structures, so they need to
be initialized before we can initialize the driver.
No signed-off - because you were not sure if this is ready? ;)
The bad news: it isn't. The x86 IOMMUs have to be initialized prior to calling
arch_map_memory_region because that calls iommu_map_memory_region.
Can you describe in more details why the SMMU driver needs that guest paging
access during init, and why that can't be solved by hooking into ARM's
arch_map_memory_region?
Jan
---
hypervisor/setup.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/hypervisor/setup.c b/hypervisor/setup.c
index e3b1b3c8..c4032f5b 100644
--- a/hypervisor/setup.c
+++ b/hypervisor/setup.c
@@ -174,13 +174,6 @@ static void init_late(void)
return;
}
- for_each_unit(unit) {
- printk("Initializing unit: %s\n", unit->name);
- error = unit->init();
- if (error)
- return;
- }
-
for_each_mem_region(mem, root_cell.config, n) {
if (JAILHOUSE_MEMORY_IS_SUBPAGE(mem))
error = mmio_subpage_register(&root_cell, mem);
@@ -190,6 +183,13 @@ static void init_late(void)
return;
}
+ for_each_unit(unit) {
+ printk("Initializing unit: %s\n", unit->name);
+ error = unit->init();
+ if (error)
+ return;
+ }
+
config_commit(&root_cell);
paging_dump_stats("after late setup");
--
Siemens AG, Corporate Technology, CT RDA IOT SES-DE
Corporate Competence Center Embedded Linux
--
You received this message because you are subscribed to the Google Groups
"Jailhouse" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/jailhouse-dev/bd22fee9-f3ee-0585-d98f-a411f8d58f1a%40siemens.com.
For more options, visit https://groups.google.com/d/optout.