linux-hardened/security/apparmor/include
Linus Torvalds 1751e8a6cb Rename superblock flags (MS_xyz -> SB_xyz)
This is a pure automated search-and-replace of the internal kernel
superblock flags.

The s_flags are now called SB_*, with the names and the values for the
moment mirroring the MS_* flags that they're equivalent to.

Note how the MS_xyz flags are the ones passed to the mount system call,
while the SB_xyz flags are what we then use in sb->s_flags.

The script to do this was:

    # places to look in; re security/*: it generally should *not* be
    # touched (that stuff parses mount(2) arguments directly), but
    # there are two places where we really deal with superblock flags.
    FILES="drivers/mtd drivers/staging/lustre fs ipc mm \
            include/linux/fs.h include/uapi/linux/bfs_fs.h \
            security/apparmor/apparmorfs.c security/apparmor/include/lib.h"
    # the list of MS_... constants
    SYMS="RDONLY NOSUID NODEV NOEXEC SYNCHRONOUS REMOUNT MANDLOCK \
          DIRSYNC NOATIME NODIRATIME BIND MOVE REC VERBOSE SILENT \
          POSIXACL UNBINDABLE PRIVATE SLAVE SHARED RELATIME KERNMOUNT \
          I_VERSION STRICTATIME LAZYTIME SUBMOUNT NOREMOTELOCK NOSEC BORN \
          ACTIVE NOUSER"

    SED_PROG=
    for i in $SYMS; do SED_PROG="$SED_PROG -e s/MS_$i/SB_$i/g"; done

    # we want files that contain at least one of MS_...,
    # with fs/namespace.c and fs/pnode.c excluded.
    L=$(for i in $SYMS; do git grep -w -l MS_$i $FILES; done| sort|uniq|grep -v '^fs/namespace.c'|grep -v '^fs/pnode.c')

    for f in $L; do sed -i $f $SED_PROG; done

Requested-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2017-11-27 13:05:09 -08:00
..
apparmor.h apparmor: add mount mediation 2017-09-22 13:00:57 -07:00
apparmorfs.h apparmor: add policy revision file interface 2017-06-10 17:11:27 -07:00
audit.h Revert "apparmor: add base infastructure for socket mediation" 2017-10-26 19:35:35 +02:00
capability.h apparmor: move capability checks to using labels 2017-06-10 17:11:40 -07:00
context.h apparmor: switch from profiles to using labels on contexts 2017-06-10 17:11:38 -07:00
crypto.h apparmor: allow introspecting the loaded policy pre internal transform 2017-01-16 01:18:42 -08:00
domain.h + Features 2017-09-23 05:33:29 -10:00
file.h apparmor: Refactor to remove bprm_secureexec hook 2017-08-01 12:03:06 -07:00
ipc.h apparmor: add the ability to mediate signals 2017-09-22 13:00:57 -07:00
label.h apparmor: add support for absolute root view based labels 2017-09-22 13:00:58 -07:00
lib.h Rename superblock flags (MS_xyz -> SB_xyz) 2017-11-27 13:05:09 -08:00
match.h apparmor: fix restricted endian type warnings for dfa unpack 2017-01-16 01:18:54 -08:00
mount.h apparmor: add mount mediation 2017-09-22 13:00:57 -07:00
path.h apparmor: Move path lookup to using preallocated buffers 2017-06-08 11:29:34 -07:00
perms.h Revert "apparmor: add base infastructure for socket mediation" 2017-10-26 19:35:35 +02:00
policy.h Revert "apparmor: add base infastructure for socket mediation" 2017-10-26 19:35:35 +02:00
policy_ns.h apparmor: switch from profiles to using labels on contexts 2017-06-10 17:11:38 -07:00
policy_unpack.h apparmor: move to per loaddata files, instead of replicating in profiles 2017-06-08 12:51:49 -07:00
procattr.h apparmor: switch getprocattr to using label_print fns() 2017-06-10 17:11:39 -07:00
resource.h apparmor: move resource checks to using labels 2017-06-10 17:11:40 -07:00
secid.h apparmor: rename sid to secid 2017-01-16 00:42:17 -08:00
sig_names.h apparmor: fix build failure on sparc caused by undeclared signals 2017-09-22 13:00:58 -07:00