On 2017-02-27 16:40, Henning Schild wrote:
> We used to unmap the firmware image right after "jailhouse disable".
> Change that and keep the firmware mapped until we exit the module or
> restart jailhouse. This way we can look into the firmware that just ran.
>
> This will be used by later patches.
>
> Signed-off-by: Henning Schild <[email protected]>
>
> diff --git a/driver/main.c b/driver/main.c
> --- a/driver/main.c
> +++ b/driver/main.c
> @@ -393,7 +393,9 @@
Your git (or hg) is misconfigured, lacking -p for diffs. Makes review hard.
> #ifdef JAILHOUSE_BORROW_ROOT_PT
> remap_addr = JAILHOUSE_BASE;
> #endif
> - /* Map physical memory region reserved for Jailhouse. */
> + /* Map physical memory region reserved for Jailhouse. And unmap
> + * the old one if it is not the first "jailhouse enable" */
In the right order
please describe. ;)
> + jailhouse_firmware_free();
> hypervisor_mem = jailhouse_ioremap(hv_mem->phys_start, remap_addr,
> hv_mem->size);
> if (!hypervisor_mem) {
> @@ -608,8 +610,6 @@
>
> update_last_console();
>
> - jailhouse_firmware_free();
> -
> jailhouse_cell_delete_root();
> jailhouse_enabled = false;
> module_put(THIS_MODULE);
> @@ -832,6 +832,7 @@
> unregister_reboot_notifier(&jailhouse_shutdown_nb);
> misc_deregister(&jailhouse_misc_dev);
> jailhouse_sysfs_exit(jailhouse_dev);
> + jailhouse_firmware_free();
> jailhouse_pci_unregister();
> root_device_unregister(jailhouse_dev);
> }
>
Jan
--
Siemens AG, Corporate Technology, CT RDA ITP 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].
For more options, visit https://groups.google.com/d/optout.