From: Ben Gras Date: Fri, 13 May 2005 13:42:07 +0000 (+0000) Subject: Don't cache /dev/ram blocks X-Git-Tag: v3.1.0~838 X-Git-Url: http://zhaoyanbai.com/repos/%22http:/www.isc.org/icons/Bv9ARM.ch11.html?a=commitdiff_plain;h=33bc71c3f528a3a63c855c6b3588558bdd4bef18;p=minix.git Don't cache /dev/ram blocks --- diff --git a/servers/fs/cache.c b/servers/fs/cache.c index 6f9f401b2..61b4a73d9 100644 --- a/servers/fs/cache.c +++ b/servers/fs/cache.c @@ -147,7 +147,7 @@ int block_type; /* INODE_BLOCK, DIRECTORY_BLOCK, or whatever */ * it on the front of the LRU chain where it will be the first one to be * taken when a free buffer is needed later. */ - if (block_type & ONE_SHOT) { + if (bp->b_dev == DEV_RAM || block_type & ONE_SHOT) { /* Block probably won't be needed quickly. Put it on front of chain. * It will be the next block to be evicted from the cache. */