Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f57ab32a authored by Rafael J. Wysocki's avatar Rafael J. Wysocki
Browse files

Merge branch 'pm-tools'

* pm-tools:
  Creating a common structure initialization pattern for struct option
  cpupower: Enable disabled Cstates if they are below max latency
  cpupower: Remove debug message when using cpupower idle-set -D switch
  cpupower: cpupower monitor reports uninitialized values for offline cpus
  tools/power turbostat: bugfix: print MAX_NON_TURBO_RATIO
  tools/power turbostat: simplify Bzy_MHz calculation
parents f6f18a26 89ba7d8c
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -134,7 +134,7 @@ next_one:
}

static struct option info_opts[] = {
	{.name = "numpst",	.has_arg=no_argument,	.flag=NULL, .val='n'},
     {"numpst", no_argument, NULL, 'n'},
};

void print_help(void)
+3 −1
Original line number Diff line number Diff line
@@ -20,7 +20,9 @@ Disable a specific processor sleep state.
Enable a specific processor sleep state.
.TP
\fB\-D\fR \fB\-\-disable-by-latency\fR <LATENCY>
Disable all idle states with a equal or higher latency than <LATENCY>
Disable all idle states with a equal or higher latency than <LATENCY>.

Enable all idle states with a latency lower than <LATENCY>.
.TP
\fB\-E\fR \fB\-\-enable-all\fR
Enable all idle states if not enabled already.
+15 −15
Original line number Diff line number Diff line
@@ -536,21 +536,21 @@ static int get_latency(unsigned int cpu, unsigned int human)
}

static struct option info_opts[] = {
	{ .name = "debug",	.has_arg = no_argument,		.flag = NULL,	.val = 'e'},
	{ .name = "boost",	.has_arg = no_argument,		.flag = NULL,	.val = 'b'},
	{ .name = "freq",	.has_arg = no_argument,		.flag = NULL,	.val = 'f'},
	{ .name = "hwfreq",	.has_arg = no_argument,		.flag = NULL,	.val = 'w'},
	{ .name = "hwlimits",	.has_arg = no_argument,		.flag = NULL,	.val = 'l'},
	{ .name = "driver",	.has_arg = no_argument,		.flag = NULL,	.val = 'd'},
	{ .name = "policy",	.has_arg = no_argument,		.flag = NULL,	.val = 'p'},
	{ .name = "governors",	.has_arg = no_argument,		.flag = NULL,	.val = 'g'},
	{ .name = "related-cpus", .has_arg = no_argument,	.flag = NULL,	.val = 'r'},
	{ .name = "affected-cpus",.has_arg = no_argument,	.flag = NULL,	.val = 'a'},
	{ .name = "stats",	.has_arg = no_argument,		.flag = NULL,	.val = 's'},
	{ .name = "latency",	.has_arg = no_argument,		.flag = NULL,	.val = 'y'},
	{ .name = "proc",	.has_arg = no_argument,		.flag = NULL,	.val = 'o'},
	{ .name = "human",	.has_arg = no_argument,		.flag = NULL,	.val = 'm'},
	{ .name = "no-rounding", .has_arg = no_argument,	.flag = NULL,	.val = 'n'},
	{"debug",	 no_argument,		 NULL,	 'e'},
	{"boost",	 no_argument,		 NULL,	 'b'},
	{"freq",	 no_argument,		 NULL,	 'f'},
	{"hwfreq",	 no_argument,		 NULL,	 'w'},
	{"hwlimits",	 no_argument,		 NULL,	 'l'},
	{"driver",	 no_argument,		 NULL,	 'd'},
	{"policy",	 no_argument,		 NULL,	 'p'},
	{"governors",	 no_argument,		 NULL,	 'g'},
	{"related-cpus",  no_argument,	 NULL,	 'r'},
	{"affected-cpus", no_argument,	 NULL,	 'a'},
	{"stats",	 no_argument,		 NULL,	 's'},
	{"latency",	 no_argument,		 NULL,	 'y'},
	{"proc",	 no_argument,		 NULL,	 'o'},
	{"human",	 no_argument,		 NULL,	 'm'},
	{"no-rounding", no_argument,	 NULL,	 'n'},
	{ },
};

+5 −5
Original line number Diff line number Diff line
@@ -22,11 +22,11 @@
#define NORM_FREQ_LEN 32

static struct option set_opts[] = {
	{ .name = "min",	.has_arg = required_argument,	.flag = NULL,	.val = 'd'},
	{ .name = "max",	.has_arg = required_argument,	.flag = NULL,	.val = 'u'},
	{ .name = "governor",	.has_arg = required_argument,	.flag = NULL,	.val = 'g'},
	{ .name = "freq",	.has_arg = required_argument,	.flag = NULL,	.val = 'f'},
	{ .name = "related",	.has_arg = no_argument,		.flag = NULL,	.val='r'},
	{"min",		required_argument,	NULL, 'd'},
	{"max",		required_argument,	NULL, 'u'},
	{"governor",	required_argument,	NULL, 'g'},
	{"freq",	required_argument,	NULL, 'f'},
	{"related",	no_argument,		NULL, 'r'},
	{ },
};

+2 −2
Original line number Diff line number Diff line
@@ -126,8 +126,8 @@ static void proc_cpuidle_cpu_output(unsigned int cpu)
}

static struct option info_opts[] = {
	{ .name = "silent",	.has_arg = no_argument,	.flag = NULL,	.val = 's'},
	{ .name = "proc",	.has_arg = no_argument,	.flag = NULL,	.val = 'o'},
	{"silent", no_argument, NULL, 's'},
	{"proc", no_argument, NULL, 'o'},
	{ },
};

Loading