diff options
author | Viresh Kumar <viresh.kumar@linaro.org> | 2022-06-03 15:01:30 +0530 |
---|---|---|
committer | Viresh Kumar <viresh.kumar@linaro.org> | 2022-07-08 11:27:51 +0530 |
commit | 1efae8d2e7775b04656eb18d0a044fbd412dab3c (patch) | |
tree | 3ca3acb0a5932abbd62ac50ff72f6a97f059d0f8 /drivers/opp/opp.h | |
parent | 8bdac14b0cd56d9578d3112375ed8b23884c1a69 (diff) | |
download | linux-stable-1efae8d2e7775b04656eb18d0a044fbd412dab3c.tar.gz |
OPP: Make dev_pm_opp_set_opp() independent of frequency
dev_pm_opp_set_opp() can be called for any device, it may or may not
have a frequency value associated with it.
If a frequency value isn't available, we pass 0 to _set_opp(). Make it
optional instead by making _set_opp() accept a pointer instead, as the
frequency value is anyway available in the OPP. This makes
dev_pm_opp_set_opp() and _set_opp() completely independent of any
special key value.
Tested-by: Dmitry Osipenko <dmitry.osipenko@collabora.com>
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Diffstat (limited to 'drivers/opp/opp.h')
-rw-r--r-- | drivers/opp/opp.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/opp/opp.h b/drivers/opp/opp.h index e449828ffbf4..e481bdb59499 100644 --- a/drivers/opp/opp.h +++ b/drivers/opp/opp.h @@ -159,7 +159,7 @@ enum opp_table_access { * @clock_latency_ns_max: Max clock latency in nanoseconds. * @parsed_static_opps: Count of devices for which OPPs are initialized from DT. * @shared_opp: OPP is shared between multiple devices. - * @current_rate: Currently configured frequency. + * @rate_clk_single: Currently configured frequency for single clk. * @current_opp: Currently configured OPP for the table. * @suspend_opp: Pointer to OPP to be used during device suspend. * @genpd_virt_dev_lock: Mutex protecting the genpd virtual device pointers. @@ -208,7 +208,7 @@ struct opp_table { unsigned int parsed_static_opps; enum opp_table_access shared_opp; - unsigned long current_rate; + unsigned long rate_clk_single; struct dev_pm_opp *current_opp; struct dev_pm_opp *suspend_opp; |