summaryrefslogtreecommitdiffstats
path: root/drivers/block
diff options
context:
space:
mode:
authorPhilipp Reisner <philipp.reisner@linbit.com>2010-09-09 14:22:21 +0200
committerPhilipp Reisner <philipp.reisner@linbit.com>2010-10-14 18:38:38 +0200
commit5a75cc7cfbb98e896232902214432dae30653dfe (patch)
tree278a4625bc5ba0bd406357c2ef4450e9c98eb188 /drivers/block
parentf2906e183f5460df9d9e774f5952f5ff670b3913 (diff)
downloadop-kernel-dev-5a75cc7cfbb98e896232902214432dae30653dfe.zip
op-kernel-dev-5a75cc7cfbb98e896232902214432dae30653dfe.tar.gz
drbd: Fixed compatibility with protocol versions smaller than 95
Forgot to consider the max size for the resync requests. Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com> Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
Diffstat (limited to 'drivers/block')
-rw-r--r--drivers/block/drbd/drbd_worker.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/block/drbd/drbd_worker.c b/drivers/block/drbd/drbd_worker.c
index c72a5fc..daa672f 100644
--- a/drivers/block/drbd/drbd_worker.c
+++ b/drivers/block/drbd/drbd_worker.c
@@ -534,8 +534,9 @@ int w_make_resync_request(struct drbd_conf *mdev,
/* starting with drbd 8.3.8, we can handle multi-bio EEs,
* if it should be necessary */
- max_segment_size = mdev->agreed_pro_version < 94 ?
- queue_max_segment_size(mdev->rq_queue) : DRBD_MAX_SEGMENT_SIZE;
+ max_segment_size =
+ mdev->agreed_pro_version < 94 ? queue_max_segment_size(mdev->rq_queue) :
+ mdev->agreed_pro_version < 95 ? DRBD_MAX_SIZE_H80_PACKET : DRBD_MAX_SEGMENT_SIZE;
if (mdev->rs_plan_s.size) { /* mdev->sync_conf.c_plan_ahead */
number = drbd_rs_controller(mdev) >> (BM_BLOCK_SHIFT - 9);
OpenPOWER on IntegriCloud