linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chanwoo Choi <cwchoi00@gmail.com>
To: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: cw00.choi@samsung.com, myungjoo.ham@samsung.com,
	kyungmin.park@samsung.com, johnson.wang@mediatek.com,
	mka@chromium.org, jia-wei.chang@mediatek.com,
	andrew-sh.cheng@mediatek.com, hsinyi@chromium.org,
	sibis@codeaurora.org, saravanak@google.com
Subject: [PATCH v2 0/5] PM / devfreq: Add cpu based scaling support to passive governor
Date: Sun,  8 May 2022 00:01:40 +0900	[thread overview]
Message-ID: <20220507150145.531864-1-cw00.choi@samsung.com> (raw)

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 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 (4):
  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
  PM / devfreq: passive: Update frequency when start governor

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 | 412 ++++++++++++++++++++++++-----
 include/linux/devfreq.h            |  17 +-
 4 files changed, 402 insertions(+), 74 deletions(-)

-- 
2.25.1


             reply	other threads:[~2022-05-07 15:02 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-07 15:01 Chanwoo Choi [this message]
2022-05-07 15:01 ` [PATCH v2 1/5] PM / devfreq: Export devfreq_get_freq_range symbol within devfreq Chanwoo Choi
2022-05-07 15:01 ` [PATCH v2 2/5] PM / devfreq: Add cpu based scaling support to passive governor Chanwoo Choi
2022-05-07 15:01 ` [PATCH v2 3/5] PM / devfreq: passive: Reduce duplicate code when passive_devfreq case Chanwoo Choi
2022-05-07 15:01 ` [PATCH v2 4/5] PM / devfreq: passive: Keep cpufreq_policy for possible cpus Chanwoo Choi
2022-05-07 15:01 ` [PATCH v2 5/5] PM / devfreq: passive: Update frequency when start governor Chanwoo Choi
2022-05-09  4:25   ` Chen-Yu Tsai
2022-05-09 10:29     ` 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=20220507150145.531864-1-cw00.choi@samsung.com \
    --to=cwchoi00@gmail.com \
    --cc=andrew-sh.cheng@mediatek.com \
    --cc=cw00.choi@samsung.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=mka@chromium.org \
    --cc=myungjoo.ham@samsung.com \
    --cc=saravanak@google.com \
    --cc=sibis@codeaurora.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).