From: Andreas Dilger <adilger@dilger.ca>
To: Ye Bin <yebin10@huawei.com>
Cc: "Theodore Y. Ts'o" <tytso@mit.edu>,
Ext4 Developers List <linux-ext4@vger.kernel.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Liu Zhi Qiang <liuzhiqiang26@huawei.com>
Subject: Re: [PATCH] ext4: Fix ext4_error_err save negative errno into superblock
Date: Thu, 1 Apr 2021 19:11:57 -0600 [thread overview]
Message-ID: <7103B623-9FD2-4BD2-8A44-8DBE38DFE291@dilger.ca> (raw)
In-Reply-To: <20210401072234.3338057-1-yebin10@huawei.com>
[-- Attachment #1: Type: text/plain, Size: 1258 bytes --]
On Apr 1, 2021, at 1:22 AM, Ye Bin <yebin10@huawei.com> wrote:
>
> As read_mmp_block return 1 when failed, so just pass retval to
> save_error_info.
Thank you for submitting this patch, but it should not be accepted.
The commit message is confusing, since the code being changed relates
to retval from write_mmp_block(). That currently returns 1, but
only until your next patch is applied.
I think it is better to fix write_mmp_block() as in your next patch
to return a negative value to be more consistent with other code.
Cheers, Andreas
> Fixes: 54d3adbc29f0 ("ext4: save all error info in save_error_info() and
> drop ext4_set_errno()")
> Reported-by: Liu Zhi Qiang <liuzhiqiang26@huawei.com>
> Signed-off-by: Ye Bin <yebin10@huawei.com>
> ---
> fs/ext4/mmp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/ext4/mmp.c b/fs/ext4/mmp.c
> index 795c3ff2907c..bb8353e25841 100644
> --- a/fs/ext4/mmp.c
> +++ b/fs/ext4/mmp.c
> @@ -171,7 +171,7 @@ static int kmmpd(void *data)
> */
> if (retval) {
> if ((failed_writes % 60) == 0) {
> - ext4_error_err(sb, -retval,
> + ext4_error_err(sb, retval,
> "Error writing to MMP block");
> }
> failed_writes++;
> --
> 2.25.4
>
Cheers, Andreas
[-- Attachment #2: Message signed with OpenPGP --]
[-- Type: application/pgp-signature, Size: 873 bytes --]
prev parent reply other threads:[~2021-04-02 1:12 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-01 7:22 Ye Bin
2021-04-02 1:11 ` Andreas Dilger [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=7103B623-9FD2-4BD2-8A44-8DBE38DFE291@dilger.ca \
--to=adilger@dilger.ca \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=liuzhiqiang26@huawei.com \
--cc=tytso@mit.edu \
--cc=yebin10@huawei.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
all inboxes | Powered by JetHome®