lkml.org 
[lkml]   [2003]   [Feb]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH][2.5][3/5] CPU Hotplug fs/
 buffer.c |   16 +++++++++++++++-
1 files changed, 15 insertions(+), 1 deletion(-)

Index: linux-2.5.61-trojan/fs/buffer.c
===================================================================
RCS file: /build/cvsroot/linux-2.5.61/fs/buffer.c,v
retrieving revision 1.1.1.1
diff -u -r1.1.1.1 buffer.c
--- linux-2.5.61-trojan/fs/buffer.c 15 Feb 2003 12:32:24 -0000 1.1.1.1
+++ linux-2.5.61-trojan/fs/buffer.c 15 Feb 2003 19:35:22 -0000
@@ -2866,7 +2866,18 @@
bha->ratelimit = 0;
memset(bhl, 0, sizeof(*bhl));
}
-
+
+static void buffer_exit_cpu(int cpu)
+{
+ int i;
+ struct bh_lru *b = &per_cpu(bh_lrus, cpu);
+
+ for (i = 0; i < BH_LRU_SIZE; i++) {
+ brelse(b->bhs[i]);
+ b->bhs[i] = NULL;
+ }
+}
+
static int __devinit buffer_cpu_notify(struct notifier_block *self,
unsigned long action, void *hcpu)
{
@@ -2874,6 +2885,9 @@
switch(action) {
case CPU_UP_PREPARE:
buffer_init_cpu(cpu);
+ break;
+ case CPU_OFFLINE:
+ buffer_exit_cpu(cpu);
break;
default:
break;
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
\
 
 \ /
  Last update: 2005-03-22 13:33    [W:0.035 / U:3.012 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site