fs_parse: fold fs_parameter_desc/fs_parameter_spec
[linux-2.6-block.git] / security / selinux / hooks.c
index 116b4d644f68935a82083cdbdd232c5243d203cc..d085569fd426292adc8b3758e3a976abfe67f2f9 100644 (file)
@@ -2808,7 +2808,7 @@ static int selinux_fs_context_dup(struct fs_context *fc,
        return 0;
 }
 
-static const struct fs_parameter_spec selinux_param_specs[] = {
+static const struct fs_parameter_spec selinux_fs_parameters[] = {
        fsparam_string(CONTEXT_STR,     Opt_context),
        fsparam_string(DEFCONTEXT_STR,  Opt_defcontext),
        fsparam_string(FSCONTEXT_STR,   Opt_fscontext),
@@ -2817,18 +2817,13 @@ static const struct fs_parameter_spec selinux_param_specs[] = {
        {}
 };
 
-static const struct fs_parameter_description selinux_fs_parameters = {
-       .name           = "SELinux",
-       .specs          = selinux_param_specs,
-};
-
 static int selinux_fs_context_parse_param(struct fs_context *fc,
                                          struct fs_parameter *param)
 {
        struct fs_parse_result result;
        int opt, rc;
 
-       opt = fs_parse(fc, &selinux_fs_parameters, param, &result);
+       opt = fs_parse(fc, selinux_fs_parameters, param, &result);
        if (opt < 0)
                return opt;
 
@@ -7145,7 +7140,7 @@ static __init int selinux_init(void)
        else
                pr_debug("SELinux:  Starting in permissive mode\n");
 
-       fs_validate_description(&selinux_fs_parameters);
+       fs_validate_description("selinux", selinux_fs_parameters);
 
        return 0;
 }