1 While the stripe in-memory must be in-sync, the stripe on disk might not be
2 because if we computed a block rather than reading it from an in-sync disk,
3 the in-memory stripe can be different from the on-disk stripe.
5 If this bug were still in mainline I would probably want a bigger patch which
6 would leave this code but also set R5_LOCKED on all blocks that have been
7 computed. But as it is a stablisation patch, the above is simple and more
10 Thanks for you patience - I look forward to your success/failure report.
14 diff -up /drivers/md/raid5.c
15 ===========================================
16 --- a/drivers/md/raid5.c
17 +++ b/drivers/md/raid5.c
20 set_bit(R5_Wantwrite, &sh->dev[i].flags);
22 - /* after a RECONSTRUCT_WRITE, the stripe MUST be in-sync */
23 - set_bit(STRIPE_INSYNC, &sh->state);
25 if (test_and_clear_bit(STRIPE_PREREAD_ACTIVE, &sh->state)) {
26 atomic_dec(&conf->preread_active_stripes);