Skip to content

Commit

Permalink
VDEV_REQ_FUA should be mapped to REQ_FUA
Browse files Browse the repository at this point in the history
Pre-2.6.37 kernels support REQ_FUA in request flags, but not in BIO
flags. zvols are the only consumer of VDEV_REQ_FUA and since they are
passed requests, they should be obey the REQ_FUA flag like later
kernels. This optimization will only matter on 2.6.36 and 2.6.37 because
the zvol rework changes things to use bio, where we no longer are able
to distinguish on earlier kernels

Signed-off-by: Richard Yao <ryao@gentoo.org>
  • Loading branch information
ryao committed Sep 2, 2015
1 parent 69de342 commit 782b2c3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/linux/blkdev_compat.h
Original file line number Diff line number Diff line change
Expand Up @@ -458,7 +458,7 @@ bio_set_flags_failfast(struct block_device *bdev, int *flags)
#else
#define VDEV_WRITE_FLUSH_FUA WRITE_BARRIER
#define VDEV_REQ_FLUSH REQ_HARDBARRIER
#define VDEV_REQ_FUA REQ_HARDBARRIER
#define VDEV_REQ_FUA REQ_FUA
#endif

/*
Expand Down

0 comments on commit 782b2c3

Please sign in to comment.