patch-2.3.47 linux/drivers/block/raid1.c
Next file: linux/drivers/char/Makefile
Previous file: linux/drivers/block/nbd.c
Back to the patch index
Back to the overall index
- Lines: 36
- Date:
Sun Feb 20 20:23:20 2000
- Orig file:
v2.3.46/linux/drivers/block/raid1.c
- Orig date:
Thu Aug 12 10:16:28 1999
diff -u --recursive --new-file v2.3.46/linux/drivers/block/raid1.c linux/drivers/block/raid1.c
@@ -211,7 +211,11 @@
while (!( /* FIXME: now we are rather fault tolerant than nice */
r1_bh = kmalloc (sizeof (struct raid1_bh), GFP_KERNEL)
) )
+ {
printk ("raid1_make_request(#1): out of memory\n");
+ current->policy |= SCHED_YIELD;
+ schedule();
+ }
memset (r1_bh, 0, sizeof (struct raid1_bh));
/*
@@ -298,7 +302,11 @@
while (!( /* FIXME: now we are rather fault tolerant than nice */
mirror_bh[i] = kmalloc (sizeof (struct buffer_head), GFP_KERNEL)
) )
+ {
printk ("raid1_make_request(#2): out of memory\n");
+ current->policy |= SCHED_YIELD;
+ schedule();
+ }
memset (mirror_bh[i], 0, sizeof (struct buffer_head));
/*
@@ -710,7 +718,11 @@
while (!( /* FIXME: now we are rather fault tolerant than nice */
mddev->private = kmalloc (sizeof (struct raid1_data), GFP_KERNEL)
) )
+ {
printk ("raid1_run(): out of memory\n");
+ current->policy |= SCHED_YIELD;
+ schedule();
+ }
raid_conf = mddev->private;
memset(raid_conf, 0, sizeof(*raid_conf));
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)