From: Shuah Khan <skhan@linuxfoundation.org>
To: Brahadambal Srinivasan <latha@linux.vnet.ibm.com>,
shuah@kernel.org, trenn@suse.com
Cc: Janakarajan.Natarajan@amd.com, linux-pm@vger.kernel.org,
linux-kernel@vger.kernel.org,
"Pavithra R . Prakash" <pavrampu@in.ibm.com>,
Shuah Khan <skhan@linuxfoundation.org>
Subject: Re: [PATCH v2] cpupower: Provide online and offline CPU information
Date: Fri, 2 Oct 2020 11:27:51 -0600 [thread overview]
Message-ID: <6694193a-f44e-1239-26c2-7e01650964fc@linuxfoundation.org> (raw)
In-Reply-To: <20200929131108.19435-1-latha@linux.vnet.ibm.com>
On 9/29/20 7:11 AM, Brahadambal Srinivasan wrote:
> When a user tries to modify cpuidle or cpufreq properties on offline
> CPUs, the tool returns success (exit status 0) but also does not provide
> any warning message regarding offline cpus that may have been specified
> but left unchanged. In case of all or a few CPUs being offline, it can be
> difficult to keep track of which CPUs didn't get the new frequency or idle
> state set. Silent failures are difficult to keep track of when there are a
> huge number of CPUs on which the action is performed.
>
> This patch adds helper functions to find both online and offline CPUs and
> print them out accordingly.
>
> We use these helper functions in cpuidle-set and cpufreq-set to print an
> additional message if the user attempts to modify offline cpus.
>
> Reported-by: Pavithra R. Prakash <pavrampu@in.ibm.com>
> Signed-off-by: Brahadambal Srinivasan <latha@linux.vnet.ibm.com>
> ---
> tools/power/cpupower/utils/cpufreq-set.c | 3 +
> tools/power/cpupower/utils/cpuidle-set.c | 4 ++
> tools/power/cpupower/utils/cpupower.c | 8 +++
> tools/power/cpupower/utils/helpers/helpers.h | 12 ++++
> tools/power/cpupower/utils/helpers/misc.c | 66 +++++++++++++++++++-
> 5 files changed, 92 insertions(+), 1 deletion(-)
>
Please elaborate the changes made since v1.
I am seeing compile warnings. Please fix and send v3.
utils/cpufreq-set.c: In function ‘cmd_freq_set’:
utils/cpufreq-set.c:332:2: warning: implicit declaration of function
‘print_offline_cpus’ [-Wimplicit-function-declaration]
332 | print_offline_cpus();
| ^~~~~~~~~~~~~~~~~~
CC utils/cpupower-set.o
CC utils/cpupower-info.o
CC utils/cpuidle-info.o
CC utils/cpuidle-set.o
utils/cpuidle-set.c: In function ‘cmd_idle_set’:
utils/cpuidle-set.c:187:2: warning: implicit declaration of function
‘print_offline_cpus’ [-Wimplicit-function-declaration]
187 | print_offline_cpus();
thanks,
-- Shuah
prev parent reply other threads:[~2020-10-02 17:27 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-29 13:11 Brahadambal Srinivasan
2020-10-02 17:27 ` Shuah Khan [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=6694193a-f44e-1239-26c2-7e01650964fc@linuxfoundation.org \
--to=skhan@linuxfoundation.org \
--cc=Janakarajan.Natarajan@amd.com \
--cc=latha@linux.vnet.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=pavrampu@in.ibm.com \
--cc=shuah@kernel.org \
--cc=trenn@suse.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®