aboutsummaryrefslogtreecommitdiff
path: root/drivers/block/genhd.c
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2005-05-05 16:15:59 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-05-05 16:36:44 -0700
commit2ef41634def0fcb0def3e3c90220c651ca478cb3 (patch)
tree86fb9c439ad5043d38d69588975e84bd8b565619 /drivers/block/genhd.c
parent91bb52416854dfd581efe6e2a0aca8dc655f043e (diff)
[PATCH] remove do_sync parameter from __invalidate_device
The only caller that ever sets it can call fsync_bdev itself easily. Also update some comments. Signed-off-by: Christoph Hellwig <hch@lst.de> Cc: <viro@parcelfarce.linux.theplanet.co.uk> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/block/genhd.c')
-rw-r--r--drivers/block/genhd.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/block/genhd.c b/drivers/block/genhd.c
index ab4db71375e..8bbe01d4b48 100644
--- a/drivers/block/genhd.c
+++ b/drivers/block/genhd.c
@@ -14,6 +14,7 @@
#include <linux/slab.h>
#include <linux/kmod.h>
#include <linux/kobj_map.h>
+#include <linux/buffer_head.h>
#define MAX_PROBE_HASH 255 /* random */
@@ -676,7 +677,8 @@ int invalidate_partition(struct gendisk *disk, int index)
int res = 0;
struct block_device *bdev = bdget_disk(disk, index);
if (bdev) {
- res = __invalidate_device(bdev, 1);
+ fsync_bdev(bdev);
+ res = __invalidate_device(bdev);
bdput(bdev);
}
return res;