Since Linux kernel 2.4.0, MS_NOATIME has been a super block flag,
and S_NOATIME has been the corresponding inode flag. Use the
correct flag when we're opening cache files.
FIXES 126084
Change-Id: I69cbcd651584cc86568c51793dd3f6d3e8644709
Reviewed-on: http://gerrit.openafs.org/1070
Reviewed-by: Derrick Brashear <shadow@dementia.org>
Tested-by: Derrick Brashear <shadow@dementia.org>
osi_Panic("Can't get dentry\n");
tip = dp->d_inode;
#endif
- tip->i_flags |= MS_NOATIME; /* Disable updating access times. */
+ tip->i_flags |= S_NOATIME; /* Disable updating access times. */
#if defined(STRUCT_TASK_HAS_CRED)
/* Use stashed credentials - prevent selinux/apparmor problems */
osi_Panic("Can't get dentry\n");
tip = dp->d_inode;
#endif
+
+#if defined(S_NOATIME)
+ tip->i_flags |= S_NOATIME; /* Disable updating access times. */
+#else
tip->i_flags |= MS_NOATIME; /* Disable updating access times. */
+#endif
#if defined(STRUCT_TASK_HAS_CRED)
filp = dentry_open(dp, mntget(afs_cacheMnt), O_RDWR, current_cred());