linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johannes Thumshirn <jthumshirn@suse.de>
To: Qu Wenruo <wqu@suse.com>, linux-btrfs@vger.kernel.org
Cc: Nikolay Borisov <nborisov@suse.com>
Subject: Re: [PATCH v2 4/5] btrfs: disk-io: Show the timing of corrupted tree block explicitly
Date: Thu, 17 Jan 2019 14:36:23 +0100	[thread overview]
Message-ID: <1d2c7fbe-eb9d-9ab1-8d2b-82e475bf312c@suse.de> (raw)
In-Reply-To: <20190117101528.8675-5-wqu@suse.com>

On 17/01/2019 11:15, Qu Wenruo wrote:
> Just add one extra line to show when the corruption is detected.
> Currently only read time detection is possible.
> 
> Reviewed-by: Nikolay Borisov <nborisov@suse.com>
> Signed-off-by: Qu Wenruo <wqu@suse.com>
> ---
>  fs/btrfs/disk-io.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c
> index 659bab9de03b..bc2379cb2091 100644
> --- a/fs/btrfs/disk-io.c
> +++ b/fs/btrfs/disk-io.c
> @@ -652,11 +652,14 @@ static int btree_readpage_end_io_hook(struct btrfs_io_bio *io_bio,
>  	 */
>  	if (found_level == 0 && btrfs_check_leaf_full(fs_info, eb)) {
>  		set_bit(EXTENT_BUFFER_CORRUPT, &eb->bflags);
> +		btrfs_err(fs_info, "read time tree block corruption detected");
>  		ret = -EIO;
>  	}
>  
> -	if (found_level > 0 && btrfs_check_node(fs_info, eb))
> +	if (found_level > 0 && btrfs_check_node(fs_info, eb)) {
> +		btrfs_err(fs_info, "read time tree block corruption detected");
>  		ret = -EIO;
> +	}

It's still the same error message for two different checks (check_node
vs. check_leaf_full).

Granted you can still refer to the messages of btrfs_check_node() and
btrfs_check_leaf_full() but where's the point in having the new message?

Byte,
	Johannes
-- 
Johannes Thumshirn                            SUSE Labs Filesystems
jthumshirn@suse.de                                +49 911 74053 689
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: Felix Imendörffer, Jane Smithard, Graham Norton
HRB 21284 (AG Nürnberg)
Key fingerprint = EC38 9CAB C2C4 F25D 8600 D0D0 0393 969D 2D76 0850

  reply	other threads:[~2019-01-17 13:36 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-17 10:15 [PATCH v2 0/5] btrfs: Enhancement to tree block validation Qu Wenruo
2019-01-17 10:15 ` [PATCH v2 1/5] btrfs: Always output error message when key/level verification fails Qu Wenruo
2019-01-17 13:14   ` Johannes Thumshirn
2019-01-17 13:25     ` Qu Wenruo
2019-01-17 10:15 ` [PATCH v2 2/5] btrfs: extent_io: Kill the forward declaration of flush_write_bio() Qu Wenruo
2019-01-17 13:22   ` Johannes Thumshirn
2019-01-17 10:15 ` [PATCH v2 3/5] btrfs: extent_io: Kill the BUG_ON() in flush_write_bio() Qu Wenruo
2019-01-17 10:15 ` [PATCH v2 4/5] btrfs: disk-io: Show the timing of corrupted tree block explicitly Qu Wenruo
2019-01-17 13:36   ` Johannes Thumshirn [this message]
2019-01-17 13:42     ` Qu Wenruo
2019-01-17 14:08       ` Johannes Thumshirn
2019-01-17 14:29         ` Qu Wenruo
2019-01-17 10:15 ` [PATCH v2 5/5] btrfs: Do mandatory tree block check before submitting bio Qu Wenruo

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=1d2c7fbe-eb9d-9ab1-8d2b-82e475bf312c@suse.de \
    --to=jthumshirn@suse.de \
    --cc=linux-btrfs@vger.kernel.org \
    --cc=nborisov@suse.com \
    --cc=wqu@suse.com \
    /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).