diff options
author | Lars Ellenberg <lars.ellenberg@linbit.com> | 2012-06-25 13:15:38 -0400 |
---|---|---|
committer | Philipp Reisner <philipp.reisner@linbit.com> | 2012-07-24 09:14:28 -0400 |
commit | a73ff3231df59a4b92ccd0dd4e73897c5822489b (patch) | |
tree | b4a702fefd94689682a6be89773ef7c59f20db59 /drivers/block/drbd/drbd_actlog.c | |
parent | db141b2f42b485b700465fe2401fbe65c65b190c (diff) |
drbd: announce FLUSH/FUA capability to upper layers
Unconditionally announce FLUSH/FUA to upper layers.
If the lower layers on either node do not actually support this,
generic_make_request() will deal with it.
If this causes performance regressions on your setup,
make sure there are no volatile caches involved,
and mount -o nobarrier or equivalent.
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 | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/block/drbd/drbd_actlog.c b/drivers/block/drbd/drbd_actlog.c index 6ace11e9e5a1..3fbef018ce55 100644 --- a/drivers/block/drbd/drbd_actlog.c +++ b/drivers/block/drbd/drbd_actlog.c | |||
@@ -876,7 +876,11 @@ int __drbd_set_out_of_sync(struct drbd_conf *mdev, sector_t sector, int size, | |||
876 | unsigned int enr, count = 0; | 876 | unsigned int enr, count = 0; |
877 | struct lc_element *e; | 877 | struct lc_element *e; |
878 | 878 | ||
879 | if (size <= 0 || (size & 0x1ff) != 0 || size > DRBD_MAX_BIO_SIZE) { | 879 | /* this should be an empty REQ_FLUSH */ |
880 | if (size == 0) | ||
881 | return 0; | ||
882 | |||
883 | if (size < 0 || (size & 0x1ff) != 0 || size > DRBD_MAX_BIO_SIZE) { | ||
880 | dev_err(DEV, "sector: %llus, size: %d\n", | 884 | dev_err(DEV, "sector: %llus, size: %d\n", |
881 | (unsigned long long)sector, size); | 885 | (unsigned long long)sector, size); |
882 | return 0; | 886 | return 0; |