swap_pager.h (12325) | swap_pager.h (12767) |
---|---|
1/* 2 * Copyright (c) 1990 University of Utah. 3 * Copyright (c) 1991 The Regents of the University of California. 4 * All rights reserved. 5 * 6 * This code is derived from software contributed to Berkeley by 7 * the Systems Programming Group of the University of Utah Computer 8 * Science Department. --- 22 unchanged lines hidden (view full) --- 31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 36 * SUCH DAMAGE. 37 * 38 * from: @(#)swap_pager.h 7.1 (Berkeley) 12/5/90 | 1/* 2 * Copyright (c) 1990 University of Utah. 3 * Copyright (c) 1991 The Regents of the University of California. 4 * All rights reserved. 5 * 6 * This code is derived from software contributed to Berkeley by 7 * the Systems Programming Group of the University of Utah Computer 8 * Science Department. --- 22 unchanged lines hidden (view full) --- 31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 36 * SUCH DAMAGE. 37 * 38 * from: @(#)swap_pager.h 7.1 (Berkeley) 12/5/90 |
39 * $Id: swap_pager.h,v 1.10 1995/10/07 19:02:52 davidg Exp $ | 39 * $Id: swap_pager.h,v 1.11 1995/11/16 09:51:22 bde Exp $ |
40 */ 41 42/* 43 * Modifications to the block allocation data structure by John S. Dyson 44 * 18 Dec 93. 45 */ 46 47#ifndef _SWAP_PAGER_ --- 6 unchanged lines hidden (view full) --- 54 * perhaps up to 8 pages might be in order???? 55 * Above problem has been fixed, now we support 16 pages per block. Unused 56 * space is recovered by the swap pager now... 57 */ 58#define SWB_NPAGES 8 59struct swblock { 60 unsigned short swb_valid; /* bitmask for valid pages */ 61 unsigned short swb_locked; /* block locked */ | 40 */ 41 42/* 43 * Modifications to the block allocation data structure by John S. Dyson 44 * 18 Dec 93. 45 */ 46 47#ifndef _SWAP_PAGER_ --- 6 unchanged lines hidden (view full) --- 54 * perhaps up to 8 pages might be in order???? 55 * Above problem has been fixed, now we support 16 pages per block. Unused 56 * space is recovered by the swap pager now... 57 */ 58#define SWB_NPAGES 8 59struct swblock { 60 unsigned short swb_valid; /* bitmask for valid pages */ 61 unsigned short swb_locked; /* block locked */ |
62 int swb_block[SWB_NPAGES]; /* unfortunately int instead of daddr_t */ | 62 daddr_t swb_block[SWB_NPAGES]; /* unfortunately int instead of daddr_t */ |
63}; 64typedef struct swblock *sw_blk_t; 65 66#ifdef KERNEL 67extern struct pagerlst swap_pager_un_object_list; 68extern int swap_pager_full; 69 70int swap_pager_getpages __P((vm_object_t, vm_page_t *, int, int)); 71int swap_pager_putpages __P((vm_object_t, vm_page_t *, int, boolean_t, int *)); 72void swap_pager_sync __P((void)); 73int swap_pager_swp_alloc __P((vm_object_t, int)); | 63}; 64typedef struct swblock *sw_blk_t; 65 66#ifdef KERNEL 67extern struct pagerlst swap_pager_un_object_list; 68extern int swap_pager_full; 69 70int swap_pager_getpages __P((vm_object_t, vm_page_t *, int, int)); 71int swap_pager_putpages __P((vm_object_t, vm_page_t *, int, boolean_t, int *)); 72void swap_pager_sync __P((void)); 73int swap_pager_swp_alloc __P((vm_object_t, int)); |
74void swap_pager_copy __P((vm_object_t, vm_offset_t, vm_object_t, vm_offset_t, vm_offset_t)); 75void swap_pager_freespace __P((vm_object_t, vm_offset_t, vm_offset_t)); | 74void swap_pager_copy __P((vm_object_t, vm_pindex_t, vm_object_t, 75 vm_pindex_t, vm_pindex_t)); 76void swap_pager_freespace __P((vm_object_t, vm_pindex_t, vm_size_t)); |
76void swap_pager_swap_init __P((void)); 77#endif 78 79#endif /* _SWAP_PAGER_ */ | 77void swap_pager_swap_init __P((void)); 78#endif 79 80#endif /* _SWAP_PAGER_ */ |