Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-07 Thread Gao Xiang
Hi Christian, On 2024/3/7 17:17, Christian Brauner wrote: On Thu, Mar 07, 2024 at 12:18:52PM +0800, Gao Xiang wrote: Hi, (try to +Cc Christian and Al here...) On 2024/3/7 11:41, Jingbo Xu wrote: Hi Baokun, Thanks for catching this! On 3/7/24 10:52 AM, Gao Xiang wrote: Hi Baokun, On

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-07 Thread Christian Brauner
On Thu, Mar 07, 2024 at 12:18:52PM +0800, Gao Xiang wrote: > Hi, > > (try to +Cc Christian and Al here...) > > On 2024/3/7 11:41, Jingbo Xu wrote: > > Hi Baokun, > > > > Thanks for catching this! > > > > > > On 3/7/24 10:52 AM, Gao Xiang wrote: > > > Hi Baokun, > > > > > > On 2024/3/7 10:44,

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-07 Thread Baokun Li via Linux-erofs
On 2024/3/7 16:46, Al Viro wrote: On Thu, Mar 07, 2024 at 07:21:12AM +, Al Viro wrote: On Thu, Mar 07, 2024 at 03:06:49PM +0800, Baokun Li wrote: +int erofs_anon_register_fs(void) +{ + return register_filesystem(_anon_fs_type); +} What for? The only thing it gives you is an ability

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-07 Thread Al Viro
On Thu, Mar 07, 2024 at 07:21:12AM +, Al Viro wrote: > On Thu, Mar 07, 2024 at 03:06:49PM +0800, Baokun Li wrote: > > > > +int erofs_anon_register_fs(void) > > > > +{ > > > > + return register_filesystem(_anon_fs_type); > > > > +} > > > What for? The only thing it gives you is an

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-06 Thread Baokun Li via Linux-erofs
On 2024/3/7 15:21, Al Viro wrote: On Thu, Mar 07, 2024 at 03:06:49PM +0800, Baokun Li wrote: +int erofs_anon_register_fs(void) +{ + return register_filesystem(_anon_fs_type); +} What for? The only thing it gives you is an ability to look it up by name. Which is completely pointless,

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-06 Thread Al Viro
On Thu, Mar 07, 2024 at 03:06:49PM +0800, Baokun Li wrote: > > > +int erofs_anon_register_fs(void) > > > +{ > > > + return register_filesystem(_anon_fs_type); > > > +} > > What for? The only thing it gives you is an ability to look it up by > > name. Which is completely pointless, IMO, > The

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-06 Thread Baokun Li via Linux-erofs
On 2024/3/7 13:07, Al Viro wrote: On Thu, Mar 07, 2024 at 10:44:59AM +0800, Baokun Li wrote: +static int erofs_anon_init_fs_context(struct fs_context *fc) +{ + fc->ops = _anon_context_ops; + return 0; +} ITYM struct pseudo_fs_context *ctx = init_pseudo(fc,

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-06 Thread Gao Xiang
Hi, On 2024/3/7 14:46, Baokun Li wrote: On 2024/3/7 11:41, Jingbo Xu wrote: Hi Baokun, ... Thank you for your feedback! If I understand you correctly, you mean to remove erofs_pseudo_mnt directly to avoid this false positive, and use anon_inode_create_getfile() to create the required

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-06 Thread Baokun Li via Linux-erofs
On 2024/3/7 11:41, Jingbo Xu wrote: Hi Baokun, Thanks for catching this! On 3/7/24 10:52 AM, Gao Xiang wrote: Hi Baokun, On 2024/3/7 10:44, Baokun Li wrote: Lockdep reported the following issue when mounting erofs with a domain_id: WARNING:

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-06 Thread Al Viro
On Thu, Mar 07, 2024 at 10:44:59AM +0800, Baokun Li wrote: > +static int erofs_anon_init_fs_context(struct fs_context *fc) > +{ > + fc->ops = _anon_context_ops; > + return 0; > +} ITYM struct pseudo_fs_context *ctx = init_pseudo(fc, EROFS_SUPER_MAGIC); return ctx ? 0 :

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-06 Thread Gao Xiang
Hi, (try to +Cc Christian and Al here...) On 2024/3/7 11:41, Jingbo Xu wrote: Hi Baokun, Thanks for catching this! On 3/7/24 10:52 AM, Gao Xiang wrote: Hi Baokun, On 2024/3/7 10:44, Baokun Li wrote: Lockdep reported the following issue when mounting erofs with a domain_id:

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-06 Thread Jingbo Xu
Hi Baokun, Thanks for catching this! On 3/7/24 10:52 AM, Gao Xiang wrote: > Hi Baokun, > > On 2024/3/7 10:44, Baokun Li wrote: >> Lockdep reported the following issue when mounting erofs with a >> domain_id: >> >> >> WARNING: possible recursive

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-06 Thread Baokun Li via Linux-erofs
Hi Xiang, On 2024/3/7 10:52, Gao Xiang wrote: Hi Baokun, On 2024/3/7 10:44, Baokun Li wrote: Lockdep reported the following issue when mounting erofs with a domain_id: WARNING: possible recursive locking detected 6.8.0-rc7-xfstests #521 Not

Re: [PATCH] erofs: fix lockdep false positives on initializing erofs_pseudo_mnt

2024-03-06 Thread Gao Xiang
Hi Baokun, On 2024/3/7 10:44, Baokun Li wrote: Lockdep reported the following issue when mounting erofs with a domain_id: WARNING: possible recursive locking detected 6.8.0-rc7-xfstests #521 Not tainted