[amir73il:fsnotify_event_info 2/2] include/linux/fsnotify.h:76:12: error: 'struct inode' has no member named 'i_fsnotify_marks'

From: kernel test robot
Date: Tue Aug 03 2021 - 07:53:25 EST


tree: https://github.com/amir73il/linux fsnotify_event_info
head: 4ad14805402352430e0b98901b97ec9166d9dae4
commit: 4ad14805402352430e0b98901b97ec9166d9dae4 [2/2] fsnotify: fast path optimization for IO on pipe with no watches
config: arc-randconfig-r033-20210803 (attached as .config)
compiler: arceb-elf-gcc (GCC) 10.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/amir73il/linux/commit/4ad14805402352430e0b98901b97ec9166d9dae4
git remote add amir73il https://github.com/amir73il/linux
git fetch --no-tags amir73il fsnotify_event_info
git checkout 4ad14805402352430e0b98901b97ec9166d9dae4
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross O=build_dir ARCH=arc SHELL=/bin/bash fs/

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

In file included from fs/open.c:12:
include/linux/fsnotify.h: In function 'fsnotify_parent':
>> include/linux/fsnotify.h:76:12: error: 'struct inode' has no member named 'i_fsnotify_marks'
76 | if (!inode->i_fsnotify_marks &&
| ^~
>> include/linux/fsnotify.h:80:18: error: 'struct super_block' has no member named 's_fsnotify_marks'
80 | !inode->i_sb->s_fsnotify_marks)
| ^~
include/linux/fsnotify.h: In function 'fsnotify_access':
include/linux/fsnotify.h:263:2: error: implicit declaration of function 'fsnotify_file'; did you mean 'fsnotify_link'? [-Werror=implicit-function-declaration]
263 | fsnotify_file(file, FS_ACCESS);
| ^~~~~~~~~~~~~
| fsnotify_link
cc1: some warnings being treated as errors


vim +76 include/linux/fsnotify.h

50
51 /* Notify this dentry's parent about a child's events. */
52 static inline int fsnotify_parent(struct dentry *dentry, struct mount *mnt,
53 __u32 mask, const void *data, int data_type)
54 {
55 struct inode *inode = d_inode(dentry);
56
57 if (S_ISDIR(inode->i_mode)) {
58 mask |= FS_ISDIR;
59
60 /* sb/mount marks are not interested in name of directory */
61 if (!(dentry->d_flags & DCACHE_FSNOTIFY_PARENT_WATCHED))
62 goto notify_child;
63 }
64
65 /* disconnected dentry cannot notify parent */
66 if (IS_ROOT(dentry))
67 goto notify_child;
68
69 return __fsnotify_parent(dentry, mnt, mask, data, data_type);
70
71 notify_child:
72 /*
73 * Optimize out the function call for the case of disconnected inode
74 * (e.g. pipe) with no watches.
75 */
> 76 if (!inode->i_fsnotify_marks &&
77 #ifdef MNT_HAVE_REAL_MOUNT
78 (!mnt || !mnt->mnt_fsnotify_marks) &&
79 #endif
> 80 !inode->i_sb->s_fsnotify_marks)
81 return 0;
82
83 return fsnotify_child(mask, data, data_type, NULL, NULL, inode, mnt);
84 }
85

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip