summaryrefslogtreecommitdiffstats
path: root/sys/vm
diff options
context:
space:
mode:
authordt <dt@FreeBSD.org>1998-12-29 22:53:51 +0000
committerdt <dt@FreeBSD.org>1998-12-29 22:53:51 +0000
commit065be558704c9254fa782e3c7a9c5496ff74c61c (patch)
tree9ec87de7cef318719819aa72fa2b36ff91dcb328 /sys/vm
parenta5b622c82ef7e58c9e2ed0f928bc6fee70115911 (diff)
downloadFreeBSD-src-065be558704c9254fa782e3c7a9c5496ff74c61c.zip
FreeBSD-src-065be558704c9254fa782e3c7a9c5496ff74c61c.tar.gz
Don't free swap in swap_pager_getpages(): this code probably cause the
"dying daemons" problem. (I thought this code was introduced in rev.1.80, but it just relaxed the condition.) Also, kill related "suggest more swap space" warning (also introduced in 1.80). It was confusing, to say the least... Requested by: msmith Not objected by: dg
Diffstat (limited to 'sys/vm')
-rw-r--r--sys/vm/swap_pager.c24
1 files changed, 1 insertions, 23 deletions
diff --git a/sys/vm/swap_pager.c b/sys/vm/swap_pager.c
index 62733c9..3e2d0de 100644
--- a/sys/vm/swap_pager.c
+++ b/sys/vm/swap_pager.c
@@ -39,7 +39,7 @@
* from: Utah $Hdr: swap_pager.c 1.4 91/04/30$
*
* @(#)swap_pager.c 8.9 (Berkeley) 3/21/94
- * $Id: swap_pager.c,v 1.103 1998/10/31 15:31:28 peter Exp $
+ * $Id: swap_pager.c,v 1.104 1998/11/19 06:20:42 bde Exp $
*/
/*
@@ -81,7 +81,6 @@
static int nswiodone;
int swap_pager_full;
extern int vm_swap_size;
-static int suggest_more_swap = 0;
static int no_swap_space = 1;
static int max_pageout_cluster;
struct rlisthdr swaplist;
@@ -398,11 +397,6 @@ swap_pager_getswapspace(object, amount, rtval)
unsigned location;
vm_swap_size -= amount;
- if (!suggest_more_swap && (vm_swap_size < btodb(cnt.v_page_count * PAGE_SIZE))) {
- printf("swap_pager: suggest more swap space: %d MB\n",
- (2 * cnt.v_page_count * (PAGE_SIZE / 1024)) / 1000);
- suggest_more_swap = 1;
- }
if (!rlist_alloc(&swaplist, amount, &location)) {
vm_swap_size += amount;
@@ -1128,22 +1122,6 @@ swap_pager_getpages(object, m, count, reqpage)
}
m[reqpage]->object->last_read = m[count-1]->pindex;
-
- /*
- * If we're out of swap space, then attempt to free
- * some whenever multiple pages are brought in. We
- * must set the dirty bits so that the page contents
- * will be preserved.
- */
- if (SWAPLOW ||
- (vm_swap_size < btodb((cnt.v_page_count - cnt.v_wire_count)) * PAGE_SIZE)) {
- for (i = 0; i < count; i++) {
- m[i]->dirty = VM_PAGE_BITS_ALL;
- }
- swap_pager_freespace(object,
- m[0]->pindex + paging_offset, count);
- }
-
} else {
swap_pager_ridpages(m, count, reqpage);
}
OpenPOWER on IntegriCloud