lkml.org 
[lkml]   [2021]   [Dec]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [BUG] fs: ocfs2: possible ABBA deadlock in ocfs2_dio_end_io_write() and ocfs2_move_extents()
From
Date


On 2021/12/14 15:08, Joseph Qi wrote:
> Hi,
>
> Thanks for the report. But I don't think this is a possible deadlock in
> practice. Please see my comments below.
>
> On 12/10/21 4:38 PM, Jia-Ju Bai wrote:
>> Hello,
>>
>> My static analysis tool reports a possible ABBA deadlock in the ocfs2 module in Linux 5.10:
>>
>> ocfs2_dio_end_io_write()
>>   down_write(&oi->ip_alloc_sem); --> Line 2322 (Lock A)
>>   ocfs2_del_inode_from_orphan()
>>     inode_lock(orphan_dir_inode);  --> Line 2701 (Lock B)
> Just as the variable name indicates, it is orphan dir inode, which is a
> system file (something hidden inside the filesystem) and not visible for
> end user.
>
>> ocfs2_move_extents()
>>   inode_lock(inode); --> Line 916 (Lock B)
> This is called from a ioctl from user, it a normal file inode.

Okay, thanks for the explanation :)


Best wishes,
Jia-Ju Bai

\
 
 \ /
  Last update: 2021-12-14 08:19    [W:0.032 / U:0.468 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site