linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Sterba <dsterba@suse.cz>
To: Anand Jain <anand.jain@oracle.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: [PATCH] btrfs: use BLK_STS defines where needed
Date: Mon, 16 Oct 2017 15:44:05 +0200	[thread overview]
Message-ID: <20171016134405.GL3521@twin.jikos.cz> (raw)
In-Reply-To: <20171014003556.8038-1-anand.jain@oracle.com>

On Sat, Oct 14, 2017 at 08:35:56AM +0800, Anand Jain wrote:
> At few places we could use BLK_STS_OK and BLK_STS_NOSUPP.
> 
> Signed-off-by: Anand Jain <anand.jain@oracle.com>
> ---
>  fs/btrfs/compression.c | 3 ++-
>  fs/btrfs/inode.c       | 4 ++--
>  fs/btrfs/volumes.c     | 2 +-
>  3 files changed, 5 insertions(+), 4 deletions(-)
> 
> diff --git a/fs/btrfs/compression.c b/fs/btrfs/compression.c
> index b51d23f5cafa..43d4b51556ec 100644
> --- a/fs/btrfs/compression.c
> +++ b/fs/btrfs/compression.c
> @@ -239,7 +239,8 @@ static void end_compressed_bio_write(struct bio *bio)
>  					 cb->start,
>  					 cb->start + cb->len - 1,
>  					 NULL,
> -					 bio->bi_status ? 0 : 1);
> +					 bio->bi_status ?
> +					 BLK_STS_OK : BLK_STS_NOTSUPP);
>  	cb->compressed_pages[0]->mapping = NULL;
>  
>  	end_compressed_writeback(inode, cb);
> diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c
> index 128f3e58634f..9aa03c89ad86 100644
> --- a/fs/btrfs/inode.c
> +++ b/fs/btrfs/inode.c
> @@ -8360,7 +8360,7 @@ static void btrfs_endio_direct_read(struct bio *bio)
>  	if (dip->flags & BTRFS_DIO_ORIG_BIO_SUBMITTED) {
>  		err = btrfs_subio_endio_read(inode, io_bio, err);
>  		if (!err)
> -			bio->bi_status = 0;
> +			bio->bi_status = BLK_STS_OK;

This hunk does not apply to current devel queue (ie. something close to
for-next), dropped and applied.

      parent reply	other threads:[~2017-10-16 13:45 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-14  0:35 [PATCH] btrfs: use BLK_STS defines where needed Anand Jain
2017-10-14 15:06 ` Satoru Takeuchi
2017-10-16 13:44 ` David Sterba [this message]

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=20171016134405.GL3521@twin.jikos.cz \
    --to=dsterba@suse.cz \
    --cc=anand.jain@oracle.com \
    --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).