summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorSudeep Holla <sudeep.holla@arm.com>2017-04-27 17:08:51 +0300
committerSudeep Holla <sudeep.holla@arm.com>2017-06-05 13:14:35 +0300
commit45ca7df7c345465dbd2426a33012c9c33d27de62 (patch)
tree0cc3f9ef1cbf4f5a942d03198f6044dc36beebc0 /include
parent2ea659a9ef488125eb46da6eb571de5eae5c43f6 (diff)
downloadlinux-45ca7df7c345465dbd2426a33012c9c33d27de62.tar.xz
firmware: arm_scpi: add support to populate OPPs and get transition latency
Currently only CPU devices use the transition latency and the OPPs populated in the SCPI driver. scpi-cpufreq has logic to handle these. However, even GPU and other users of SCPI DVFS will need the same logic. In order to avoid duplication, this patch adds support to get DVFS transition latency and add all the OPPs to the device using OPP library helper functions. The helper functions added here can be used for any device whose DVFS are managed by SCPI. Also, we also have incorrect dependency on the cluster identifier for the CPUs. It's fundamentally wrong as the domain id need not match the cluster id. This patch gets rid of that dependency by making use of the clock bindings which are already in place. Signed-off-by: Sudeep Holla <sudeep.holla@arm.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/scpi_protocol.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/scpi_protocol.h b/include/linux/scpi_protocol.h
index dc5f989be226..327d65663dbf 100644
--- a/include/linux/scpi_protocol.h
+++ b/include/linux/scpi_protocol.h
@@ -67,6 +67,9 @@ struct scpi_ops {
int (*dvfs_get_idx)(u8);
int (*dvfs_set_idx)(u8, u8);
struct scpi_dvfs_info *(*dvfs_get_info)(u8);
+ int (*device_domain_id)(struct device *);
+ int (*get_transition_latency)(struct device *);
+ int (*add_opps_to_device)(struct device *);
int (*sensor_get_capability)(u16 *sensors);
int (*sensor_get_info)(u16 sensor_id, struct scpi_sensor_info *);
int (*sensor_get_value)(u16, u64 *);