aboutsummaryrefslogtreecommitdiff
path: root/fs/nilfs2/segbuf.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-08-23 09:52:32 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2013-08-23 09:52:32 -0700
commit3db0d4defc36fd9ea4d8e09170d4584d41024cd6 (patch)
tree78ee6d6839fce9c0065eeb996a95cc531b74200a /fs/nilfs2/segbuf.c
parent6a7492a4b2e05051a44458d7187023e22d580666 (diff)
parentee8a99bdb47f32327bdfaffe35b900ca7161ba4e (diff)
downloadlinux-stericsson-3db0d4defc36fd9ea4d8e09170d4584d41024cd6.tar.gz
Merge branch 'akpm' (patches from Andrew Morton)
Merge fixes from Andrew Morton: "A few fixes. One is a licensing change and I don't do licensing, so please eyeball that one" Licensing eye-balled. * emailed patches from Andrew Morton <akpm@linux-foundation.org>: lib/lz4: correct the LZ4 license memcg: get rid of swapaccount leftovers nilfs2: fix issue with counting number of bio requests for BIO_EOPNOTSUPP error detection nilfs2: remove double bio_put() in nilfs_end_bio_write() for BIO_EOPNOTSUPP error drivers/platform/olpc/olpc-ec.c: initialise earlier
Diffstat (limited to 'fs/nilfs2/segbuf.c')
-rw-r--r--fs/nilfs2/segbuf.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/nilfs2/segbuf.c b/fs/nilfs2/segbuf.c
index dc9a913784ab..2d8be51f90dc 100644
--- a/fs/nilfs2/segbuf.c
+++ b/fs/nilfs2/segbuf.c
@@ -345,8 +345,7 @@ static void nilfs_end_bio_write(struct bio *bio, int err)
if (err == -EOPNOTSUPP) {
set_bit(BIO_EOPNOTSUPP, &bio->bi_flags);
- bio_put(bio);
- /* to be detected by submit_seg_bio() */
+ /* to be detected by nilfs_segbuf_submit_bio() */
}
if (!uptodate)
@@ -377,12 +376,12 @@ static int nilfs_segbuf_submit_bio(struct nilfs_segment_buffer *segbuf,
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;
}
- segbuf->sb_nbio++;
bio_put(bio);
wi->bio = NULL;