Linux Headquarters
[ Register ]
[ About us ] [ Home Page ]

Advertisement
[ Kernel ] [ Documentation ] [ Links ] [ Books ]

Advertisement

Kernel v2.4.17-rc2 /fs/buffer.c

Filename:/fs/buffer.c
Lines Added:3
Lines Deleted:2
Also changed in: (Previous) 2.4.17-rc1  2.4.17-pre8  2.4.17-pre7  2.4.17-pre6  2.4.17-pre5  2.4.17-pre3 
(Following) 2.4.17  2.4.18-pre3-ac1  2.4.18-pre3-ac2  2.4.18-pre4  2.4.18-pre5  2.4.18-pre6 

Location
[  2.4.17-rc2
  [  fs
     o  buffer.c

Patch

diff -Naur -X /home/marcelo/lib/dontdiff linux-2.4.16/fs/buffer.c linux/fs/buffer.c
--- linux-2.4.16/fs/buffer.c   Wed Nov 21 22:40:17 2001
+++ linux/fs/buffer.c   Tue Dec 18 19:43:00 2001
@@ -73,7 +73,7 @@
 static rwlock_t hash_table_lock = RW_LOCK_UNLOCKED;
 
 static struct buffer_head *lru_list[NR_LIST];
-static spinlock_t lru_list_lock = SPIN_LOCK_UNLOCKED;
+static spinlock_t lru_list_lock __cacheline_aligned_in_smp = SPIN_LOCK_UNLOCKED;
 static int nr_buffers_type[NR_LIST];
 static unsigned long size_buffers_type[NR_LIST];
 
@@ -1036,6 +1036,7 @@
    unsigned long dirty, tot, hard_dirty_limit, soft_dirty_limit;
 
    dirty = size_buffers_type[BUF_DIRTY] >> PAGE_SHIFT;
+   dirty += size_buffers_type[BUF_LOCKED] >> PAGE_SHIFT;
    tot = nr_free_buffer_pages();
 
    dirty *= 100;
@@ -1044,7 +1045,7 @@
 
    /* First, check for the "real" dirty limit. */
    if (dirty > soft_dirty_limit) {
-      if (dirty > hard_dirty_limit)
+      if (dirty > hard_dirty_limit && !(current->flags & PF_NOIO))
          return 1;
       return 0;
    }


Comments: webmaster (at) linuxhq.com.
Advertising: banners (at) linuxhq.com.
Compilation ©1998-2008 Linux Headquarters, Inc.