md/r5cache: simplify handling of sh->log_start in recovery
commit3c66abbaaf69671dfd3eb9fa7740b5d7ec688231
authorSong Liu <songliubraving@fb.com>
Wed, 14 Dec 2016 23:38:01 +0000 (14 15:38 -0800)
committerShaohua Li <shli@fb.com>
Thu, 5 Jan 2017 19:44:38 +0000 (5 11:44 -0800)
tree63f3110203923120a46c9b052a97a16feaf22b39
parent28ca833ecf89c585a9543fb21aef6b2bdbbaa48a
md/r5cache: simplify handling of sh->log_start in recovery

We only need to update sh->log_start at the end of recovery,
which is r5c_recovery_rewrite_data_only_stripes(), so it is not
necessary to set it before that. In this patch, log_start is
removed from r5c_recovery_alloc_stripe().

After updating all sh->log_start, rewrite_data_only_stripes()
also updates log->next_checkpoints to the last sh->log_start.

Signed-off-by: Song Liu <songliubraving@fb.com>
Signed-off-by: Shaohua Li <shli@fb.com>
drivers/md/raid5-cache.c