On 29.07.2024 15:36, Alejandro Vallejo wrote:
> On Fri Jul 26, 2024 at 4:21 PM BST, Roger Pau Monne wrote:
>> --- a/xen/arch/x86/mm/hap/hap.c
>> +++ b/xen/arch/x86/mm/hap/hap.c
>> @@ -402,7 +402,8 @@ static mfn_t hap_make_monitor_table(struct vcpu *v)
>>      m4mfn = page_to_mfn(pg);
>>      l4e = map_domain_page(m4mfn);
>>  
>> -    init_xen_l4_slots(l4e, m4mfn, d, INVALID_MFN, false);
>> +    init_xen_l4_slots(l4e, m4mfn, INVALID_MFN, d->arch.perdomain_l3_pg,
>> +                      false, true, false);
> 
> Out of ignorance: why is the compat area mapped on HVM monitor PTs? I thought
> those were used exclusively in hypervisor context, and would hence always have
> the 512 slots available.

"compat area" is perhaps a misleading term. If you look at the function itself,
it's PERDOMAIN_ALT_VIRT_START that is mapped in that case. Which underlies the
compat-arg-xlat area, which both 32-bit PV and all HVM guests need, the latter
as they can, at any time, switch to 32-bit mode.

Jan

Reply via email to