Re: [PATCH v4 05/12] x86/xen: set MTRR state when running as Xen PV initial domain

2023-03-23 Thread Borislav Petkov
On Mon, Mar 06, 2023 at 05:34:18PM +0100, Juergen Gross wrote: > + for (reg = 0; reg < MTRR_MAX_VAR_RANGES; reg++) { > + op.u.read_memtype.reg = reg; > + if (HYPERVISOR_platform_op(&op)) > + break; > + > + /* > + * Only called

Re: [PATCH v4 05/12] x86/xen: set MTRR state when running as Xen PV initial domain

2023-03-07 Thread Boris Ostrovsky
On 3/6/23 11:34 AM, Juergen Gross wrote: When running as Xen PV initial domain (aka dom0), MTRRs are disabled by the hypervisor, but the system should nevertheless use correct cache memory types. This has always kind of worked, as disabled MTRRs resulted in disabled PAT, too, so that the kerne

[PATCH v4 05/12] x86/xen: set MTRR state when running as Xen PV initial domain

2023-03-06 Thread Juergen Gross
When running as Xen PV initial domain (aka dom0), MTRRs are disabled by the hypervisor, but the system should nevertheless use correct cache memory types. This has always kind of worked, as disabled MTRRs resulted in disabled PAT, too, so that the kernel avoided code paths resulting in inconsistenc