From: Rik van Riel <riel@conectiva.com.br>
To: Linus Torvalds <torvalds@transmeta.com>
Cc: linux-mm@kvack.org
Subject: [patch] pre9-2 shm balance
Date: Wed, 17 May 2000 23:32:24 -0300 (BRST) [thread overview]
Message-ID: <Pine.LNX.4.21.0005172331320.3951-100000@duckman.distro.conectiva> (raw)
Hi Linus,
with quintela's latest patch and the small patch below, the
system works fine again, even under heavy shm stress testing.
regards,
Rik
--
The Internet is not a network of computers. It is a network
of people. That is its real strength.
Wanna talk about the kernel? irc.openprojects.net / #kernelnewbies
http://www.conectiva.com/ http://www.surriel.com/
--- ipc/shm.c.orig Wed May 17 22:59:47 2000
+++ ipc/shm.c Wed May 17 23:24:52 2000
@@ -1468,7 +1468,7 @@
}
/*
- * Goes through counter = (shm_rss >> prio) present shm pages.
+ * Goes through counter = (shm_rss / (prio + 1)) present shm pages.
*/
static unsigned long swap_id; /* currently being swapped */
static unsigned long swap_idx; /* next to swap */
@@ -1483,7 +1483,7 @@
struct page * page_map;
zshm_swap(prio, gfp_mask);
- counter = shm_rss >> prio;
+ counter = shm_rss / (prio + 1);
if (!counter)
return 0;
if (shm_swap_preop(&swap_entry))
@@ -1809,7 +1809,7 @@
int counter;
struct page * page_map;
- counter = zshm_rss >> prio;
+ counter = zshm_rss / (prio + 1);
if (!counter)
return;
next:
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux.eu.org/Linux-MM/
reply other threads:[~2000-05-18 2:32 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Pine.LNX.4.21.0005172331320.3951-100000@duckman.distro.conectiva \
--to=riel@conectiva.com.br \
--cc=linux-mm@kvack.org \
--cc=torvalds@transmeta.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox