From: "Theodore Ts'o" <tytso@mit.edu>
To: Zhang Yi <yi.zhang@huawei.com>
Cc: linux-ext4@vger.kernel.org, adilger.kernel@dilger.ca,
jack@suse.cz, yukuai3@huawei.com
Subject: Re: [PATCH] ext4: cleanup in-core orphan list if ext4_truncate() failed to get a transaction handle
Date: Thu, 17 Jun 2021 10:50:02 -0400 [thread overview]
Message-ID: <YMthGuTCuRlZ/zL0@mit.edu> (raw)
In-Reply-To: <20210507071904.160808-1-yi.zhang@huawei.com>
On Fri, May 07, 2021 at 03:19:04PM +0800, Zhang Yi wrote:
> In ext4_orphan_cleanup(), if ext4_truncate() failed to get a transaction
> handle, it didn't remove the inode from the in-core orphan list, which
> may probably trigger below error dump in ext4_destroy_inode() during the
> final iput() and could lead to memory corruption on the later orphan
> list changes.
>
> EXT4-fs (sda): Inode 6291467 (00000000b8247c67): orphan list check failed!
> 00000000b8247c67: 0001f30a 00000004 00000000 00000023 ............#...
> 00000000e24cde71: 00000006 014082a3 00000000 00000000 ......@.........
> 0000000072c6a5ee: 00000000 00000000 00000000 00000000 ................
> ...
>
> This patch fix this by cleanup in-core orphan list manually if
> ext4_truncate() return error.
>
> Signed-off-by: Zhang Yi <yi.zhang@huawei.com>
Applied, thanks.
- Ted
prev parent reply other threads:[~2021-06-17 14:50 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-07 7:19 [PATCH] ext4: cleanup in-core orphan list if ext4_truncate() failed to get a transaction handle Zhang Yi
2021-05-10 10:21 ` Jan Kara
2021-06-17 14:50 ` Theodore Ts'o [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=YMthGuTCuRlZ/zL0@mit.edu \
--to=tytso@mit.edu \
--cc=adilger.kernel@dilger.ca \
--cc=jack@suse.cz \
--cc=linux-ext4@vger.kernel.org \
--cc=yi.zhang@huawei.com \
--cc=yukuai3@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.