aboutsummaryrefslogtreecommitdiffstats
path: root/tools/power/cpupower/utils/cpupower-set.c
diff options
context:
space:
mode:
authorDominik Brodowski <linux@dominikbrodowski.net>2011-04-19 20:33:50 +0200
committerDominik Brodowski <linux@dominikbrodowski.net>2011-07-29 18:35:39 +0200
commita1ce5ba2b7d08ab6347dc254f86f70e91c5f1a44 (patch)
tree22d59faf4df1547bb9547935c7f63c3ef6a6b387 /tools/power/cpupower/utils/cpupower-set.c
parentcpupowerutils: helpers - ConfigStyle bugfixes (diff)
downloadlinux-dev-a1ce5ba2b7d08ab6347dc254f86f70e91c5f1a44.tar.xz
linux-dev-a1ce5ba2b7d08ab6347dc254f86f70e91c5f1a44.zip
cpupowerutils: utils - ConfigStyle bugfixes
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'tools/power/cpupower/utils/cpupower-set.c')
-rw-r--r--tools/power/cpupower/utils/cpupower-set.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/tools/power/cpupower/utils/cpupower-set.c b/tools/power/cpupower/utils/cpupower-set.c
index 3f807bc7a567..bc1b391e46f0 100644
--- a/tools/power/cpupower/utils/cpupower-set.c
+++ b/tools/power/cpupower/utils/cpupower-set.c
@@ -30,10 +30,10 @@ void set_help(void)
}
static struct option set_opts[] = {
- { .name="perf-bias", .has_arg=optional_argument, .flag=NULL, .val='b'},
- { .name="sched-mc", .has_arg=optional_argument, .flag=NULL, .val='m'},
- { .name="sched-smt", .has_arg=optional_argument, .flag=NULL, .val='s'},
- { .name="help", .has_arg=no_argument, .flag=NULL, .val='h'},
+ { .name = "perf-bias", .has_arg = optional_argument, .flag = NULL, .val = 'b'},
+ { .name = "sched-mc", .has_arg = optional_argument, .flag = NULL, .val = 'm'},
+ { .name = "sched-smt", .has_arg = optional_argument, .flag = NULL, .val = 's'},
+ { .name = "help", .has_arg = no_argument, .flag = NULL, .val = 'h'},
{ },
};
@@ -57,17 +57,17 @@ int cmd_set(int argc, char **argv)
int perf_bias:1;
};
int params;
-
} params;
int sched_mc = 0, sched_smt = 0, perf_bias = 0;
int ret = 0;
setlocale(LC_ALL, "");
- textdomain (PACKAGE);
+ textdomain(PACKAGE);
params.params = 0;
/* parameter parsing */
- while ((ret = getopt_long(argc, argv, "m:s:b:h", set_opts, NULL)) != -1) {
+ while ((ret = getopt_long(argc, argv, "m:s:b:h",
+ set_opts, NULL)) != -1) {
switch (ret) {
case 'h':
set_help();
@@ -135,7 +135,7 @@ int cmd_set(int argc, char **argv)
/* loop over CPUs */
for (cpu = bitmask_first(cpus_chosen);
cpu <= bitmask_last(cpus_chosen); cpu++) {
-
+
if (!bitmask_isbitset(cpus_chosen, cpu) ||
cpufreq_cpu_exists(cpu))
continue;