diff --git a/fs/dcache.c b/fs/dcache.c index ab5f8e95497876cdb36d63e142505f44e93b8744..36db55960158e93a65b302b560647d161ba3edb3 100644 --- a/fs/dcache.c +++ b/fs/dcache.c @@ -682,6 +682,10 @@ static inline bool limit_negative_dentry(struct dentry *dentry) { struct dentry *parent; + /* The dentry is now unrecoverably dead, shuoldn't limit */ + if (unlikely(dentry->d_lockref.count < 0)) + return false; + parent = dentry->d_parent; if (unlikely(!parent)) return false;