statfs.c (088fecfbb2c8a3890918fc614a7e1e1ccdd16c83) | statfs.c (1751e8a6cb935e555fcdbcb9ab4f0446e322ca3e) |
---|---|
1// SPDX-License-Identifier: GPL-2.0 2#include <linux/syscalls.h> 3#include <linux/export.h> 4#include <linux/fs.h> 5#include <linux/file.h> 6#include <linux/mount.h> 7#include <linux/namei.h> 8#include <linux/statfs.h> --- 21 unchanged lines hidden (view full) --- 30 if (mnt_flags & MNT_RELATIME) 31 flags |= ST_RELATIME; 32 return flags; 33} 34 35static int flags_by_sb(int s_flags) 36{ 37 int flags = 0; | 1// SPDX-License-Identifier: GPL-2.0 2#include <linux/syscalls.h> 3#include <linux/export.h> 4#include <linux/fs.h> 5#include <linux/file.h> 6#include <linux/mount.h> 7#include <linux/namei.h> 8#include <linux/statfs.h> --- 21 unchanged lines hidden (view full) --- 30 if (mnt_flags & MNT_RELATIME) 31 flags |= ST_RELATIME; 32 return flags; 33} 34 35static int flags_by_sb(int s_flags) 36{ 37 int flags = 0; |
38 if (s_flags & MS_SYNCHRONOUS) | 38 if (s_flags & SB_SYNCHRONOUS) |
39 flags |= ST_SYNCHRONOUS; | 39 flags |= ST_SYNCHRONOUS; |
40 if (s_flags & MS_MANDLOCK) | 40 if (s_flags & SB_MANDLOCK) |
41 flags |= ST_MANDLOCK; | 41 flags |= ST_MANDLOCK; |
42 if (s_flags & MS_RDONLY) | 42 if (s_flags & SB_RDONLY) |
43 flags |= ST_RDONLY; 44 return flags; 45} 46 47static int calculate_f_flags(struct vfsmount *mnt) 48{ 49 return ST_VALID | flags_by_mnt(mnt->mnt_flags) | 50 flags_by_sb(mnt->mnt_sb->s_flags); --- 336 unchanged lines hidden --- | 43 flags |= ST_RDONLY; 44 return flags; 45} 46 47static int calculate_f_flags(struct vfsmount *mnt) 48{ 49 return ST_VALID | flags_by_mnt(mnt->mnt_flags) | 50 flags_by_sb(mnt->mnt_sb->s_flags); --- 336 unchanged lines hidden --- |