Return -ESTALE to force a lookup when the file has no more links
Signed-off-by: Lance Shelton <lance.shelton@hammerspace.com>
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Orabug:
28789030
(cherry picked from commit
a61246c96195fc5f7500f6842e883b9eb1567d8d)
Signed-off-by: Calum Mackay <calum.mackay@oracle.com>
Reviewed-by: Darren Kenny <darren.kenny@oracle.com>
Tested-by: alfredo.ramirez@oracle.com
Signed-off-by: Brian Maly <brian.maly@oracle.com>
(S_ISREG(inode->i_mode) || S_ISDIR(inode->i_mode)))
goto out_force;
out:
- return (inode->i_nlink == 0) ? -ENOENT : 0;
+ return (inode->i_nlink == 0) ? -ESTALE : 0;
out_force:
if (flags & LOOKUP_RCU)
return -ECHILD;