* Re: [PATCH v3 1/2] cpufreq: Fix a comment in cpufreq_policy_free
2021-12-01 7:40 ` [PATCH v3 1/2] cpufreq: Fix a comment in cpufreq_policy_free Tang Yizhou
@ 2021-12-01 7:19 ` Viresh Kumar
2021-12-01 19:04 ` Rafael J. Wysocki
0 siblings, 1 reply; 5+ messages in thread
From: Viresh Kumar @ 2021-12-01 7:19 UTC (permalink / raw)
To: Tang Yizhou; +Cc: rafael.j.wysocki, rafael, linux-pm, linux-kernel, zhengbin13
On 01-12-21, 15:40, Tang Yizhou wrote:
> Make the comment of blocking_notifier_call_chain() easier to
> understand.
>
> Signed-off-by: Tang Yizhou <tangyizhou@huawei.com>
> ---
> drivers/cpufreq/cpufreq.c | 5 +++--
> 1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
> index e338d2f010fe..db0b4b4258d5 100644
> --- a/drivers/cpufreq/cpufreq.c
> +++ b/drivers/cpufreq/cpufreq.c
> @@ -1296,8 +1296,9 @@ static void cpufreq_policy_free(struct cpufreq_policy *policy)
>
> if (policy->max_freq_req) {
> /*
> - * CPUFREQ_CREATE_POLICY notification is sent only after
> - * successfully adding max_freq_req request.
> + * Remove max_freq_req after sending CPUFREQ_REMOVE_POLICY
> + * notification, since CPUFREQ_CREATE_POLICY notification was
> + * sent after adding max_freq_req earlier.
> */
> blocking_notifier_call_chain(&cpufreq_policy_notifier_list,
> CPUFREQ_REMOVE_POLICY, policy);
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
--
viresh
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v3 0/2] cpufreq: Update function comment and document
@ 2021-12-01 7:40 Tang Yizhou
2021-12-01 7:40 ` [PATCH v3 1/2] cpufreq: Fix a comment in cpufreq_policy_free Tang Yizhou
2021-12-01 7:40 ` [PATCH v3 2/2] doc/cpufreq: Update core.rst Tang Yizhou
0 siblings, 2 replies; 5+ messages in thread
From: Tang Yizhou @ 2021-12-01 7:40 UTC (permalink / raw)
To: viresh.kumar, rafael.j.wysocki, rafael
Cc: linux-pm, linux-kernel, zhengbin13, Tang Yizhou
v3:
Take viresh's advice and update the comments in cpufreq.c
v2:
1. Take viresh's advice and update the comments in cpufreq.c
2. Add an Acked-by tag in Patch 2.
Tang Yizhou (2):
cpufreq: Fix a comment in cpufreq_policy_free
doc/cpufreq: Update core.rst
Documentation/cpu-freq/core.rst | 6 +++---
drivers/cpufreq/cpufreq.c | 5 +++--
2 files changed, 6 insertions(+), 5 deletions(-)
--
2.17.1
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v3 1/2] cpufreq: Fix a comment in cpufreq_policy_free
2021-12-01 7:40 [PATCH v3 0/2] cpufreq: Update function comment and document Tang Yizhou
@ 2021-12-01 7:40 ` Tang Yizhou
2021-12-01 7:19 ` Viresh Kumar
2021-12-01 7:40 ` [PATCH v3 2/2] doc/cpufreq: Update core.rst Tang Yizhou
1 sibling, 1 reply; 5+ messages in thread
From: Tang Yizhou @ 2021-12-01 7:40 UTC (permalink / raw)
To: viresh.kumar, rafael.j.wysocki, rafael
Cc: linux-pm, linux-kernel, zhengbin13, Tang Yizhou
Make the comment of blocking_notifier_call_chain() easier to
understand.
Signed-off-by: Tang Yizhou <tangyizhou@huawei.com>
---
drivers/cpufreq/cpufreq.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
index e338d2f010fe..db0b4b4258d5 100644
--- a/drivers/cpufreq/cpufreq.c
+++ b/drivers/cpufreq/cpufreq.c
@@ -1296,8 +1296,9 @@ static void cpufreq_policy_free(struct cpufreq_policy *policy)
if (policy->max_freq_req) {
/*
- * CPUFREQ_CREATE_POLICY notification is sent only after
- * successfully adding max_freq_req request.
+ * Remove max_freq_req after sending CPUFREQ_REMOVE_POLICY
+ * notification, since CPUFREQ_CREATE_POLICY notification was
+ * sent after adding max_freq_req earlier.
*/
blocking_notifier_call_chain(&cpufreq_policy_notifier_list,
CPUFREQ_REMOVE_POLICY, policy);
--
2.17.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH v3 2/2] doc/cpufreq: Update core.rst
2021-12-01 7:40 [PATCH v3 0/2] cpufreq: Update function comment and document Tang Yizhou
2021-12-01 7:40 ` [PATCH v3 1/2] cpufreq: Fix a comment in cpufreq_policy_free Tang Yizhou
@ 2021-12-01 7:40 ` Tang Yizhou
1 sibling, 0 replies; 5+ messages in thread
From: Tang Yizhou @ 2021-12-01 7:40 UTC (permalink / raw)
To: viresh.kumar, rafael.j.wysocki, rafael
Cc: linux-pm, linux-kernel, zhengbin13, Tang Yizhou
As the definition of struct cpufreq_freqs has changed, update core.rst
with the new first member of struct cpufreq_freqs.
Signed-off-by: Tang Yizhou <tangyizhou@huawei.com>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
---
Documentation/cpu-freq/core.rst | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/Documentation/cpu-freq/core.rst b/Documentation/cpu-freq/core.rst
index 33cb90bd1d8f..4ceef8e7217c 100644
--- a/Documentation/cpu-freq/core.rst
+++ b/Documentation/cpu-freq/core.rst
@@ -73,12 +73,12 @@ CPUFREQ_POSTCHANGE.
The third argument is a struct cpufreq_freqs with the following
values:
-===== ===========================
-cpu number of the affected CPU
+====== ======================================
+policy a pointer to the struct cpufreq_policy
old old frequency
new new frequency
flags flags of the cpufreq driver
-===== ===========================
+====== ======================================
3. CPUFreq Table Generation with Operating Performance Point (OPP)
==================================================================
--
2.17.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v3 1/2] cpufreq: Fix a comment in cpufreq_policy_free
2021-12-01 7:19 ` Viresh Kumar
@ 2021-12-01 19:04 ` Rafael J. Wysocki
0 siblings, 0 replies; 5+ messages in thread
From: Rafael J. Wysocki @ 2021-12-01 19:04 UTC (permalink / raw)
To: Viresh Kumar, Tang Yizhou
Cc: Rafael Wysocki, Rafael J. Wysocki, Linux PM,
Linux Kernel Mailing List, zhengbin13
On Wed, Dec 1, 2021 at 8:19 AM Viresh Kumar <viresh.kumar@linaro.org> wrote:
>
> On 01-12-21, 15:40, Tang Yizhou wrote:
> > Make the comment of blocking_notifier_call_chain() easier to
> > understand.
> >
> > Signed-off-by: Tang Yizhou <tangyizhou@huawei.com>
> > ---
> > drivers/cpufreq/cpufreq.c | 5 +++--
> > 1 file changed, 3 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/cpufreq/cpufreq.c b/drivers/cpufreq/cpufreq.c
> > index e338d2f010fe..db0b4b4258d5 100644
> > --- a/drivers/cpufreq/cpufreq.c
> > +++ b/drivers/cpufreq/cpufreq.c
> > @@ -1296,8 +1296,9 @@ static void cpufreq_policy_free(struct cpufreq_policy *policy)
> >
> > if (policy->max_freq_req) {
> > /*
> > - * CPUFREQ_CREATE_POLICY notification is sent only after
> > - * successfully adding max_freq_req request.
> > + * Remove max_freq_req after sending CPUFREQ_REMOVE_POLICY
> > + * notification, since CPUFREQ_CREATE_POLICY notification was
> > + * sent after adding max_freq_req earlier.
> > */
> > blocking_notifier_call_chain(&cpufreq_policy_notifier_list,
> > CPUFREQ_REMOVE_POLICY, policy);
>
> Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Applied as 5.16-rc material along with the [2/2[, thanks!
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2021-12-01 19:04 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-01 7:40 [PATCH v3 0/2] cpufreq: Update function comment and document Tang Yizhou
2021-12-01 7:40 ` [PATCH v3 1/2] cpufreq: Fix a comment in cpufreq_policy_free Tang Yizhou
2021-12-01 7:19 ` Viresh Kumar
2021-12-01 19:04 ` Rafael J. Wysocki
2021-12-01 7:40 ` [PATCH v3 2/2] doc/cpufreq: Update core.rst Tang Yizhou
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).