Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

nfs: LOOKUP_{OPEN,CREATE,EXCL} is set only on the last step

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>

Al Viro 8aeb376c 43527803

+2 -4
+2 -4
fs/nfs/dir.c
··· 997 997 * Return the intent data that applies to this particular path component 998 998 * 999 999 * Note that the current set of intents only apply to the very last 1000 - * component of the path. 1001 - * We check for this using LOOKUP_CONTINUE and LOOKUP_PARENT. 1000 + * component of the path and none of them is set before that last 1001 + * component. 1002 1002 */ 1003 1003 static inline unsigned int nfs_lookup_check_intent(struct nameidata *nd, 1004 1004 unsigned int mask) 1005 1005 { 1006 - if (nd->flags & (LOOKUP_CONTINUE|LOOKUP_PARENT)) 1007 - return 0; 1008 1006 return nd->flags & mask; 1009 1007 } 1010 1008