summaryrefslogtreecommitdiff
path: root/drivers/block/drbd/drbd_worker.c
diff options
context:
space:
mode:
authorLars Ellenberg <lars.ellenberg@linbit.com>2012-03-26 19:06:29 +0400
committerPhilipp Reisner <philipp.reisner@linbit.com>2012-11-08 19:58:24 +0400
commit2415308eb94e7bddf9c9a0f210374600210274d7 (patch)
tree7f29fa607205f674f01da1365cdad72e27a7450f /drivers/block/drbd/drbd_worker.c
parent6870ca6d463e195cf13589e90f8281648b389909 (diff)
downloadlinux-2415308eb94e7bddf9c9a0f210374600210274d7.tar.xz
drbd: move put_ldev from __req_mod() to the endio callback
Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com> Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
Diffstat (limited to 'drivers/block/drbd/drbd_worker.c')
-rw-r--r--drivers/block/drbd/drbd_worker.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/block/drbd/drbd_worker.c b/drivers/block/drbd/drbd_worker.c
index 3adbc5a29702..f10451701cdb 100644
--- a/drivers/block/drbd/drbd_worker.c
+++ b/drivers/block/drbd/drbd_worker.c
@@ -238,6 +238,7 @@ void drbd_request_endio(struct bio *bio, int error)
spin_lock_irqsave(&mdev->tconn->req_lock, flags);
__req_mod(req, what, &m);
spin_unlock_irqrestore(&mdev->tconn->req_lock, flags);
+ put_ldev(mdev);
if (m.bio)
complete_master_bio(mdev, &m);