• N
    md/raid1: clean up request counts properly in close_sync() · 669cc7ba
    NeilBrown 提交于
    If there are outstanding writes when close_sync is called,
    the change to ->start_next_window might cause them to
    decrement the wrong counter when they complete.  Fix this
    by merging the two counters into the one that will be decremented.
    
    Having an incorrect value in a counter can cause raise_barrier()
    to hangs, so this is suitable for -stable.
    
    Fixes: 79ef3a8a
    cc: stable@vger.kernel.org (v3.13+)
    Signed-off-by: NNeilBrown <neilb@suse.de>
    669cc7ba
raid1.c 86.9 KB