mirror of
https://github.com/torvalds/linux.git
synced 2026-11-29 10:07:52 +00:00
Add a call security_inode_init_security() after ramfs_get_inode(), to let LSMs initialize the inode security field. Skip ramfs_fill_super(), as the initialization is done through the sb_set_mnt_opts hook. Calling security_inode_init_security() call inside ramfs_get_inode() is not possible since, for CONFIG_SHMEM=n, tmpfs also calls the former after the latter. Pass NULL as initxattrs() callback to security_inode_init_security(), since the purpose of the call is only to initialize the in-memory inodes. Cc: Hugh Dickins <[email protected]> Acked-by: Andrew Morton <[email protected]> Signed-off-by: Roberto Sassu <[email protected]> Signed-off-by: Casey Schaufler <[email protected]>