| To: | axboe <axboe@xxxxxxxxx>, "konrad.wilk" <konrad.wilk@xxxxxxxxxx>, "chris.mason" <chris.mason@xxxxxxxxxxxx>, viro <viro@xxxxxxxxxxxxxxxxxx>, tytso <tytso@xxxxxxx>, "adilger.kernel" <adilger.kernel@xxxxxxxxx>, shaggy <shaggy@xxxxxxxxxx>, mfasheh <mfasheh@xxxxxxxx>, jlbec <jlbec@xxxxxxxxxxxx>, bpm <bpm@xxxxxxx>, elder <elder@xxxxxxxxxx> |
|---|---|
| Subject: | [PATCH 5/8]fs/ext4: Evalue bio->bi_rw after calling bio_alloc() and before calling bio_add_page(). |
| From: | majianpeng <majianpeng@xxxxxxxxx> |
| Date: | Mon, 30 Jul 2012 15:24:24 +0800 |
| Cc: | linux-kernel <linux-kernel@xxxxxxxxxxxxxxx>, linux-btrfs <linux-btrfs@xxxxxxxxxxxxxxx>, linux-fsdevel <linux-fsdevel@xxxxxxxxxxxxxxx>, linux-ext4 <linux-ext4@xxxxxxxxxxxxxxx>, jfs-discussion <jfs-discussion@xxxxxxxxxxxxxxxxxxxxx>, xfs <xfs@xxxxxxxxxxx> |
| Dkim-signature: | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:x-priority:x-has-attach:x-mailer :mime-version:message-id:content-type:content-transfer-encoding; bh=IRslP8HgrZaOd9NS9WGZ1U+mCTzM3jt1+CV8F8lXVls=; b=RKC9tzy8gOcbl3LbhZjQGYFeu1Z+l8jhQfzXQ7aliPuGRwJZMf4hgRwMn7UfJMWVyE alCC/NFhcCb/+8ejlwC4XgPWwbN2Ydk9SOxqP3Bv6pUQCY9JzCO5VaTH3vUEncrxPzce bAmEwgDma+kTdkMP2dLBWMn0beOKwU0b53skqP91uP9VaWuVvQq40UDbsotdPuAV6gmt MXWEUWUHYgslmI/XO7YhtqCY3HlamQc5ToaaxwB2LofuyqfjRm2p4+Orx15U10YA/fC5 JVPkGGZbYFHZDL1XsSvvRPmt3JArFzLs5Si7iWUPofHY+Alyw2mMBDFtIuOlQiv/wdA/ 1bTQ== |
Because call bio_alloc, the bi_rw is zero by default,but in
bio_add_page used the bi_rw. So evalue bi_rw.
Signed-off-by: Jianpeng Ma <majianpeng@xxxxxxxxx>
---
fs/ext4/page-io.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/fs/ext4/page-io.c b/fs/ext4/page-io.c
index dcdeef1..c875502 100644
--- a/fs/ext4/page-io.c
+++ b/fs/ext4/page-io.c
@@ -304,6 +304,7 @@ static int io_submit_init(struct ext4_io_submit *io,
io->io_bio = bio;
io->io_op = (wbc->sync_mode == WB_SYNC_ALL ? WRITE_SYNC : WRITE);
io->io_next_block = bh->b_blocknr;
+ bio->bi_rw = io->io_op;
return 0;
}
--
1.7.9.5
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | [PATCH 3/8]fs/btrfs: Evalue bio->bi_rw after calling bio_alloc() and before calling bio_add_page()., majianpeng |
|---|---|
| Next by Date: | [PATCH 6/8]fs/jfs: Evalue bio->bi_rw after calling bio_alloc() and before calling bio_add_page()., majianpeng |
| Previous by Thread: | [PATCH 3/8]fs/btrfs: Evalue bio->bi_rw after calling bio_alloc() and before calling bio_add_page()., majianpeng |
| Next by Thread: | [PATCH 6/8]fs/jfs: Evalue bio->bi_rw after calling bio_alloc() and before calling bio_add_page()., majianpeng |
| Indexes: | [Date] [Thread] [Top] [All Lists] |