• D
    vfs, afs, ext4: Make the inode hash table RCU searchable · dc136109
    David Howells 提交于
    task #29263287
    
    commit 3f19b2ab97a97b413c24b66c67ae16daa4f56c35 upstream
    
    Make the inode hash table RCU searchable so that searches that want to
    access or modify an inode without taking a ref on that inode can do so
    without taking the inode hash table lock.
    
    The main thing this requires is some RCU annotation on the list
    manipulation operations.  Inodes are already freed by RCU in most cases.
    
    Users of this interface must take care as the inode may be still under
    construction or may be being torn down around them.
    
    There are at least three instances where this can be of use:
    
     (1) Testing whether the inode number iunique() is going to return is
         currently unique (the iunique_lock is still held).
    
     (2) Ext4 date stamp updating.
    
     (3) AFS callback breaking.
    Signed-off-by: NDavid Howells <dhowells@redhat.com>
    Acked-by: NKonstantin Khlebnikov <khlebnikov@yandex-team.ru>
    cc: linux-ext4@vger.kernel.org
    cc: linux-afs@lists.infradead.org
    [jeffle: resolve collision in afs_break_one_callback since code base change]
    Signed-off-by: NJeffle Xu <jefflexu@linux.alibaba.com>
    Reviewed-by: NJoseph Qi <joseph.qi@linux.alibaba.com>
    dc136109
inode.c 59.4 KB