Skip to content

RFC ARMv7: Add HYP mode switching support

Andre Przywara u-boot 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest0 of 6 patches 0 repliesNew

Patches in v1 No applies recorded yet

None of the 6 patches the cover letter announces are in this archive.

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [U-Boot] [RFC PATCH 0/6] ARMv7: Add HYP mode switching support
Quoted 11 lines · Peter Maydell
Quoted 9 lines · Andre Przywara

ARM CPUs with the virtualization extension have a new mode called HYP mode, which allows hypervisors to safely control and monitor guests. The current hypervisor (KVM and Xen) implementations require the kernel to be entered in that HYP mode.

This patch series introduces a new U-Boot command called "hypmode" which can be used at any time at the U-Boot command prompt to switch the CPU into HYP mode - ideally this would be done before starting the kernel.

Quoted 4 lines

The obvious question here is "why do we need a new command?". The kernel booting specification says "boot the kernel in Hyp mode" so we should just always do that for booting Linux, surely?

Because it avoids regressions. I kind of feel uneasy to do a lot of tinkering with secure state and the GIC unconditionally, especially if enabled on many boards with virt-capable CPUs.

As written in question 2) later in that mail, I can also live with a command to _dis_able the HYP mode switching in case it causes problems.

Regards,
Andre.