Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
drbd: don't increase unacked_cnt when error is from resync write
In drbd_endio_write_sec_final(), if a write error has occured and the protocol is not 'C', inc_unacked() will be called. But when it is a resync write, we shouldn't increase unacked_cnt there because of there is no corresponding dec_unacked(). If we do then unacked_cnt will never be zero, which leads to the problem that in do_start_resync(), start_resync_timer() will be scheduled over and over again and the resync will never start. Fix this problem by adding a condition in drbd_endio_write_sec_final(). When the error is from a resync write, don't increase unacked_cnt. Signed-off-by: Rui Xu <rui.xu@easystack.cn> Signed-off-by: Joel Colledge <joel.colledge@linbit.com>
- Loading branch information