From: Damien Le Moal <damien.lemoal@opensource.wdc.com>
To: Johannes Thumshirn <Johannes.Thumshirn@wdc.com>,
"linux-fsdevel@vger.kernel.org" <linux-fsdevel@vger.kernel.org>
Subject: Re: [PATCH 6/8] zonefs: Add active seq file accounting
Date: Tue, 19 Apr 2022 20:26:41 +0900 [thread overview]
Message-ID: <38720285-3f18-dcee-fcee-f2c223b1d52a@opensource.wdc.com> (raw)
In-Reply-To: <PH0PR04MB741645F790D210401E2CD2EB9BF29@PH0PR04MB7416.namprd04.prod.outlook.com>
On 4/19/22 20:06, Johannes Thumshirn wrote:
> On 19/04/2022 13:03, Damien Le Moal wrote:
>> On 4/19/22 19:59, Johannes Thumshirn wrote:
>>> On 18/04/2022 03:12, Damien Le Moal wrote:
>>>> +/*
>>>> + * Manage the active zone count. Called with zi->i_truncate_mutex held.
>>>> + */
>>>> +static void zonefs_account_active(struct inode *inode)
>>>> +{
>>>> + struct zonefs_sb_info *sbi = ZONEFS_SB(inode->i_sb);
>>>> + struct zonefs_inode_info *zi = ZONEFS_I(inode);
>>>> +
>>>
>>> Nit: lockdep_assert_held(&zi->i_truncate_mutex);
>>
>> If I add that, lockdep screams during mount as the inodes mutex is not
>> held when the zone inodes are initialized and zonefs_account_active()
>> called. We could add a wrapper function for this, but I did not feel it
>> was necessary.
>
> OK, but then the 'Called with zi->i_truncate_mutex held.' comment is invalid
> and should be removed.
Not invalid. When mounting, nobody but the mount process can touch inodes,
so not holding the mutex is OK.
Will see how to clean this up.
--
Damien Le Moal
Western Digital Research
next prev parent reply other threads:[~2022-04-19 11:26 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-18 1:11 [PATCH 0/8] zonefs improvements Damien Le Moal
2022-04-18 1:12 ` [PATCH 1/8] zonefs: Clear inode information flags on inode creation Damien Le Moal
2022-04-19 9:27 ` Johannes Thumshirn
2022-04-18 1:12 ` [PATCH 2/8] zonefs: Fix management of open zones Damien Le Moal
2022-04-19 9:38 ` Johannes Thumshirn
2022-04-18 1:12 ` [PATCH 3/8] zonefs: Rename super block information fields Damien Le Moal
2022-04-19 9:29 ` Johannes Thumshirn
2022-04-18 1:12 ` [PATCH 4/8] zonefs: Always do seq file write open accounting Damien Le Moal
2022-04-19 9:55 ` Johannes Thumshirn
2022-04-18 1:12 ` [PATCH 5/8] zonefs: Export open zone resource information through sysfs Damien Le Moal
2022-04-19 10:06 ` Johannes Thumshirn
2022-04-18 1:12 ` [PATCH 6/8] zonefs: Add active seq file accounting Damien Le Moal
2022-04-19 10:59 ` Johannes Thumshirn
2022-04-19 11:02 ` Damien Le Moal
2022-04-19 11:06 ` Johannes Thumshirn
2022-04-19 11:26 ` Damien Le Moal [this message]
2022-04-18 1:12 ` [PATCH 7/8] documentation: zonefs: Cleanup the mount options section Damien Le Moal
2022-04-19 10:14 ` Johannes Thumshirn
2022-04-18 1:12 ` [PATCH 8/8] documentation: zonefs: Document sysfs attributes Damien Le Moal
2022-04-19 10:14 ` Johannes Thumshirn
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=38720285-3f18-dcee-fcee-f2c223b1d52a@opensource.wdc.com \
--to=damien.lemoal@opensource.wdc.com \
--cc=Johannes.Thumshirn@wdc.com \
--cc=linux-fsdevel@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).