History

get rid of cg_invalf()

pointless alias for invalf()...

Al Viro committed 6 years ago

Commit fbc2d161 parent aa1918f1 file · +12 −14Browse files

Unified · Split

kernel/cgroup/cgroup-v1.c+12−14
@@ -18,8 +18,6 @@ · 17 unmodified lines
1818
1919 #include <trace/events/cgroup.h>
2020
21−#define cg_invalf(fc, fmt, ...) invalf(fc, fmt, ## __VA_ARGS__)
22−
2321 /*
2422 * pidlists linger the following amount before being destroyed. The goal
2523 * is avoiding frequent destruction in the middle of consecutive read calls
@@ -924,7 +922,7 @@ int cgroup1_parse_param(struct fs_context *fc, struct fs_parameter *param) · 898 unmodified lines
924922 ctx->subsys_mask |= (1 << i);
925923 return 0;
926924 }
927− return cg_invalf(fc, "cgroup1: Unknown subsys name '%s'", param->key);
925+ return invalf(fc, "cgroup1: Unknown subsys name '%s'", param->key);
928926 }
929927 if (opt < 0)
930928 return opt;
@@ -952,7 +950,7 @@ int cgroup1_parse_param(struct fs_context *fc, struct fs_parameter *param) · 21 unmodified lines
952950 case Opt_release_agent:
953951 /* Specifying two release agents is forbidden */
954952 if (ctx->release_agent)
955− return cg_invalf(fc, "cgroup1: release_agent respecified");
953+ return invalf(fc, "cgroup1: release_agent respecified");
956954 ctx->release_agent = param->string;
957955 param->string = NULL;
958956 break;
@@ -962,9 +960,9 @@ int cgroup1_parse_param(struct fs_context *fc, struct fs_parameter *param) · 3 unmodified lines
962960 return -ENOENT;
963961 /* Can't specify an empty name */
964962 if (!param->size)
965− return cg_invalf(fc, "cgroup1: Empty name");
963+ return invalf(fc, "cgroup1: Empty name");
966964 if (param->size > MAX_CGROUP_ROOT_NAMELEN - 1)
967− return cg_invalf(fc, "cgroup1: Name too long");
965+ return invalf(fc, "cgroup1: Name too long");
968966 /* Must match [\w.-]+ */
969967 for (i = 0; i < param->size; i++) {
970968 char c = param->string[i];
@@ -972,11 +970,11 @@ int cgroup1_parse_param(struct fs_context *fc, struct fs_parameter *param) · 1 unmodified line
972970 continue;
973971 if ((c == '.') || (c == '-') || (c == '_'))
974972 continue;
975− return cg_invalf(fc, "cgroup1: Invalid name");
973+ return invalf(fc, "cgroup1: Invalid name");
976974 }
977975 /* Specifying two names is forbidden */
978976 if (ctx->name)
979− return cg_invalf(fc, "cgroup1: name respecified");
977+ return invalf(fc, "cgroup1: name respecified");
980978 ctx->name = param->string;
981979 param->string = NULL;
982980 break;
@@ -1011,7 +1009,7 @@ static int check_cgroupfs_options(struct fs_context *fc) · 28 unmodified lines
10111009 if (ctx->all_ss) {
10121010 /* Mutually exclusive option 'all' + subsystem name */
10131011 if (ctx->subsys_mask)
1014− return cg_invalf(fc, "cgroup1: subsys name conflicts with all");
1012+ return invalf(fc, "cgroup1: subsys name conflicts with all");
10151013 /* 'all' => select all the subsystems */
10161014 ctx->subsys_mask = enabled;
10171015 }
@@ -1021,7 +1019,7 @@ static int check_cgroupfs_options(struct fs_context *fc) · 3 unmodified lines
10211019 * empty hierarchies must have a name).
10221020 */
10231021 if (!ctx->subsys_mask && !ctx->name)
1024− return cg_invalf(fc, "cgroup1: Need name or subsystem set");
1022+ return invalf(fc, "cgroup1: Need name or subsystem set");
10251023
10261024 /*
10271025 * Option noprefix was introduced just for backward compatibility
@@ -1029,11 +1027,11 @@ static int check_cgroupfs_options(struct fs_context *fc) · 1 unmodified line
10291027 * the cpuset subsystem.
10301028 */
10311029 if ((ctx->flags & CGRP_ROOT_NOPREFIX) && (ctx->subsys_mask & mask))
1032− return cg_invalf(fc, "cgroup1: noprefix used incorrectly");
1030+ return invalf(fc, "cgroup1: noprefix used incorrectly");
10331031
10341032 /* Can't specify "none" and some subsystems */
10351033 if (ctx->subsys_mask && ctx->none)
1036− return cg_invalf(fc, "cgroup1: none used incorrectly");
1034+ return invalf(fc, "cgroup1: none used incorrectly");
10371035
10381036 return 0;
10391037 }
@@ -1063,7 +1061,7 @@ int cgroup1_reconfigure(struct fs_context *fc) · 23 unmodified lines
10631061 /* Don't allow flags or name to change at remount */
10641062 if ((ctx->flags ^ root->flags) ||
10651063 (ctx->name && strcmp(ctx->name, root->name))) {
1066− cg_invalf(fc, "option or name mismatch, new: 0x%x \"%s\", old: 0x%x \"%s\"",
1064+ errorf(fc, "option or name mismatch, new: 0x%x \"%s\", old: 0x%x \"%s\"",
10671065 ctx->flags, ctx->name ?: "", root->flags, root->name);
10681066 ret = -EINVAL;
10691067 goto out_unlock;
@@ -1180,7 +1178,7 @@ static int cgroup1_root_to_use(struct fs_context *fc) · 110 unmodified lines
11801178 * can't create new one without subsys specification.
11811179 */
11821180 if (!ctx->subsys_mask && !ctx->none)
1183− return cg_invalf(fc, "cgroup1: No subsys list or none specified");
1181+ return invalf(fc, "cgroup1: No subsys list or none specified");
11841182
11851183 /* Hierarchies may only be created in the initial cgroup namespace. */
11861184 if (ctx->ns != &init_cgroup_ns)