Thanks David and Andrew for providing all the helpful details.
I know what happened. As Andrew said, the raid1 buffers have simply
disappeared into thin air.
The line that makes them invisible is
r1_bh->state = 0;
at line 165 in drivers/md/raid1.c. This should be more like
r1_bh->state = (1 << R1BH_PreAlloc);
We need to clear the Uptodate bit and the Phase bit, but not
the prealloc bit.
Linus: Please consider applying this patch.
NeilBrown
--- drivers/md/raid1.c 2001/08/30 00:36:54 1.1
+++ drivers/md/raid1.c 2001/08/30 00:37:03
@@ -162,7 +162,7 @@
conf->freer1 = r1_bh->next_r1;
conf->freer1_cnt--;
r1_bh->next_r1 = NULL;
- r1_bh->state = 0;
+ r1_bh->state = (1 << R1BH_PreAlloc);
r1_bh->bh_req.b_state = 0;
}
md_spin_unlock_irq(&conf->device_lock);
-
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/