diff options
author | Miklos Szeredi <mszeredi@suse.cz> | 2008-07-03 14:56:04 -0400 |
---|---|---|
committer | James Morris <jmorris@namei.org> | 2008-07-14 01:02:05 -0400 |
commit | b478a9f9889c81e88077d1495daadee64c0af541 (patch) | |
tree | d1a843fab53dd4b28b45172ba0b90417c4eefc48 | |
parent | 2069f457848f846cb31149c9aa29b330a6b66d1b (diff) |
security: remove unused sb_get_mnt_opts hook
The sb_get_mnt_opts() hook is unused, and is superseded by the
sb_show_options() hook.
Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
Acked-by: James Morris <jmorris@namei.org>
-rw-r--r-- | include/linux/security.h | 14 | ||||
-rw-r--r-- | security/dummy.c | 8 | ||||
-rw-r--r-- | security/security.c | 6 | ||||
-rw-r--r-- | security/selinux/hooks.c | 1 |
4 files changed, 0 insertions, 29 deletions
diff --git a/include/linux/security.h b/include/linux/security.h index c8ad8ec684b4..43c6357568a3 100644 --- a/include/linux/security.h +++ b/include/linux/security.h | |||
@@ -291,10 +291,6 @@ static inline void security_free_mnt_opts(struct security_mnt_opts *opts) | |||
291 | * Update module state after a successful pivot. | 291 | * Update module state after a successful pivot. |
292 | * @old_path contains the path for the old root. | 292 | * @old_path contains the path for the old root. |
293 | * @new_path contains the path for the new root. | 293 | * @new_path contains the path for the new root. |
294 | * @sb_get_mnt_opts: | ||
295 | * Get the security relevant mount options used for a superblock | ||
296 | * @sb the superblock to get security mount options from | ||
297 | * @opts binary data structure containing all lsm mount data | ||
298 | * @sb_set_mnt_opts: | 294 | * @sb_set_mnt_opts: |
299 | * Set the security relevant mount options used for a superblock | 295 | * Set the security relevant mount options used for a superblock |
300 | * @sb the superblock to set security mount options for | 296 | * @sb the superblock to set security mount options for |
@@ -1348,8 +1344,6 @@ struct security_operations { | |||
1348 | struct path *new_path); | 1344 | struct path *new_path); |
1349 | void (*sb_post_pivotroot) (struct path *old_path, | 1345 | void (*sb_post_pivotroot) (struct path *old_path, |
1350 | struct path *new_path); | 1346 | struct path *new_path); |
1351 | int (*sb_get_mnt_opts) (const struct super_block *sb, | ||
1352 | struct security_mnt_opts *opts); | ||
1353 | int (*sb_set_mnt_opts) (struct super_block *sb, | 1347 | int (*sb_set_mnt_opts) (struct super_block *sb, |
1354 | struct security_mnt_opts *opts); | 1348 | struct security_mnt_opts *opts); |
1355 | void (*sb_clone_mnt_opts) (const struct super_block *oldsb, | 1349 | void (*sb_clone_mnt_opts) (const struct super_block *oldsb, |
@@ -1624,8 +1618,6 @@ void security_sb_post_remount(struct vfsmount *mnt, unsigned long flags, void *d | |||
1624 | void security_sb_post_addmount(struct vfsmount *mnt, struct path *mountpoint); | 1618 | void security_sb_post_addmount(struct vfsmount *mnt, struct path *mountpoint); |
1625 | int security_sb_pivotroot(struct path *old_path, struct path *new_path); | 1619 | int security_sb_pivotroot(struct path *old_path, struct path *new_path); |
1626 | void security_sb_post_pivotroot(struct path *old_path, struct path *new_path); | 1620 | void security_sb_post_pivotroot(struct path *old_path, struct path *new_path); |
1627 | int security_sb_get_mnt_opts(const struct super_block *sb, | ||
1628 | struct security_mnt_opts *opts); | ||
1629 | int security_sb_set_mnt_opts(struct super_block *sb, struct security_mnt_opts *opts); | 1621 | int security_sb_set_mnt_opts(struct super_block *sb, struct security_mnt_opts *opts); |
1630 | void security_sb_clone_mnt_opts(const struct super_block *oldsb, | 1622 | void security_sb_clone_mnt_opts(const struct super_block *oldsb, |
1631 | struct super_block *newsb); | 1623 | struct super_block *newsb); |
@@ -1942,12 +1934,6 @@ static inline int security_sb_pivotroot(struct path *old_path, | |||
1942 | static inline void security_sb_post_pivotroot(struct path *old_path, | 1934 | static inline void security_sb_post_pivotroot(struct path *old_path, |
1943 | struct path *new_path) | 1935 | struct path *new_path) |
1944 | { } | 1936 | { } |
1945 | static inline int security_sb_get_mnt_opts(const struct super_block *sb, | ||
1946 | struct security_mnt_opts *opts) | ||
1947 | { | ||
1948 | security_init_mnt_opts(opts); | ||
1949 | return 0; | ||
1950 | } | ||
1951 | 1937 | ||
1952 | static inline int security_sb_set_mnt_opts(struct super_block *sb, | 1938 | static inline int security_sb_set_mnt_opts(struct super_block *sb, |
1953 | struct security_mnt_opts *opts) | 1939 | struct security_mnt_opts *opts) |
diff --git a/security/dummy.c b/security/dummy.c index c155f08e9dd8..793856691641 100644 --- a/security/dummy.c +++ b/security/dummy.c | |||
@@ -252,13 +252,6 @@ static void dummy_sb_post_pivotroot (struct path *old_path, struct path *new_pat | |||
252 | return; | 252 | return; |
253 | } | 253 | } |
254 | 254 | ||
255 | static int dummy_sb_get_mnt_opts(const struct super_block *sb, | ||
256 | struct security_mnt_opts *opts) | ||
257 | { | ||
258 | security_init_mnt_opts(opts); | ||
259 | return 0; | ||
260 | } | ||
261 | |||
262 | static int dummy_sb_set_mnt_opts(struct super_block *sb, | 255 | static int dummy_sb_set_mnt_opts(struct super_block *sb, |
263 | struct security_mnt_opts *opts) | 256 | struct security_mnt_opts *opts) |
264 | { | 257 | { |
@@ -1104,7 +1097,6 @@ void security_fixup_ops (struct security_operations *ops) | |||
1104 | set_to_dummy_if_null(ops, sb_post_addmount); | 1097 | set_to_dummy_if_null(ops, sb_post_addmount); |
1105 | set_to_dummy_if_null(ops, sb_pivotroot); | 1098 | set_to_dummy_if_null(ops, sb_pivotroot); |
1106 | set_to_dummy_if_null(ops, sb_post_pivotroot); | 1099 | set_to_dummy_if_null(ops, sb_post_pivotroot); |
1107 | set_to_dummy_if_null(ops, sb_get_mnt_opts); | ||
1108 | set_to_dummy_if_null(ops, sb_set_mnt_opts); | 1100 | set_to_dummy_if_null(ops, sb_set_mnt_opts); |
1109 | set_to_dummy_if_null(ops, sb_clone_mnt_opts); | 1101 | set_to_dummy_if_null(ops, sb_clone_mnt_opts); |
1110 | set_to_dummy_if_null(ops, sb_parse_opts_str); | 1102 | set_to_dummy_if_null(ops, sb_parse_opts_str); |
diff --git a/security/security.c b/security/security.c index de74fdccde26..28b2860c1129 100644 --- a/security/security.c +++ b/security/security.c | |||
@@ -348,12 +348,6 @@ void security_sb_post_pivotroot(struct path *old_path, struct path *new_path) | |||
348 | security_ops->sb_post_pivotroot(old_path, new_path); | 348 | security_ops->sb_post_pivotroot(old_path, new_path); |
349 | } | 349 | } |
350 | 350 | ||
351 | int security_sb_get_mnt_opts(const struct super_block *sb, | ||
352 | struct security_mnt_opts *opts) | ||
353 | { | ||
354 | return security_ops->sb_get_mnt_opts(sb, opts); | ||
355 | } | ||
356 | |||
357 | int security_sb_set_mnt_opts(struct super_block *sb, | 351 | int security_sb_set_mnt_opts(struct super_block *sb, |
358 | struct security_mnt_opts *opts) | 352 | struct security_mnt_opts *opts) |
359 | { | 353 | { |
diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c index 33dee83fdd2f..745a69e74e38 100644 --- a/security/selinux/hooks.c +++ b/security/selinux/hooks.c | |||
@@ -5421,7 +5421,6 @@ static struct security_operations selinux_ops = { | |||
5421 | .sb_statfs = selinux_sb_statfs, | 5421 | .sb_statfs = selinux_sb_statfs, |
5422 | .sb_mount = selinux_mount, | 5422 | .sb_mount = selinux_mount, |
5423 | .sb_umount = selinux_umount, | 5423 | .sb_umount = selinux_umount, |
5424 | .sb_get_mnt_opts = selinux_get_mnt_opts, | ||
5425 | .sb_set_mnt_opts = selinux_set_mnt_opts, | 5424 | .sb_set_mnt_opts = selinux_set_mnt_opts, |
5426 | .sb_clone_mnt_opts = selinux_sb_clone_mnt_opts, | 5425 | .sb_clone_mnt_opts = selinux_sb_clone_mnt_opts, |
5427 | .sb_parse_opts_str = selinux_parse_opts_str, | 5426 | .sb_parse_opts_str = selinux_parse_opts_str, |