提交 83c38830 编写于 作者: L Lars Ellenberg 提交者: Philipp Reisner

drbd: performance - don't lose unplug events

Signed-off-by: NPhilipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: NLars Ellenberg <lars.ellenberg@linbit.com>
上级 e656ec8a
...@@ -505,7 +505,7 @@ void __req_mod(struct drbd_request *req, enum drbd_req_event what, ...@@ -505,7 +505,7 @@ void __req_mod(struct drbd_request *req, enum drbd_req_event what,
* corresponding hlist_del is in _req_may_be_done() */ * corresponding hlist_del is in _req_may_be_done() */
hlist_add_head(&req->colision, ar_hash_slot(mdev, req->sector)); hlist_add_head(&req->colision, ar_hash_slot(mdev, req->sector));
set_bit(UNPLUG_REMOTE, &mdev->flags); /* why? */ set_bit(UNPLUG_REMOTE, &mdev->flags);
D_ASSERT(req->rq_state & RQ_NET_PENDING); D_ASSERT(req->rq_state & RQ_NET_PENDING);
req->rq_state |= RQ_NET_QUEUED; req->rq_state |= RQ_NET_QUEUED;
...@@ -536,6 +536,11 @@ void __req_mod(struct drbd_request *req, enum drbd_req_event what, ...@@ -536,6 +536,11 @@ void __req_mod(struct drbd_request *req, enum drbd_req_event what,
* *
* Add req to the (now) current epoch (barrier). */ * Add req to the (now) current epoch (barrier). */
/* otherwise we may lose an unplug, which may cause some remote
* io-scheduler timeout to expire, increasing maximum latency,
* hurting performance. */
set_bit(UNPLUG_REMOTE, &mdev->flags);
/* see drbd_make_request_common, /* see drbd_make_request_common,
* just after it grabs the req_lock */ * just after it grabs the req_lock */
D_ASSERT(test_bit(CREATE_BARRIER, &mdev->flags) == 0); D_ASSERT(test_bit(CREATE_BARRIER, &mdev->flags) == 0);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册