• David Howells's avatar
    afs: Mark afs_net::ws_cell as __rcu and set using rcu functions · 1588def9
    David Howells authored
    The afs_net::ws_cell member is sometimes used under RCU conditions from
    within an seq-readlock.  It isn't, however, marked __rcu and it isn't set
    using the proper RCU barrier-imposing functions.
    
    Fix this by annotating it with __rcu and using appropriate barriers to
    make sure accesses are correctly ordered.
    
    Without this, the code can produce the following warning:
    
    >> fs/afs/proc.c:151:24: sparse: incompatible types in comparison expression (different address spaces)
    
    Fixes: f044c884 ("afs: Lay the groundwork for supporting network namespaces")
    Reported-by: default avatarkbuild test robot <lkp@intel.com>
    Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
    1588def9
internal.h 39.9 KB