From: mlarkin Date: Sun, 5 Jan 2014 23:06:54 +0000 (+0000) Subject: HIBERNATE_SELTABLE is not used anymore. Remove, and reclaim its stolen X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=19caa8b1895792ba3b666f0ac029e4cf8b1c1ca0;p=openbsd HIBERNATE_SELTABLE is not used anymore. Remove, and reclaim its stolen page. --- diff --git a/sys/arch/amd64/amd64/hibernate_machdep.c b/sys/arch/amd64/amd64/hibernate_machdep.c index f81320e2880..4d429770751 100644 --- a/sys/arch/amd64/amd64/hibernate_machdep.c +++ b/sys/arch/amd64/amd64/hibernate_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: hibernate_machdep.c,v 1.17 2013/10/20 20:03:03 mlarkin Exp $ */ +/* $OpenBSD: hibernate_machdep.c,v 1.18 2014/01/05 23:06:54 mlarkin Exp $ */ /* * Copyright (c) 2012 Mike Larkin @@ -243,7 +243,6 @@ hibernate_populate_resume_pt(union hibernate_info *hib_info, pmap_kenter_pa(HIBERNATE_PT_LOW, HIBERNATE_PT_LOW, VM_PROT_ALL); pmap_kenter_pa(HIBERNATE_PT_LOW2, HIBERNATE_PT_LOW2, VM_PROT_ALL); pmap_kenter_pa(HIBERNATE_PT_HI, HIBERNATE_PT_HI, VM_PROT_ALL); - pmap_kenter_pa(HIBERNATE_SELTABLE, HIBERNATE_SELTABLE, VM_PROT_ALL); /* Identity map 3 pages for stack */ pmap_kenter_pa(HIBERNATE_STACK_PAGE, HIBERNATE_STACK_PAGE, VM_PROT_ALL); @@ -262,7 +261,6 @@ hibernate_populate_resume_pt(union hibernate_info *hib_info, bzero((caddr_t)HIBERNATE_PT_LOW, PAGE_SIZE); bzero((caddr_t)HIBERNATE_PT_LOW2, PAGE_SIZE); bzero((caddr_t)HIBERNATE_PT_HI, PAGE_SIZE); - bzero((caddr_t)HIBERNATE_SELTABLE, PAGE_SIZE); bzero((caddr_t)(HIBERNATE_STACK_PAGE - 3*PAGE_SIZE) , 3*PAGE_SIZE); /* First 512GB PML4E */ diff --git a/sys/arch/amd64/include/hibernate_var.h b/sys/arch/amd64/include/hibernate_var.h index db8d774b4e5..c822f195357 100644 --- a/sys/arch/amd64/include/hibernate_var.h +++ b/sys/arch/amd64/include/hibernate_var.h @@ -1,4 +1,4 @@ -/* $OpenBSD: hibernate_var.h,v 1.7 2014/01/05 20:23:57 mlarkin Exp $ */ +/* $OpenBSD: hibernate_var.h,v 1.8 2014/01/05 23:06:54 mlarkin Exp $ */ /* * Copyright (c) 2011 Mike Larkin @@ -54,14 +54,12 @@ #define HIBERNATE_PT_LOW2 (PAGE_SIZE * 25) #define HIBERNATE_PT_HI (PAGE_SIZE * 26) -#define HIBERNATE_SELTABLE (PAGE_SIZE * 27) - /* 3 pages for stack */ -#define HIBERNATE_STACK_PAGE (PAGE_SIZE * 30) +#define HIBERNATE_STACK_PAGE (PAGE_SIZE * 29) -#define HIBERNATE_INFLATE_PAGE (PAGE_SIZE * 31) +#define HIBERNATE_INFLATE_PAGE (PAGE_SIZE * 30) /* HIBERNATE_HIBALLOC_PAGE must be the last stolen page (see machdep.c) */ -#define HIBERNATE_HIBALLOC_PAGE (PAGE_SIZE * 32) +#define HIBERNATE_HIBALLOC_PAGE (PAGE_SIZE * 31) /* Use 4MB hibernation chunks */ #define HIBERNATE_CHUNK_SIZE 0x400000