vfs_bio.c (225448) | vfs_bio.c (226843) |
---|---|
1/*- 2 * Copyright (c) 2004 Poul-Henning Kamp 3 * Copyright (c) 1994,1997 John S. Dyson 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 25 unchanged lines hidden (view full) --- 34 * Author: John S. Dyson 35 * Significant help during the development and debugging phases 36 * had been provided by David Greenman, also of the FreeBSD core team. 37 * 38 * see man buf(9) for more info. 39 */ 40 41#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2004 Poul-Henning Kamp 3 * Copyright (c) 1994,1997 John S. Dyson 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 25 unchanged lines hidden (view full) --- 34 * Author: John S. Dyson 35 * Significant help during the development and debugging phases 36 * had been provided by David Greenman, also of the FreeBSD core team. 37 * 38 * see man buf(9) for more info. 39 */ 40 41#include <sys/cdefs.h> |
42__FBSDID("$FreeBSD: head/sys/kern/vfs_bio.c 225448 2011-09-08 12:56:26Z attilio $"); | 42__FBSDID("$FreeBSD: head/sys/kern/vfs_bio.c 226843 2011-10-27 16:39:17Z alc $"); |
43 44#include <sys/param.h> 45#include <sys/systm.h> 46#include <sys/bio.h> 47#include <sys/conf.h> 48#include <sys/buf.h> 49#include <sys/devicestat.h> 50#include <sys/eventhandler.h> --- 3704 unchanged lines hidden (view full) --- 3755 3756 for (pg = from; pg < to; pg += PAGE_SIZE, index++) { 3757tryagain: 3758 /* 3759 * note: must allocate system pages since blocking here 3760 * could interfere with paging I/O, no matter which 3761 * process we are. 3762 */ | 43 44#include <sys/param.h> 45#include <sys/systm.h> 46#include <sys/bio.h> 47#include <sys/conf.h> 48#include <sys/buf.h> 49#include <sys/devicestat.h> 50#include <sys/eventhandler.h> --- 3704 unchanged lines hidden (view full) --- 3755 3756 for (pg = from; pg < to; pg += PAGE_SIZE, index++) { 3757tryagain: 3758 /* 3759 * note: must allocate system pages since blocking here 3760 * could interfere with paging I/O, no matter which 3761 * process we are. 3762 */ |
3763 p = vm_page_alloc(NULL, pg >> PAGE_SHIFT, VM_ALLOC_NOOBJ | 3764 VM_ALLOC_SYSTEM | VM_ALLOC_WIRED | 3765 VM_ALLOC_COUNT((to - pg) >> PAGE_SHIFT)); 3766 if (!p) { | 3763 p = vm_page_alloc(NULL, 0, VM_ALLOC_SYSTEM | VM_ALLOC_NOOBJ | 3764 VM_ALLOC_WIRED | VM_ALLOC_COUNT((to - pg) >> PAGE_SHIFT)); 3765 if (p == NULL) { |
3767 VM_WAIT; 3768 goto tryagain; 3769 } 3770 pmap_qenter(pg, &p, 1); 3771 bp->b_pages[index] = p; 3772 } 3773 bp->b_npages = index; 3774} --- 310 unchanged lines hidden --- | 3766 VM_WAIT; 3767 goto tryagain; 3768 } 3769 pmap_qenter(pg, &p, 1); 3770 bp->b_pages[index] = p; 3771 } 3772 bp->b_npages = index; 3773} --- 310 unchanged lines hidden --- |