diff options
author | Andreas Gruenbacher <agruen@linbit.com> | 2011-03-16 15:31:39 +0100 |
---|---|---|
committer | Philipp Reisner <philipp.reisner@linbit.com> | 2012-11-08 16:44:43 +0100 |
commit | 99920dc5c5fe52182fe922aa70330861e2b6418b (patch) | |
tree | 51890fb25f704bf1cbea56695d794be8166deb81 /drivers/block/drbd/drbd_actlog.c | |
parent | b2f0ab62ecfe8711fefb82223b40430f8141a949 (diff) | |
download | op-kernel-dev-99920dc5c5fe52182fe922aa70330861e2b6418b.zip op-kernel-dev-99920dc5c5fe52182fe922aa70330861e2b6418b.tar.gz |
drbd: Make all worker callbacks return 0 upon success and an error code otherwise
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 | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/block/drbd/drbd_actlog.c b/drivers/block/drbd/drbd_actlog.c index ac96cf9..fe60b18 100644 --- a/drivers/block/drbd/drbd_actlog.c +++ b/drivers/block/drbd/drbd_actlog.c @@ -106,7 +106,7 @@ struct drbd_atodb_wait { }; -static long w_al_write_transaction(struct drbd_work *, int); +static int w_al_write_transaction(struct drbd_work *, int); static int _drbd_md_sync_page_io(struct drbd_conf *mdev, struct drbd_backing_dev *bdev, @@ -298,7 +298,7 @@ static unsigned int rs_extent_to_bm_page(unsigned int rs_enr) (BM_EXT_SHIFT - BM_BLOCK_SHIFT)); } -static long +static int w_al_write_transaction(struct drbd_work *w, int unused) { struct update_al_work *aw = container_of(w, struct update_al_work, w); @@ -315,7 +315,7 @@ w_al_write_transaction(struct drbd_work *w, int unused) drbd_disk_str(mdev->state.disk)); aw->err = -EIO; complete(&((struct update_al_work *)w)->event); - return 1; + return 0; } /* The bitmap write may have failed, causing a state change. */ @@ -326,7 +326,7 @@ w_al_write_transaction(struct drbd_work *w, int unused) aw->err = -EIO; complete(&((struct update_al_work *)w)->event); put_ldev(mdev); - return 1; + return 0; } mutex_lock(&mdev->md_io_mutex); /* protects md_io_buffer, al_tr_cycle, ... */ @@ -404,7 +404,7 @@ w_al_write_transaction(struct drbd_work *w, int unused) complete(&((struct update_al_work *)w)->event); put_ldev(mdev); - return 1; + return 0; } /* FIXME @@ -698,7 +698,7 @@ void drbd_al_shrink(struct drbd_conf *mdev) wake_up(&mdev->al_wait); } -static long w_update_odbm(struct drbd_work *w, int unused) +static int w_update_odbm(struct drbd_work *w, int unused) { struct update_odbm_work *udw = container_of(w, struct update_odbm_work, w); struct drbd_conf *mdev = w->mdev; @@ -708,7 +708,7 @@ static long w_update_odbm(struct drbd_work *w, int unused) if (__ratelimit(&drbd_ratelimit_state)) dev_warn(DEV, "Can not update on disk bitmap, local IO disabled.\n"); kfree(udw); - return 1; + return 0; } drbd_bm_write_page(mdev, rs_extent_to_bm_page(udw->enr)); @@ -728,7 +728,7 @@ static long w_update_odbm(struct drbd_work *w, int unused) } drbd_bcast_event(mdev, &sib); - return 1; + return 0; } |