From: Jean Delvare <jdelvare@suse.de>
To: linux-block@vger.kernel.org
Cc: Jens Axboe <axboe@kernel.dk>, Hannes Reinecke <hare@suse.com>
Subject: [PATCH v3] block: copy ioprio in __bio_clone_fast()
Date: Mon, 12 Nov 2018 10:29:59 +0100 [thread overview]
Message-ID: <20181112102959.6d2f4984@endymion> (raw)
From: Hannes Reinecke <hare@suse.com>
We need to copy the io priority, too; otherwise the clone will run
with a different priority than the original one.
Fixes: 43b62ce3ff0a ("block: move bio io prio to a new field")
Signed-off-by: Hannes Reinecke <hare@suse.com>
Signed-off-by: Jean Delvare <jdelvare@suse.de>
---
Changes since v2:
* Rebased on kernel v4.20-rc2.
block/bio.c | 1 +
block/bounce.c | 1 +
2 files changed, 2 insertions(+)
--- linux-4.20-rc2.orig/block/bio.c 2018-11-12 10:00:34.875181186 +0100
+++ linux-4.20-rc2/block/bio.c 2018-11-12 10:00:42.804275169 +0100
@@ -608,6 +608,7 @@ void __bio_clone_fast(struct bio *bio, s
bio->bi_write_hint = bio_src->bi_write_hint;
bio->bi_iter = bio_src->bi_iter;
bio->bi_io_vec = bio_src->bi_io_vec;
+ bio->bi_ioprio = bio_src->bi_ioprio;
bio_clone_blkcg_association(bio, bio_src);
}
--- linux-4.20-rc2.orig/block/bounce.c 2018-11-12 09:34:19.478031060 +0100
+++ linux-4.20-rc2/block/bounce.c 2018-11-12 10:04:25.742906302 +0100
@@ -251,6 +251,7 @@ static struct bio *bounce_clone_bio(stru
bio->bi_write_hint = bio_src->bi_write_hint;
bio->bi_iter.bi_sector = bio_src->bi_iter.bi_sector;
bio->bi_iter.bi_size = bio_src->bi_iter.bi_size;
+ bio->bi_ioprio = bio_src->bi_ioprio;
switch (bio_op(bio)) {
case REQ_OP_DISCARD:
--
Jean Delvare
SUSE L3 Support
next reply other threads:[~2018-11-12 9:29 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-12 9:29 Jean Delvare [this message]
2018-11-12 17:36 ` [PATCH v3] block: copy ioprio in __bio_clone_fast() Jens Axboe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20181112102959.6d2f4984@endymion \
--to=jdelvare@suse.de \
--cc=axboe@kernel.dk \
--cc=hare@suse.com \
--cc=linux-block@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).