Skip to contentSkip to conversation

ARM Guest VM Type

DISCUSSION Wei Huang 5 participants 5 messages Apr 25, 2014 – Apr 28, 2014

lore
Share & tools
lore

Wei Huang

author
#0 lore raw

According to enlighten.c in Kernel, ARM DomU is considered as HVM domain. However when the DomU is created, its property isn't configured to reflect this (XEN_DOMCTL_CDF_xxx) in tools. So is_hvm_domain(d) will return FALSE inside hypervisor.

Error?

-Wei

#1 lore raw
Quoted 6 lines · Wei Huang

According to enlighten.c in Kernel, ARM DomU is considered as HVM domain. However when the DomU is created, its property isn't configured to reflect this (XEN_DOMCTL_CDF_xxx) in tools. So is_hvm_domain(d) will return FALSE inside hypervisor.

Error?

It is not really an error, more an inconsistency. In reality the old "PV" and "HVM" labels don't fit ARM guests very well.

Quoted 1 line

From Linux POV it makes sense to think of ARM guests as HVM guests.

If it makes sense to do the same in Xen, then we might as well set the flag.

#2 lore raw

What about paging? On x86 it's configurable whether I want the guest to use shadow or HAP via hap=0/1 but I haven't find anything about that for the ARM side. Looking at the source I got the feeling that it's shadow paging if the guest is created with the config shown in
http://wiki.xenproject.org/wiki/Xen_ARM_with_Virtualization_Extensions#DomU_kernel_and_DTS.
Please correct me if I'm wrong! Thanks =)

Quoted 12 lines · Stefano Stabellini
Quoted 2 lines · Wei Huang

According to enlighten.c in Kernel, ARM DomU is considered as HVM domain. However when the DomU is created, its property isn't configured to

reflect

Quoted 4 lines

this (XEN_DOMCTL_CDF_xxx) in tools. So is_hvm_domain(d) will return FALSE inside hypervisor.

Error?

It is not really an error, more an inconsistency. In reality the old "PV" and "HVM" labels don't fit ARM guests very well.

Quoted 9 lines

From Linux POV it makes sense to think of ARM guests as HVM guests. If it makes sense to do the same in Xen, then we might as well set the flag.

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

_______________________________________________
Xen-devel mailing list
[email protected]
http://lists.xen.org/xen-devel

#3 lore raw

Hello Tamas,

Quoted 6 lines · Tamas Lengyel

What about paging? On x86 it's configurable whether I want the guest to use shadow or HAP via hap=0/1 but I haven't find anything about that for the ARM side. Looking at the source I got the feeling that it's shadow paging if the guest is created with the config shown in
http://wiki.xenproject.org/wiki/Xen_ARM_with_Virtualization_Extensions#DomU_kernel_and_DTS.
Please correct me if I'm wrong! Thanks =)

Xen on ARM takes directly advantage of the hardware virtualization feature. ARM processors provide a stage 2 translation (i.e guest PA -> host PA).

We don't support other kind of P2M translation (such as shadow PT) on ARM.

Regards,

Signature · 1 line
Julien Grall
#4 lore raw
In reply to Stefano Stabellini
Quoted 6 lines · Stefano Stabellini
Quoted 5 lines · Wei Huang

According to enlighten.c in Kernel, ARM DomU is considered as HVM domain. However when the DomU is created, its property isn't configured to reflect this (XEN_DOMCTL_CDF_xxx) in tools. So is_hvm_domain(d) will return FALSE inside hypervisor.

Quoted 8 lines
Quoted 1 line

Error?

It is not really an error, more an inconsistency. In reality the old "PV" and "HVM" labels don't fit ARM guests very well.

From Linux POV it makes sense to think of ARM guests as HVM guests. If it makes sense to do the same in Xen, then we might as well set the flag.

The "PV" and "HVM" labels are x86 specific and have no real bearing on the ARM hypervisor. We've been slowly eliminating the is_{pv,hvm}_foo calls from the generic code in the hypervisor in favour of more specific functionality tests (often paging-mode-translate based ones). We should continue to do this cleanup, setting any kind of PV or HVM based flag for an ARM guest would be wrong.

IMHO we should be doing the same on Linux (and all guest kernels) as well, but the leakage of x86-isms into the generic code is more pervasive there it seems (although I hope that between ARM and x86 PVH we can eventually clean it up there too)

Ian.