You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
drbd: Call drbd_md_sync() explicitly after a state change on the connection
Without this, the meta-data gets updates after 5 seconds by the md_sync_timer. Better to do it immeditaly after a state change. If the asender detects a network failure, it may take a bit until the worker processes the according after-conn-state-change work item. The worker might be blocked in sending something, i.e. it takes until it gets into its timeout. That is 6 seconds by default which is longer than the 5 seconds of the md_sync_timer. Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com> Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
This commit is contained in:
@@ -363,22 +363,6 @@ int drbd_khelper(struct drbd_conf *mdev, char *cmd)
|
||||
return ret;
|
||||
}
|
||||
|
||||
static void conn_md_sync(struct drbd_tconn *tconn)
|
||||
{
|
||||
struct drbd_conf *mdev;
|
||||
int vnr;
|
||||
|
||||
rcu_read_lock();
|
||||
idr_for_each_entry(&tconn->volumes, mdev, vnr) {
|
||||
kref_get(&mdev->kref);
|
||||
rcu_read_unlock();
|
||||
drbd_md_sync(mdev);
|
||||
kref_put(&mdev->kref, &drbd_minor_destroy);
|
||||
rcu_read_lock();
|
||||
}
|
||||
rcu_read_unlock();
|
||||
}
|
||||
|
||||
int conn_khelper(struct drbd_tconn *tconn, char *cmd)
|
||||
{
|
||||
char *envp[] = { "HOME=/",
|
||||
|
||||
Reference in New Issue
Block a user