On Fri, 6 Nov 2020 12:34:10 +0100 Paolo Bonzini <pbonzini@xxxxxxxxxx> wrote: > On 02/10/20 17:44, Claudio Imbrenda wrote: > > x86 gets > > * lowest area (24-bit addresses) > > * low area (32-bit addresses) > > * the rest > > x86 if anything could use a 36-bit area; the 24-bit one is out of > scope for what kvm-unit-tests does. sure... I went with what I remembered about the x86 architecture, but I'm not an expert my patch was meant to be some "sensible defaults" that people with more knowledge should override anyway :) > So something like this: > > diff --git a/lib/x86/asm/memory_areas.h b/lib/x86/asm/memory_areas.h > index d704df3..952f5bd 100644 > --- a/lib/x86/asm/memory_areas.h > +++ b/lib/x86/asm/memory_areas.h > @@ -1,20 +1,19 @@ > #ifndef MEMORY_AREAS_H > #define MEMORY_AREAS_H > > -#define AREA_NORMAL_PFN BIT(32-12) > +#define AREA_NORMAL_PFN BIT(36-12) > #define AREA_NORMAL_NUMBER 0 > #define AREA_NORMAL 1 > > -#define AREA_LOW_PFN BIT(24-12) > -#define AREA_LOW_NUMBER 1 > -#define AREA_LOW 2 > +#define AREA_PAE_HIGH_PFN BIT(32-12) > +#define AREA_PAE_HIGH_NUMBER 1 > +#define AREA_PAE_HIGH 2 > > -#define AREA_LOWEST_PFN 0 > -#define AREA_LOWEST_NUMBER 2 > -#define AREA_LOWEST 4 > +#define AREA_LOW_PFN 0 > +#define AREA_LOW_NUMBER 2 > +#define AREA_LOW 4 > > -#define AREA_DMA24 AREA_LOWEST > -#define AREA_DMA32 (AREA_LOWEST | AREA_LOW) > +#define AREA_PAE (AREA_PAE | AREA_LOW) > > #define AREA_ANY -1 > #define AREA_ANY_NUMBER 0xff > > Paolo >