Hi Amir,
I love your patch! Yet something to improve:
[auto build test ERROR on linus/master]
[also build test ERROR on v5.1-rc7 next-20190503]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the
system]
url:
https://github.com/0day-ci/linux/commits/Amir-Goldstein/fsnotify-fix-unli...
config: riscv-tinyconfig (attached as .config)
compiler: riscv64-linux-gcc (GCC) 8.1.0
reproduce:
wget
https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O
~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
GCC_VERSION=8.1.0 make.cross ARCH=riscv
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from fs///attr.c:15:
include/linux/fsnotify.h: In function 'fsnotify_nameremove':
> include/linux/fsnotify.h:179:23: error: 'struct inode'
has no member named 'i_fsnotify_mask'
if
(!(d_inode(parent)->i_fsnotify_mask & FS_DELETE) &&
^~
> include/linux/fsnotify.h:180:20: error: 'struct
super_block' has no member named 's_fsnotify_mask'
!(dentry->d_sb->s_fsnotify_mask & FS_DELETE))
^~
vim +179 include/linux/fsnotify.h
153
154 /*
155 * fsnotify_nameremove - a filename was removed from a directory
156 *
157 * This is mostly called under parent vfs inode lock so name and
158 * dentry->d_parent should be stable. However there are some corner cases where
159 * inode lock is not held. So to be on the safe side and be reselient to future
160 * callers and out of tree users of d_delete(), we do not assume that d_parent
161 * and d_name are stable and we use dget_parent() and
162 * take_dentry_name_snapshot() to grab stable references.
163 */
164 static inline void fsnotify_nameremove(struct dentry *dentry, int isdir)
165 {
166 struct dentry *parent;
167 struct name_snapshot name;
168 __u32 mask = FS_DELETE;
169
170 /* d_delete() of pseudo inode? (e.g. __ns_get_path() playing tricks) */
171 if (IS_ROOT(dentry))
172 return;
173
174 if (isdir)
175 mask |= FS_ISDIR;
176
177 parent = dget_parent(dentry);
178 /* Avoid unneeded take_dentry_name_snapshot() */
179 if (!(d_inode(parent)->i_fsnotify_mask & FS_DELETE)
&&
180 !(dentry->d_sb->s_fsnotify_mask & FS_DELETE))
181 goto
out_dput;
182
183 take_dentry_name_snapshot(&name, dentry);
184
185 fsnotify(d_inode(parent), mask, d_inode(dentry), FSNOTIFY_EVENT_INODE,
186 name.name, 0);
187
188 release_dentry_name_snapshot(&name);
189
190 out_dput:
191 dput(parent);
192 }
193
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation