From: Damien Le Moal <dlemoal@kernel.org>
To: Jaegeuk Kim <jaegeuk@kernel.org>
Cc: Christoph Hellwig <hch@lst.de>,
chao@kernel.org, linux-f2fs-devel@lists.sourceforge.net,
linux-block@vger.kernel.org
Subject: Re: [PATCH] f2fs: don't reopen the main block device in f2fs_scan_devices
Date: Tue, 11 Jul 2023 11:00:55 +0900 [thread overview]
Message-ID: <4d484518-5822-bd4b-4261-08a3aec6b5d2@kernel.org> (raw)
In-Reply-To: <ZKy15tpRQjja6s/5@google.com>
On 7/11/23 10:52, Jaegeuk Kim wrote:
>>>> diff --git a/fs/f2fs/super.c b/fs/f2fs/super.c
>>>> index ca31163da00a55..8d11d4a5ec331d 100644
>>>> --- a/fs/f2fs/super.c
>>>> +++ b/fs/f2fs/super.c
>>>> @@ -1560,7 +1560,8 @@ static void destroy_device_list(struct f2fs_sb_info *sbi)
>>>> {
>>>> int i;
>>>>
>>>> - for (i = 0; i < sbi->s_ndevs; i++) {
>>>
>>> #ifdef CONFIG_BLK_DEV_ZONED
>>>
>>>> + kvfree(FDEV(0).blkz_seq);
>>>
>>> #endif
>>
>> This should not be needed since for the !CONFIG_BLK_DEV_ZONED case,
>> FDEV(0).blkz_seq should always be NULL. However, what I think may be missing is
>> "FDEV(0).blkz_seq = NULL;" after the kvfree() call. No ?
>
> I was looking at a glance of this:
> https://lore.kernel.org/linux-f2fs-devel/202307110542.NBAMyZxE-lkp@intel.com/T/#u
OK. Got it.
I still think that it may be safer to add the NULL affectation though.
--
Damien Le Moal
Western Digital Research
next prev parent reply other threads:[~2023-07-11 2:01 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-07 9:40 [PATCH] f2fs: don't reopen the main block device in f2fs_scan_devices Christoph Hellwig
2023-07-10 21:22 ` Jaegeuk Kim
2023-07-10 23:51 ` Damien Le Moal
2023-07-11 1:52 ` Jaegeuk Kim
2023-07-11 2:00 ` Damien Le Moal [this message]
2023-07-11 5:01 ` Christoph Hellwig
2023-07-11 6:19 ` Hannes Reinecke
2023-07-11 6:22 ` Christoph Hellwig
2023-07-11 16:17 ` Jaegeuk Kim
2023-07-17 15:16 ` Chao Yu
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=4d484518-5822-bd4b-4261-08a3aec6b5d2@kernel.org \
--to=dlemoal@kernel.org \
--cc=chao@kernel.org \
--cc=hch@lst.de \
--cc=jaegeuk@kernel.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-f2fs-devel@lists.sourceforge.net \
/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