lkml.org 
[lkml]   [2003]   [Mar]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [CHECKER] a few race conditions
Dawson Engler <engler@csl.stanford.edu> wrote:
>
> BUG FALSE pair: lock=<dcache_lock:spinlock_t:0>, var=<struct inode.i_dentry>
> 2 errors out of 5 uses:
> /u2/engler/mc/oses/linux/linux-2.5.53/fs/dcache.c:284:d_prune_aliases: ERROR: var <struct inode.i_dentry> not protected by <dcache_lock:spinlock_t:0>(pop=5, s=3) [locked=0]
>
> i think this actually is a race: other places check it.
>
> void d_prune_aliases(struct inode *inode)
> {
> struct list_head *tmp, *head = &inode->i_dentry;
> restart:
> spin_lock(&dcache_lock);

This is OK. Local variable `head' is being set up to point at a member
inside the inode, but we're not dereferencing that pointer outside the lock.
The address of inode->i_dentry is constant across this function.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:33    [W:0.041 / U:3.796 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site