From: Dmitry Osipenko <digetx@gmail.com>
To: sumitg <sumitg@nvidia.com>,
rjw@rjwysocki.net, viresh.kumar@linaro.org,
catalin.marinas@arm.com, will@kernel.org,
thierry.reding@gmail.com, jonathanh@nvidia.com, talho@nvidia.com,
linux-pm@vger.kernel.org, linux-tegra@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org
Cc: bbasu@nvidia.com, mperttunen@nvidia.com
Subject: Re: [TEGRA194_CPUFREQ Patch v2 2/3] cpufreq: Add Tegra194 cpufreq driver
Date: Tue, 7 Apr 2020 22:12:00 +0300 [thread overview]
Message-ID: <3009a636-0c85-c867-6dcb-2deb1a610a00@gmail.com> (raw)
In-Reply-To: <538ddcf4-b760-a342-eab6-5a61c9bd860a@nvidia.com>
07.04.2020 21:55, sumitg пишет:
...
>>> + * Returns freq in KHz on success, 0 if cpu is offline
>>
>> I don't see any checks in the code about whether CPU is offline.
>>
>> Googling for "queue_work_on offline cpu" suggests that this function
>> should hang.
>>
> Tried this and didn't get crash or hang.
> show_cpuinfo_cur_freq() returns "<unknown>" value on reading frequency
> from a cluster having both it's cores offline.
> If only one cpu is offline, then frequency of other online cpu which is
> managing the policy of that cluster is returned.
> Have still added below check as guard in get|set() freq calls.
> if (!cpu_online(cpu))
> return -EINVAL;
> Thankyou for the input.
If CPUFreq core takes care of taking into account the offline CPU, then
the check isn't needed. It also wouldn't be enough if there was a
problem here.
next prev parent reply other threads:[~2020-04-07 19:12 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-04 19:29 [TEGRA194_CPUFREQ Patch v2 0/3] Add cpufreq driver for Tegra194 Sumit Gupta
2020-04-04 19:29 ` [TEGRA194_CPUFREQ Patch v2 1/3] firmware: tegra: adding function to get BPMP data Sumit Gupta
2020-04-04 19:29 ` [TEGRA194_CPUFREQ Patch v2 2/3] cpufreq: Add Tegra194 cpufreq driver Sumit Gupta
2020-04-05 14:05 ` Dmitry Osipenko
2020-04-07 18:55 ` sumitg
2020-04-07 19:12 ` Dmitry Osipenko [this message]
2020-04-05 14:11 ` Dmitry Osipenko
2020-04-07 18:56 ` sumitg
2020-04-04 19:29 ` [TEGRA194_CPUFREQ Patch v2 3/3] arm64: defconfig: Enable CONFIG_ARM_TEGRA194_CPUFREQ Sumit Gupta
2020-04-06 2:47 ` [TEGRA194_CPUFREQ Patch v2 0/3] Add cpufreq driver for Tegra194 Viresh Kumar
2020-04-06 6:06 ` sumitg
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=3009a636-0c85-c867-6dcb-2deb1a610a00@gmail.com \
--to=digetx@gmail.com \
--cc=bbasu@nvidia.com \
--cc=catalin.marinas@arm.com \
--cc=jonathanh@nvidia.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux-tegra@vger.kernel.org \
--cc=mperttunen@nvidia.com \
--cc=rjw@rjwysocki.net \
--cc=sumitg@nvidia.com \
--cc=talho@nvidia.com \
--cc=thierry.reding@gmail.com \
--cc=viresh.kumar@linaro.org \
--cc=will@kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).