Hi Andrew, Today's linux-next merge of the akpm tree got a conflict in fs/dcache.c between commits 8aab6a27332b ("vfs: reorganize dput() memory accesses") and 0d98439ea3c6 ("vfs: use lockred "dead" flag to mark unrecoverably dead dentries") from Linus' tree and commit "dcache: remove dentries from LRU before putting on dispose list" from the akpm tree. I fixed it up (hopefully - see below) and can carry the fix as necessary (no action is required). -- Cheers, Stephen Rothwell sfr@xxxxxxxxxxxxxxxx diff --cc fs/dcache.c index a4cc2eb,43a1c0e..0000000 --- a/fs/dcache.c +++ b/fs/dcache.c @@@ -374,7 -344,6 +374,7 @@@ static void dentry_lru_add(struct dentr static void __dentry_lru_del(struct dentry *dentry) { list_del_init(&dentry->d_lru); - dentry->d_flags &= ~(DCACHE_SHRINK_LIST | DCACHE_LRU_LIST); ++ dentry->d_flags &= ~DCACHE_LRU_LIST; dentry->d_sb->s_nr_dentry_unused--; this_cpu_dec(nr_dentry_unused); } @@@ -393,14 -372,15 +403,16 @@@ static void dentry_lru_del(struct dentr static void dentry_lru_move_list(struct dentry *dentry, struct list_head *list) { + BUG_ON(dentry->d_flags & DCACHE_SHRINK_LIST); + spin_lock(&dentry->d_sb->s_dentry_lru_lock); if (list_empty(&dentry->d_lru)) { + dentry->d_flags |= DCACHE_LRU_LIST; list_add_tail(&dentry->d_lru, list); - dentry->d_sb->s_nr_dentry_unused++; - this_cpu_inc(nr_dentry_unused); } else { list_move_tail(&dentry->d_lru, list); + dentry->d_sb->s_nr_dentry_unused--; + this_cpu_dec(nr_dentry_unused); } spin_unlock(&dentry->d_sb->s_dentry_lru_lock); } @@@ -498,7 -478,8 +510,8 @@@ EXPORT_SYMBOL(d_drop) * If ref is non-zero, then decrement the refcount too. * Returns dentry requiring refcount drop, or NULL if we're done. */ - static inline struct dentry *dentry_kill(struct dentry *dentry) + static inline struct dentry * -dentry_kill(struct dentry *dentry, int ref, int unlock_on_failure) ++dentry_kill(struct dentry *dentry, int unlock_on_failure) __releases(dentry->d_lock) { struct inode *inode; @@@ -591,7 -573,7 +606,7 @@@ repeat return; kill_it: - dentry = dentry_kill(dentry); - dentry = dentry_kill(dentry, 1, 1); ++ dentry = dentry_kill(dentry, 1); if (dentry) goto repeat; } @@@ -816,7 -798,7 +831,7 @@@ static struct dentry * try_prune_one_de { struct dentry *parent; - parent = dentry_kill(dentry); - parent = dentry_kill(dentry, 0, 0); ++ parent = dentry_kill(dentry, 0); /* * If dentry_kill returns NULL, we have nothing more to do. * if it returns the same dentry, trylocks failed. In either @@@ -836,9 -818,10 +851,10 @@@ dentry = parent; while (dentry) { if (lockref_put_or_lock(&dentry->d_lockref)) - return; - dentry = dentry_kill(dentry); + return NULL; - dentry = dentry_kill(dentry, 1, 1); ++ dentry = dentry_kill(dentry, 1); } + return NULL; } static void shrink_dentry_list(struct list_head *list)
Attachment:
pgpnfrDOMO2Bz.pgp
Description: PGP signature