mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 19:51:31 -04:00
block: remove BIO_EOPNOTSUPP
Since the big barrier rewrite/removal in 2007 we never fail FLUSH or FUA requests, which means we can remove the magic BIO_EOPNOTSUPP flag to help propagating those to the buffer_head layer. Signed-off-by: Christoph Hellwig <[email protected]> Reviewed-by: Jeff Moyer <[email protected]> Acked-by: Tejun Heo <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
This commit is contained in:
parent
4ecd4fef3a
commit
b25de9d6da
7 changed files with 2 additions and 38 deletions
|
|
@ -343,11 +343,6 @@ static void nilfs_end_bio_write(struct bio *bio, int err)
|
|||
const int uptodate = test_bit(BIO_UPTODATE, &bio->bi_flags);
|
||||
struct nilfs_segment_buffer *segbuf = bio->bi_private;
|
||||
|
||||
if (err == -EOPNOTSUPP) {
|
||||
set_bit(BIO_EOPNOTSUPP, &bio->bi_flags);
|
||||
/* to be detected by nilfs_segbuf_submit_bio() */
|
||||
}
|
||||
|
||||
if (!uptodate)
|
||||
atomic_inc(&segbuf->sb_err);
|
||||
|
||||
|
|
@ -374,15 +369,8 @@ static int nilfs_segbuf_submit_bio(struct nilfs_segment_buffer *segbuf,
|
|||
|
||||
bio->bi_end_io = nilfs_end_bio_write;
|
||||
bio->bi_private = segbuf;
|
||||
bio_get(bio);
|
||||
submit_bio(mode, bio);
|
||||
segbuf->sb_nbio++;
|
||||
if (bio_flagged(bio, BIO_EOPNOTSUPP)) {
|
||||
bio_put(bio);
|
||||
err = -EOPNOTSUPP;
|
||||
goto failed;
|
||||
}
|
||||
bio_put(bio);
|
||||
|
||||
wi->bio = NULL;
|
||||
wi->rest_blocks -= wi->end - wi->start;
|
||||
|
|
|
|||
Loading…
Reference in a new issue