All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chanwoo Choi <cw00.choi@samsung.com>
To: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: johnson.wang@mediatek.com, mka@chromium.org, wenst@chromium.org,
	jia-wei.chang@mediatek.com, andrew-sh.cheng@mediatek.com,
	hsinyi@chromium.org, m.szyprowski@samsung.com,
	saravanak@google.com, cw00.choi@samsung.com,
	myungjoo.ham@samsung.com, kyungmin.park@samsung.com
Subject: [PATCH v5 0/4] PM / devfreq: Add cpu based scaling support to passive governor
Date: Tue, 17 May 2022 18:21:04 +0900	[thread overview]
Message-ID: <20220517092108.31680-1-cw00.choi@samsung.com> (raw)
In-Reply-To: CGME20220517085446epcas1p4c07ab7d3b80d62c0093c3a45484eae97@epcas1p4.samsung.com

The devfreq passive governor has already supported the devfreq parent device
for coupling the frequency change if some hardware have the constraints
such as power sharing and so on.

Add cpu based scaling support to passive governor with required-opp property.
It uses the cpufreq notifier to catch the frequency change timing of cpufreq
and get the next frequency according to new cpu frequency by using required-opp
property. It is based on patch[1] and then just code clean-up by myself.

Make the common code for both passive_devfreq and passive_cpufreq
parent type to remove the duplicate code.

[1] [RFC,v2] PM / devfreq: Add cpu based scaling support to passive_governor
- https://lore.kernel.org/patchwork/patch/1101049/

Changes from v4:
: https://patchwork.kernel.org/project/linux-pm/cover/20220511093554.17535-1-cw00.choi@samsung.com/
- Fix issue[2] reported by Marek Szyprowski
[2] https://patchwork.kernel.org/project/linux-pm/patch/20220511093554.17535-3-cw00.choi@samsung.com/

Changes from v3:
: ttps://patchwork.kernel.org/project/linux-pm/cover/20220509120337.92472-1-cw00.choi@samsung.com/
- Add tested-by tag of both Chen-Yu Tsai and Johnson Wang
- Fix some typo

Changes from v2:
: https://patchwork.kernel.org/project/linux-pm/cover/20220507150145.531864-1-cw00.choi@samsung.com/
- Drop the following patch ("PM / devfreq: passive: Update frequency when start governor")
- Move p_data->this initialization into cpufreq_passive_regiser_notifier()

Changes from v1:
: https://patchwork.kernel.org/project/linux-pm/cover/20210617060546.26933-1-cw00.choi@samsung.com/
- Rename cpu_data variable to parent_cpu_data to avoid build fail
- Use for_each_possible_cpu macro when register cpufreq transition notifier
- Add missing exception handling when cpufreq_passive_register_notifier is failed
- Keep cpufreq_policy for posible cpus instead of NR_CPU in order to avoid
  the memory waste when NR_CPU is too high.
- Add reviewed-by tag of Matthias Kaehlcke for patch1

Chanwoo Choi (3):
  PM / devfreq: Export devfreq_get_freq_range symbol within devfreq
  PM / devfreq: passive: Reduce duplicate code when passive_devfreq case
  PM / devfreq: passive: Keep cpufreq_policy for possible cpus

Saravana Kannan (1):
  PM / devfreq: Add cpu based scaling support to passive governor

 drivers/devfreq/devfreq.c          |  20 +-
 drivers/devfreq/governor.h         |  27 ++
 drivers/devfreq/governor_passive.c | 403 ++++++++++++++++++++++++-----
 include/linux/devfreq.h            |  17 +-
 4 files changed, 389 insertions(+), 78 deletions(-)

-- 
2.17.1


       reply	other threads:[~2022-05-17  8:55 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20220517085446epcas1p4c07ab7d3b80d62c0093c3a45484eae97@epcas1p4.samsung.com>
2022-05-17  9:21 ` Chanwoo Choi [this message]
     [not found]   ` <CGME20220517085447epcas1p486bdbfab57211a12409e590abee05556@epcas1p4.samsung.com>
2022-05-17  9:21     ` [PATCH v5 1/4] PM / devfreq: Export devfreq_get_freq_range symbol within devfreq Chanwoo Choi
     [not found]   ` <CGME20220517085448epcas1p46423db24a3211003238b6c5947228923@epcas1p4.samsung.com>
2022-05-17  9:21     ` [PATCH v5 2/4] PM / devfreq: Add cpu based scaling support to passive governor Chanwoo Choi
     [not found]   ` <CGME20220517085449epcas1p4a2e53dda3af368e452d9caaa572d71ae@epcas1p4.samsung.com>
2022-05-17  9:21     ` [PATCH v5 3/4] PM / devfreq: passive: Reduce duplicate code when passive_devfreq case Chanwoo Choi
     [not found]   ` <CGME20220517085450epcas1p3601e3fa12dbce84aeee34ae38c7d689f@epcas1p3.samsung.com>
2022-05-17  9:21     ` [PATCH v5 4/4] PM / devfreq: passive: Keep cpufreq_policy for possible cpus Chanwoo Choi
2022-05-18 10:56   ` [PATCH v5 0/4] PM / devfreq: Add cpu based scaling support to passive governor Marek Szyprowski
2022-05-19  0:25     ` Chanwoo Choi
2022-05-19  0:44     ` Chanwoo Choi

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=20220517092108.31680-1-cw00.choi@samsung.com \
    --to=cw00.choi@samsung.com \
    --cc=andrew-sh.cheng@mediatek.com \
    --cc=hsinyi@chromium.org \
    --cc=jia-wei.chang@mediatek.com \
    --cc=johnson.wang@mediatek.com \
    --cc=kyungmin.park@samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=m.szyprowski@samsung.com \
    --cc=mka@chromium.org \
    --cc=myungjoo.ham@samsung.com \
    --cc=saravanak@google.com \
    --cc=wenst@chromium.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.