From: BitKeeper B. <ri...@su...> - 2005-02-27 14:01:26
|
ChangeSet 1.1271, 2005/02/27 13:40:30+00:00, ka...@sc... Set pagetable bits correctly (for Linux) in DOM0 builder. Signed-off-by: Keir Fraser <ke...@xe...> domain_build.c | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-) diff -Nru a/xen/arch/x86/domain_build.c b/xen/arch/x86/domain_build.c --- a/xen/arch/x86/domain_build.c 2005-02-27 09:01:00 -05:00 +++ b/xen/arch/x86/domain_build.c 2005-02-27 09:01:00 -05:00 @@ -32,9 +32,11 @@ /* Allow ring-3 access in long mode as guest cannot use ring 1. */ #define L1_PROT (_PAGE_PRESENT|_PAGE_RW|_PAGE_ACCESSED|_PAGE_USER) #endif -#define L2_PROT (_PAGE_PRESENT|_PAGE_RW|_PAGE_ACCESSED|_PAGE_USER) -#define L3_PROT (_PAGE_PRESENT|_PAGE_RW|_PAGE_ACCESSED|_PAGE_USER) -#define L4_PROT (_PAGE_PRESENT|_PAGE_RW|_PAGE_ACCESSED|_PAGE_USER) +/* Don't change these: Linux expects just these bits to be set. */ +/* (And that includes the bogus _PAGE_DIRTY!) */ +#define L2_PROT (_PAGE_PRESENT|_PAGE_RW|_PAGE_ACCESSED|_PAGE_DIRTY|_PAGE_USER) +#define L3_PROT (_PAGE_PRESENT|_PAGE_RW|_PAGE_ACCESSED|_PAGE_DIRTY|_PAGE_USER) +#define L4_PROT (_PAGE_PRESENT|_PAGE_RW|_PAGE_ACCESSED|_PAGE_DIRTY|_PAGE_USER) #define round_pgup(_p) (((_p)+(PAGE_SIZE-1))&PAGE_MASK) #define round_pgdown(_p) ((_p)&PAGE_MASK) |