diff options
author | Mike Larkin <mlarkin@cvs.openbsd.org> | 2014-05-31 06:30:17 +0000 |
---|---|---|
committer | Mike Larkin <mlarkin@cvs.openbsd.org> | 2014-05-31 06:30:17 +0000 |
commit | 8d6d885afdf3b031f041566fbba839b892dd5936 (patch) | |
tree | 5aaa6dc41b63c3e854793502f074dca1f7a1b849 /sys/arch/i386 | |
parent | 713744c0293b3f2362b1ec99be1c806cf9866760 (diff) |
Remove some unused code that we added at the 2013 Toronto hackathon but
don't need anymore.
Diffstat (limited to 'sys/arch/i386')
-rw-r--r-- | sys/arch/i386/i386/hibernate_machdep.c | 36 | ||||
-rw-r--r-- | sys/arch/i386/include/hibernate.h | 3 |
2 files changed, 2 insertions, 37 deletions
diff --git a/sys/arch/i386/i386/hibernate_machdep.c b/sys/arch/i386/i386/hibernate_machdep.c index 34a6c0fca15..b65b42c8321 100644 --- a/sys/arch/i386/i386/hibernate_machdep.c +++ b/sys/arch/i386/i386/hibernate_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: hibernate_machdep.c,v 1.29 2013/10/20 20:03:03 mlarkin Exp $ */ +/* $OpenBSD: hibernate_machdep.c,v 1.30 2014/05/31 06:30:16 mlarkin Exp $ */ /* * Copyright (c) 2011 Mike Larkin <mlarkin@openbsd.org> @@ -267,40 +267,6 @@ hibernate_populate_resume_pt(union hibernate_info *hib_info, } /* - * MD-specific resume preparation (creating resume time pagetables, - * stacks, etc). - */ -void -hibernate_prepare_resume_machdep(union hibernate_info *hib_info) -{ - paddr_t pa, piglet_end; - vaddr_t va; - - /* - * At this point, we are sure that the piglet's phys space is going to - * have been unused by the suspending kernel, but the vaddrs used by - * the suspending kernel may or may not be available to us here in the - * resuming kernel, so we allocate a new range of VAs for the piglet. - * Those VAs will be temporary and will cease to exist as soon as we - * switch to the resume PT, so we need to ensure that any VAs required - * during inflate are also entered into that map. - */ - - hib_info->piglet_va = (vaddr_t)km_alloc(HIBERNATE_CHUNK_SIZE*3, - &kv_any, &kp_none, &kd_nowait); - if (!hib_info->piglet_va) - panic("Unable to allocate vaddr for hibernate resume piglet\n"); - - piglet_end = hib_info->piglet_pa + HIBERNATE_CHUNK_SIZE*3; - - for (pa = hib_info->piglet_pa,va = hib_info->piglet_va; - pa <= piglet_end; pa += PAGE_SIZE, va += PAGE_SIZE) - pmap_kenter_pa(va, pa, VM_PROT_ALL); - - pmap_activate(curproc); -} - -/* * During inflate, certain pages that contain our bookkeeping information * (eg, the chunk table, scratch pages, etc) need to be skipped over and * not inflated into. diff --git a/sys/arch/i386/include/hibernate.h b/sys/arch/i386/include/hibernate.h index 02b73734e21..f170ed82992 100644 --- a/sys/arch/i386/include/hibernate.h +++ b/sys/arch/i386/include/hibernate.h @@ -1,4 +1,4 @@ -/* $OpenBSD: hibernate.h,v 1.8 2013/06/04 01:20:23 pirofti Exp $ */ +/* $OpenBSD: hibernate.h,v 1.9 2014/05/31 06:30:16 mlarkin Exp $ */ /* * Copyright (c) 2011 Mike Larkin <mlarkin@openbsd.org> @@ -24,7 +24,6 @@ int get_hibernate_info_md(union hibernate_info *); void hibernate_flush(void); void hibernate_enter_resume_mapping(vaddr_t, paddr_t, int); int hibernate_inflate_skip(union hibernate_info *, paddr_t); -void hibernate_prepare_resume_machdep(union hibernate_info *); int hibernate_suspend(void); void hibernate_switch_stack_machdep(void); void hibernate_resume_machdep(void); |