mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Chanwoo Choi <cw00.choi@samsung.com>
To: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-tegra@vger.kernel.org
Cc: digetx@gmail.com, lukasz.luba@arm.com,
	enric.balletbo@collabora.com, hl@rock-chips.com,
	thierry.reding@gmail.com, jonathanh@nvidia.com,
	abel.vesa@nxp.com, k.konieczny@samsung.com,
	b.zolnierkie@samsung.com, chanwoo@kernel.org,
	myungjoo.ham@samsung.com, kyungmin.park@samsung.com
Subject: Re: [PATCH v6 0/2] PM / devfreq: Add governor feature and attribute flag
Date: Mon, 26 Oct 2020 12:20:59 +0900	[thread overview]
Message-ID: <56da5f5c-faab-3d81-c438-e17301a41bb6@samsung.com> (raw)
In-Reply-To: <20201026025038.1480-1-cw00.choi@samsung.com>

On 10/26/20 11:50 AM, Chanwoo Choi wrote:
> Each devfreq governor can have the different sysfs attributes and features.
> In order to provide the only available sysfs attribute to user-space,
> add governor attribute flag with DEVFREQ_GOV_ATTR_[attribute name] defintion.
> 
> Also, each governor is able to have the specific flag in order to
> support specific feature with DEVFREQ_GOV_FLAG_[feature name] defintion
> like immutable governor.
> 
> According to each governor, can initiate the governor feature and attribute
> flags.
> 
> [Common sysfs attributes for devfreq class]
> And all devfreq governors have to support the following common attributes.
> The common attributes are added to devfreq class by default.
> - governor
> - available_governors
> - available_frequencies
> - cur_freq
> - target_freq
> - min_freq
> - max_freq
> - trans_stat
> 
> [Definition for governor attribute flag]
> - DEVFREQ_GOV_ATTR_POLLING_INTERVAL to update polling interval for timer.
>   : /sys/class/devfreq/[devfreq dev name]/polling_interval
> - DEVFREQ_GOV_ATTR_TIMER to change the type of timer on either deferrable
>   or dealyed timer.
>   : /sys/class/devfreq/[devfreq dev name]/timer
> 
> [Definition for governor feature flag]
> - DEVFREQ_GOV_FLAG_IMMUTABLE
>   : If immutable flag is set, governor is never changeable to other governors.
> - DEVFREQ_GOV_FLAG_IRQ_DRIVEN
>   : Devfreq core won't schedule polling work for this governor if value is set.
> 
> [Table of governor attribute flags for evfreq governors]
> -----------------------------------------------------------------------------
>                       | simple    | perfor | power | user | passive | tegra30
> 		      | ondemand  | mance  | save  | space|         |
> ------------------------------------------------------------------------------
> governor              | O         | O      | O     | O    | O       | O
> available_governors   | O         | O      | O     | O    | O       | O
> available_frequencies | O         | O      | O     | O    | O       | O
> cur_freq              | O         | O      | O     | O    | O       | O
> target_freq           | O         | O      | O     | O    | O       | O
> min_freq              | O         | O      | O     | O    | O       | O
> max_freq              | O         | O      | O     | O    | O       | O
> trans_stat            | O         | O      | O     | O    | O       | O
> ------------------------------------------------------------------------------
> polling_interval      | O         | X      | X     | X    | X       | O
> timer                 | O         | X      | X     | X    | X       | X
> ------------------------------------------------------------------------------
> immutable             | X         | X      | X     | X    | O       | O
> interrupt_driven      | X(polling)| X      | X     | X    | X       | O (irq)
> ------------------------------------------------------------------------------
> 
> Changes from v5:
> - Remove redundant code for creating syfs files.
> - Move create_sysfs_files() position after completed governor start on
> devfreq_add_device()
> - Add reviewd-by/tested-by tag of Dmitry Osipenko
> 
> Changes from v4:
> - Rename from 'attr' to 'attrs'
> - Restore the variable name in governor_store because it is enought to explain
> the previous or new governor with detailed comments instead of variable name
> changes.
> 
> Changes from v3:
> - Fix typo
> - Rename from 'flag' to 'flags'
> - Add more exception handling code and add comments on governor_store()
> 
> Changes from v2:
> - Hide unsupported sysfs node to user-space instead of checking the permission
> of sysfs node.
> 
> Chanwoo Choi (2):
>   PM / devfreq: Add governor feature flag
>   PM / devfreq: Add governor attribute flag for specifc sysfs nodes
> 
>  Documentation/ABI/testing/sysfs-class-devfreq |  54 ++---
>  drivers/devfreq/devfreq.c                     | 187 ++++++++++++------
>  drivers/devfreq/governor.h                    |  30 ++-
>  drivers/devfreq/governor_passive.c            |   2 +-
>  drivers/devfreq/governor_simpleondemand.c     |   2 +
>  drivers/devfreq/tegra30-devfreq.c             |   5 +-
>  6 files changed, 188 insertions(+), 92 deletions(-)
> 

Applied them.

-- 
Best Regards,
Chanwoo Choi
Samsung Electronics

      parent reply	other threads:[~2020-10-26  3:07 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20201026023654epcas1p4866b7bbcb7276996500ee5c05d2c37f0@epcas1p4.samsung.com>
2020-10-26  2:50 ` Chanwoo Choi
     [not found]   ` <CGME20201026023654epcas1p3add83f4f2b27b50a322a8c27451b7d98@epcas1p3.samsung.com>
2020-10-26  2:50     ` [PATCH v6 1/2] PM / devfreq: Add governor feature flag Chanwoo Choi
     [not found]   ` <CGME20201026023655epcas1p1abc7a1281b15a8b56399f3a694afceb4@epcas1p1.samsung.com>
2020-10-26  2:50     ` [PATCH v6 2/2] PM / devfreq: Add governor attribute flag for specifc sysfs nodes Chanwoo Choi
2020-10-26  3:20   ` Chanwoo Choi [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=56da5f5c-faab-3d81-c438-e17301a41bb6@samsung.com \
    --to=cw00.choi@samsung.com \
    --cc=abel.vesa@nxp.com \
    --cc=b.zolnierkie@samsung.com \
    --cc=chanwoo@kernel.org \
    --cc=digetx@gmail.com \
    --cc=enric.balletbo@collabora.com \
    --cc=hl@rock-chips.com \
    --cc=jonathanh@nvidia.com \
    --cc=k.konieczny@samsung.com \
    --cc=kyungmin.park@samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=lukasz.luba@arm.com \
    --cc=myungjoo.ham@samsung.com \
    --cc=thierry.reding@gmail.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®