diff options
author | Lars Ellenberg <lars.ellenberg@linbit.com> | 2011-03-31 15:18:56 +0200 |
---|---|---|
committer | Philipp Reisner <philipp.reisner@linbit.com> | 2012-11-08 16:45:01 +0100 |
commit | 181286ad22bf9bfb85de625e8501285de5261b35 (patch) | |
tree | 02ea5a0be7525834ed51a875d661872bd2047c60 /drivers/block/drbd/drbd_actlog.c | |
parent | 85f103d88c8eb91755eb3c103e5ead2c9389e35e (diff) | |
download | op-kernel-dev-181286ad22bf9bfb85de625e8501285de5261b35.zip op-kernel-dev-181286ad22bf9bfb85de625e8501285de5261b35.tar.gz |
drbd: preparation commit, pass drbd_interval to drbd_al_begin/complete_io
We want to avoid bio_split for bios crossing activity log boundaries.
So we may need to activate two activity log extents "atomically".
drbd_al_begin_io() needs to know more than just the start sector.
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_actlog.c')
-rw-r--r-- | drivers/block/drbd/drbd_actlog.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/block/drbd/drbd_actlog.c b/drivers/block/drbd/drbd_actlog.c index 90ebbbb..5f0eeb7 100644 --- a/drivers/block/drbd/drbd_actlog.c +++ b/drivers/block/drbd/drbd_actlog.c @@ -205,9 +205,9 @@ static struct lc_element *_al_get(struct drbd_conf *mdev, unsigned int enr) return al_ext; } -void drbd_al_begin_io(struct drbd_conf *mdev, sector_t sector) +void drbd_al_begin_io(struct drbd_conf *mdev, struct drbd_interval *i) { - unsigned int enr = (sector >> (AL_EXTENT_SHIFT-9)); + unsigned int enr = (i->sector >> (AL_EXTENT_SHIFT-9)); struct lc_element *al_ext; struct update_al_work al_work; @@ -254,9 +254,9 @@ void drbd_al_begin_io(struct drbd_conf *mdev, sector_t sector) } } -void drbd_al_complete_io(struct drbd_conf *mdev, sector_t sector) +void drbd_al_complete_io(struct drbd_conf *mdev, struct drbd_interval *i) { - unsigned int enr = (sector >> (AL_EXTENT_SHIFT-9)); + unsigned int enr = (i->sector >> (AL_EXTENT_SHIFT-9)); struct lc_element *extent; unsigned long flags; |