md: fix possible raid1/raid10 deadlock on read error during resync