diff --git a/fs/namei.c b/fs/namei.c index f81fdc7bbfed..6e34c3317421 100644 --- a/fs/namei.c +++ b/fs/namei.c @@ -1635,10 +1635,8 @@ static inline int handle_mounts(struct nameidata *nd, struct dentry *dentry, return -ECHILD; } ret = traverse_mounts(path, &jumped, &nd->total_link_count, nd->flags); - if (jumped) { - if (!unlikely(nd->flags & LOOKUP_NO_XDEV)) - nd->state |= ND_JUMPED; - } + if (jumped) + nd->state |= ND_JUMPED; if (unlikely(ret)) { dput(path->dentry); if (path->mnt != nd->path.mnt)