On Fri, Dec 09, 2016 at 03:43:58PM +1100, Neil Brown wrote: > On Fri, Dec 09 2016, Shaohua Li wrote: > > > The mddev->flags are used for different purposes. There are a lot of > > places we check/change the flags without masking unrelated flags, we > > could check/change unrelated flags. These usage are most for superblock > > write, so spearate superblock related flags. This should make the code > > clearer and also fix real bugs. > > > > Signed-off-by: Shaohua Li <shli@xxxxxx> > > That real bug would be: > > > md_wakeup_thread(mddev->thread); > > - wait_event(mddev->sb_wait, mddev->flags == 0 || > > + wait_event(mddev->sb_wait, mddev->sb_flags == 0 || > > test_bit(MD_RECOVERY_INTR, &mddev->recovery)); Yes, for the reshape hang. > > mddev->flags used to be called mddev->sb_dirty, before > Commit: 850b2b420cd5 ("[PATCH] md: replace magic numbers in sb_dirty with well defined bit flags") > > Then we added lots of other flags. Now we are going back to the same > idea :-) > > Reviewed-by: NeilBrown <neilb@xxxxxxxx> > > Thanks, > NeilBrown -- To unsubscribe from this list: send the line "unsubscribe linux-raid" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html