lkml.org 
[lkml]   [2023]   [Oct]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v2 5/5] fs: Add inode_assert_locked() and inode_assert_locked_excl()
On 10/7/23, Matthew Wilcox (Oracle) <willy@infradead.org> wrote:
> +static inline void inode_assert_locked_excl(const struct inode *inode)
> +{
> + rwsem_assert_held_write(&inode->i_rwsem);
> +}
> +
> static inline void inode_lock_nested(struct inode *inode, unsigned
> subclass)
> {
> down_write_nested(&inode->i_rwsem, subclass);

Why "excl" instead of "write"? Apart from looking weird, it is
inconsistent with "prior art" in the file: i_mmap_assert_write_locked.

--
Mateusz Guzik <mjguzik gmail.com>

\
 
 \ /
  Last update: 2023-10-08 22:30    [W:0.102 / U:1.352 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site