diff options
Diffstat (limited to 'tools/power/cpupower/utils/cpupower.c')
-rw-r--r-- | tools/power/cpupower/utils/cpupower.c | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/tools/power/cpupower/utils/cpupower.c b/tools/power/cpupower/utils/cpupower.c index 52bee591c1c5..7efc570ffbaa 100644 --- a/tools/power/cpupower/utils/cpupower.c +++ b/tools/power/cpupower/utils/cpupower.c | |||
@@ -17,12 +17,6 @@ | |||
17 | #include "helpers/helpers.h" | 17 | #include "helpers/helpers.h" |
18 | #include "helpers/bitmask.h" | 18 | #include "helpers/bitmask.h" |
19 | 19 | ||
20 | struct cmd_struct { | ||
21 | const char *cmd; | ||
22 | int (*main)(int, const char **); | ||
23 | int needs_root; | ||
24 | }; | ||
25 | |||
26 | #define ARRAY_SIZE(x) (sizeof(x)/sizeof(x[0])) | 20 | #define ARRAY_SIZE(x) (sizeof(x)/sizeof(x[0])) |
27 | 21 | ||
28 | static int cmd_help(int argc, const char **argv); | 22 | static int cmd_help(int argc, const char **argv); |
@@ -43,10 +37,17 @@ int be_verbose; | |||
43 | 37 | ||
44 | static void print_help(void); | 38 | static void print_help(void); |
45 | 39 | ||
40 | struct cmd_struct { | ||
41 | const char *cmd; | ||
42 | int (*main)(int, const char **); | ||
43 | int needs_root; | ||
44 | }; | ||
45 | |||
46 | static struct cmd_struct commands[] = { | 46 | static struct cmd_struct commands[] = { |
47 | { "frequency-info", cmd_freq_info, 0 }, | 47 | { "frequency-info", cmd_freq_info, 0 }, |
48 | { "frequency-set", cmd_freq_set, 1 }, | 48 | { "frequency-set", cmd_freq_set, 1 }, |
49 | { "idle-info", cmd_idle_info, 0 }, | 49 | { "idle-info", cmd_idle_info, 0 }, |
50 | { "idle-set", cmd_idle_set, 1 }, | ||
50 | { "set", cmd_set, 1 }, | 51 | { "set", cmd_set, 1 }, |
51 | { "info", cmd_info, 0 }, | 52 | { "info", cmd_info, 0 }, |
52 | { "monitor", cmd_monitor, 0 }, | 53 | { "monitor", cmd_monitor, 0 }, |