2000-12-16 13:18:18

by Jani Monoses

[permalink] [raw]
Subject: mark_inode_dirty question


Hi Al,

I see that
( (inode->i_state & flags) != flags )

checked in __mark_inode_dirty as well as before it is called in
mark_inode_dirty and mark_inode_dirty_sync .Could the i_state be changed
during the call (on another CPU)?

Thanks
Jani.


2000-12-16 14:57:50

by Andrea Arcangeli

[permalink] [raw]
Subject: Re: mark_inode_dirty question

On Sat, Dec 16, 2000 at 02:47:16PM +0200, Jani Monoses wrote:
> mark_inode_dirty and mark_inode_dirty_sync .Could the i_state be changed
> during the call (on another CPU)?

no because you're protected by the inode_lock.

Andrea

2000-12-16 15:07:22

by Jani Monoses

[permalink] [raw]
Subject: Re: mark_inode_dirty question



On Sat, 16 Dec 2000, Andrea Arcangeli wrote:

> On Sat, Dec 16, 2000 at 02:47:16PM +0200, Jani Monoses wrote:
> > mark_inode_dirty and mark_inode_dirty_sync .Could the i_state be changed
> > during the call (on another CPU)?
>
> no because you're protected by the inode_lock.
>
> Andrea
>

Thanks but
I meant between the moment the call from mark_* is made and the lock is
taken.I suppose it can be changed thus the double check in both caller and
callee.