Re: HYP mode required on boot?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 8 November 2012 15:29, Jessica Allison
<jessica.allison.2012@xxxxxxxxxxx> wrote:
> Hi there, I am developing a boot loader for Linux KVM on ARM. Can you just
> confirm to me that for KVM to work it is required that the kernel is
> booted in HYP mode?

Yes. The ABI contract between the boot loader and the kernel mandates
that you pass the kernel control in Hyp mode if you want KVM to work.
This is all now documented in
https://github.com/torvalds/linux/blob/master/Documentation/arm/Booting

> Is there no way for KVM to later switch to HYP mode when the kernel
> is booted in non-secure SVC mode?

If you are in NS-SVC then the only way to get back up to Hyp mode
would be (a) to make a hypercall via the HVC insn or (b) to make
a secure monitor call via the SMC insn. This would require that
we made the boot loader provide some ABI for "give me hypervisor
access". This is much more complicated and easy for boot loader
authors to get wrong or fail to implement. So we do the simple
straightforward thing and just require the boot loader to pass
us control in the most privileged mode possible.

We don't let bootloaders start the kernel in user mode and provide
an ABI for giving us access to SVC mode later either :-)

-- PMM
_______________________________________________
kvmarm mailing list
kvmarm@xxxxxxxxxxxxxxxxxxxxx
https://lists.cs.columbia.edu/cucslists/listinfo/kvmarm


[Index of Archives]     [Linux KVM]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux