From: Anand Jain <anand.jain@oracle.com>
To: dsterba@suse.cz
Cc: linux-btrfs@vger.kernel.org
Subject: Re: [PATCH] btrfs: delete unused member nobarriers
Date: Tue, 4 Apr 2017 18:59:19 +0800 [thread overview]
Message-ID: <735d9ef3-c3f2-2a2d-af7e-b65a8980e423@oracle.com> (raw)
In-Reply-To: <20170403120639.GS4781@twin.jikos.cz>
On 04/03/2017 08:06 PM, David Sterba wrote:
> Please update the changelog to say why it's ok to remove it, eg. the
> commit that removed the last user.
>
> commit b25de9d6da49b1a8760a89672283128aa8c78345
> Author: Christoph Hellwig <hch@lst.de>
> Date: Fri Apr 24 21:41:01 2015 +0200
>
> block: remove BIO_EOPNOTSUPP
Ah. I should have search the commit log. sorry about that.
IMO, there is a bug in generic_make_request_checks() in which
it should rather return EOPNOTSUPP, instead of EIO if QUEUE_FLAG_WC
is not supported.
------------------------------------------------
1853 static noinline_for_stack bool
1854 generic_make_request_checks(struct bio *bio)
1855 {
::
1892 /*
1893 * Filter flush bio's early so that make_request based
1894 * drivers without flush support don't have to worry
1895 * about them.
1896 */
1897 if ((bio->bi_opf & (REQ_PREFLUSH | REQ_FUA)) &&
1898 !test_bit(QUEUE_FLAG_WC, &q->queue_flags)) {
1899 bio->bi_opf &= ~(REQ_PREFLUSH | REQ_FUA);
1900 if (!nr_sectors) {
1901 err = 0;
1902 goto end_io; <- this should goto not_supported
1903 }
1904 }
::
1946 not_supported:
1947 err = -EOPNOTSUPP;
------------------------------------------------
Pls ignore this patch.
I have submitted
[PATCH] btrfs: check if the device is flush capable
which will remain unaffected by the above bug/not-a-bug
in the blk core code.
Thanks, Anand
> Otherwise the patch is ok.
next prev parent reply other threads:[~2017-04-04 10:54 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-31 11:26 [PATCH] btrfs: delete unused member nobarriers Anand Jain
2017-04-03 12:06 ` David Sterba
2017-04-04 10:59 ` Anand Jain [this message]
2017-04-05 13:26 ` David Sterba
2017-04-05 3:51 ` [PATCH v2] " Anand Jain
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=735d9ef3-c3f2-2a2d-af7e-b65a8980e423@oracle.com \
--to=anand.jain@oracle.com \
--cc=dsterba@suse.cz \
--cc=linux-btrfs@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).