From: Artem Bityutskiy Date: Wed, 13 Aug 2008 13:16:31 +0000 (+0300) Subject: UBIFS: remove unneeded check X-Git-Tag: Ubuntu-5.2.0-15.16~33513^2~1 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=720b499c806200d06f4f22c668d46db784117089;p=mirror_ubuntu-eoan-kernel.git UBIFS: remove unneeded check Commit d70b67c8bc72ee23b55381bd6a884f4796692f77 fixed VFS and it never calls FS lookup function in deleted directories now. We may remove corresponding UBIFS check. Signed-off-by: Artem Bityutskiy --- diff --git a/fs/ubifs/dir.c b/fs/ubifs/dir.c index 0d1ab8967a4c..5c96f1fb7016 100644 --- a/fs/ubifs/dir.c +++ b/fs/ubifs/dir.c @@ -219,15 +219,7 @@ static struct dentry *ubifs_lookup(struct inode *dir, struct dentry *dentry, err = ubifs_tnc_lookup_nm(c, &key, dent, &dentry->d_name); if (err) { - /* - * Do not hash the direntry if parent 'i_nlink' is zero, because - * this has side-effects - '->delete_inode()' call will not be - * called for the parent orphan inode, because 'd_count' of its - * direntry will stay 1 (it'll be negative direntry I guess) - * and prevent 'iput_final()' until the dentry is destroyed due - * to unmount or memory pressure. - */ - if (err == -ENOENT && dir->i_nlink != 0) { + if (err == -ENOENT) { dbg_gen("not found"); goto done; }