Commit e656ec8a authored by Philipp Reisner's avatar Philipp Reisner

Do not deadlock in drbd_disconnect() [bugz 258]

When there are many blocks on the fly (ua), and the AL gets into "starving"
mode (random IO, scattered all over the device), and the connections gets
interrupted, the receiver thread deadlocks in the drbd_disconnect() code path.

Affected are only nodes in Primary role.

The bug triggers most likely on system that mirror over "long distances"

Regression introduced shortly before 8.3.3
with git commit 31e0f1250f174ac1ee317f360943a0159e19edc8
Signed-off-by: default avatarPhilipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: default avatarLars Ellenberg <lars.ellenberg@linbit.com>
parent 0a492166
...@@ -3619,10 +3619,6 @@ static void drbd_disconnect(struct drbd_conf *mdev) ...@@ -3619,10 +3619,6 @@ static void drbd_disconnect(struct drbd_conf *mdev)
set_bit(STOP_SYNC_TIMER, &mdev->flags); set_bit(STOP_SYNC_TIMER, &mdev->flags);
resync_timer_fn((unsigned long)mdev); resync_timer_fn((unsigned long)mdev);
/* so we can be sure that all remote or resync reads
* made it at least to net_ee */
wait_event(mdev->misc_wait, !atomic_read(&mdev->local_cnt));
/* wait for all w_e_end_data_req, w_e_end_rsdata_req, w_send_barrier, /* wait for all w_e_end_data_req, w_e_end_rsdata_req, w_send_barrier,
* w_make_resync_request etc. which may still be on the worker queue * w_make_resync_request etc. which may still be on the worker queue
* to be "canceled" */ * to be "canceled" */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment