aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/block/drbd/drbd_main.c
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2013-05-05 21:52:57 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2013-05-07 02:16:21 -0400
commitdb2a144bedd58b3dcf19950c2f476c58c9f39d18 (patch)
tree931f1b5a8e6bafe388b317bce02a9fd9af309d38 /drivers/block/drbd/drbd_main.c
parenta8ca889ed9585894d53fd8919d80cbe8baff09e7 (diff)
block_device_operations->release() should return void
The value passed is 0 in all but "it can never happen" cases (and those only in a couple of drivers) *and* it would've been lost on the way out anyway, even if something tried to pass something meaningful. Just don't bother. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'drivers/block/drbd/drbd_main.c')
-rw-r--r--drivers/block/drbd/drbd_main.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/block/drbd/drbd_main.c b/drivers/block/drbd/drbd_main.c
index e98da675f0c1..298b868910dc 100644
--- a/drivers/block/drbd/drbd_main.c
+++ b/drivers/block/drbd/drbd_main.c
@@ -63,7 +63,7 @@ int drbd_asender(struct drbd_thread *);
63 63
64int drbd_init(void); 64int drbd_init(void);
65static int drbd_open(struct block_device *bdev, fmode_t mode); 65static int drbd_open(struct block_device *bdev, fmode_t mode);
66static int drbd_release(struct gendisk *gd, fmode_t mode); 66static void drbd_release(struct gendisk *gd, fmode_t mode);
67static int w_md_sync(struct drbd_work *w, int unused); 67static int w_md_sync(struct drbd_work *w, int unused);
68static void md_sync_timer_fn(unsigned long data); 68static void md_sync_timer_fn(unsigned long data);
69static int w_bitmap_io(struct drbd_work *w, int unused); 69static int w_bitmap_io(struct drbd_work *w, int unused);
@@ -1849,13 +1849,12 @@ static int drbd_open(struct block_device *bdev, fmode_t mode)
1849 return rv; 1849 return rv;
1850} 1850}
1851 1851
1852static int drbd_release(struct gendisk *gd, fmode_t mode) 1852static void drbd_release(struct gendisk *gd, fmode_t mode)
1853{ 1853{
1854 struct drbd_conf *mdev = gd->private_data; 1854 struct drbd_conf *mdev = gd->private_data;
1855 mutex_lock(&drbd_main_mutex); 1855 mutex_lock(&drbd_main_mutex);
1856 mdev->open_cnt--; 1856 mdev->open_cnt--;
1857 mutex_unlock(&drbd_main_mutex); 1857 mutex_unlock(&drbd_main_mutex);
1858 return 0;
1859} 1858}
1860 1859
1861static void drbd_set_defaults(struct drbd_conf *mdev) 1860static void drbd_set_defaults(struct drbd_conf *mdev)