diff options
author | Georgi Djakov <georgi.djakov@linaro.org> | 2020-05-12 15:53:21 +0300 |
---|---|---|
committer | Viresh Kumar <viresh.kumar@linaro.org> | 2020-05-29 07:45:08 +0300 |
commit | 6d3f922c46f2e91f63c92f8dd28381f097082912 (patch) | |
tree | 96d8512a0b37295ca4aa3d688d907b8643c74916 /drivers/opp/opp.h | |
parent | 90562c8182702058f9c8e562e067ec43cd3953dd (diff) | |
download | linux-6d3f922c46f2e91f63c92f8dd28381f097082912.tar.xz |
opp: Add support for parsing interconnect bandwidth
The OPP bindings now support bandwidth values, so add support to parse it
from device tree and store it into the new dev_pm_opp_icc_bw struct, which
is part of the dev_pm_opp.
Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org>
Reviewed-by: Matthias Kaehlcke <mka@chromium.org>
[ Viresh: Create _read_bw() and use it, renamed _of_find_icc_paths() to
dev_pm_opp_of_find_icc_paths(), exported it and made opp_table
argument optional. Also drop the depends on from Kconfig. ]
Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Diffstat (limited to 'drivers/opp/opp.h')
-rw-r--r-- | drivers/opp/opp.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/opp/opp.h b/drivers/opp/opp.h index bcadb1e328a4..2b81ffef1ba4 100644 --- a/drivers/opp/opp.h +++ b/drivers/opp/opp.h @@ -12,6 +12,7 @@ #define __DRIVER_OPP_H__ #include <linux/device.h> +#include <linux/interconnect.h> #include <linux/kernel.h> #include <linux/kref.h> #include <linux/list.h> @@ -59,6 +60,7 @@ extern struct list_head opp_tables; * @rate: Frequency in hertz * @level: Performance level * @supplies: Power supplies voltage/current values + * @bandwidth: Interconnect bandwidth values * @clock_latency_ns: Latency (in nanoseconds) of switching to this OPP's * frequency from any other OPP's frequency. * @required_opps: List of OPPs that are required by this OPP. @@ -81,6 +83,7 @@ struct dev_pm_opp { unsigned int level; struct dev_pm_opp_supply *supplies; + struct dev_pm_opp_icc_bw *bandwidth; unsigned long clock_latency_ns; @@ -146,6 +149,8 @@ enum opp_table_access { * @regulator_count: Number of power supply regulators. Its value can be -1 * (uninitialized), 0 (no opp-microvolt property) or > 0 (has opp-microvolt * property). + * @paths: Interconnect path handles + * @path_count: Number of interconnect paths * @genpd_performance_state: Device's power domain support performance state. * @is_genpd: Marks if the OPP table belongs to a genpd. * @set_opp: Platform specific set_opp callback @@ -189,6 +194,8 @@ struct opp_table { struct clk *clk; struct regulator **regulators; int regulator_count; + struct icc_path **paths; + unsigned int path_count; bool genpd_performance_state; bool is_genpd; |