From: Al Viro Date: Mon, 6 Apr 2020 01:59:55 +0000 (-0400) Subject: fix a braino in legitimize_path() X-Git-Tag: v5.7-rc1~75^2 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=5bd73286d50fc242bbff1aaddb0e97c4527c9d78;p=users%2Fhch%2Fmisc.git fix a braino in legitimize_path() brown paperbag time... wrong order of arguments ended up confusing the values to check dentry and mount_lock seqcounts against. Reported-by: kernel test robot Fixes: 2aa38470853a ("non-RCU analogue of the previous commit") Tested-by: kernel test robot Signed-off-by: Al Viro --- diff --git a/fs/namei.c b/fs/namei.c index 61fdb77a7d58..a320371899cf 100644 --- a/fs/namei.c +++ b/fs/namei.c @@ -610,7 +610,7 @@ static bool __legitimize_path(struct path *path, unsigned seq, unsigned mseq) static inline bool legitimize_path(struct nameidata *nd, struct path *path, unsigned seq) { - return __legitimize_path(path, nd->m_seq, seq); + return __legitimize_path(path, seq, nd->m_seq); } static bool legitimize_links(struct nameidata *nd)