The hypervisor takes care of this itself now.

Signed-off-by: Jan Kiszka <[email protected]>
---
 driver/main.c | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/driver/main.c b/driver/main.c
index 746de07..0b7f19a 100644
--- a/driver/main.c
+++ b/driver/main.c
@@ -283,8 +283,8 @@ static int jailhouse_cmd_enable(struct jailhouse_system 
__user *arg)
                goto error_unmap;
        }
 
-       if (config->debug_console.flags & JAILHOUSE_MEM_IO) {
 #ifdef JAILHOUSE_BORROW_ROOT_PT
+       if (config->debug_console.flags & JAILHOUSE_MEM_IO) {
                console = ioremap(config->debug_console.phys_start,
                                  config->debug_console.size);
                if (!console) {
@@ -297,11 +297,8 @@ static int jailhouse_cmd_enable(struct jailhouse_system 
__user *arg)
                /* The hypervisor has no notion of address spaces, so we need
                 * to enforce conversion. */
                header->debug_console_base = (void * __force)console;
-#else
-               header->debug_console_base =
-                       (void * __force) config->debug_console.phys_start;
-#endif
        }
+#endif
 
        err = jailhouse_cell_prepare_root(&config->root_cell);
        if (err)
-- 
2.1.4

-- 
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].
For more options, visit https://groups.google.com/d/optout.

Reply via email to