.. | .. |
---|
| 1 | +/* SPDX-License-Identifier: GPL-2.0-only */ |
---|
1 | 2 | /* |
---|
2 | 3 | * CPPC (Collaborative Processor Performance Control) methods used |
---|
3 | 4 | * by CPUfreq drivers. |
---|
4 | 5 | * |
---|
5 | 6 | * (C) Copyright 2014, 2015 Linaro Ltd. |
---|
6 | 7 | * Author: Ashwin Chaugule <ashwin.chaugule@linaro.org> |
---|
7 | | - * |
---|
8 | | - * This program is free software; you can redistribute it and/or |
---|
9 | | - * modify it under the terms of the GNU General Public License |
---|
10 | | - * as published by the Free Software Foundation; version 2 |
---|
11 | | - * of the License. |
---|
12 | 8 | */ |
---|
13 | 9 | |
---|
14 | 10 | #ifndef _CPPC_ACPI_H |
---|
.. | .. |
---|
20 | 16 | #include <acpi/pcc.h> |
---|
21 | 17 | #include <acpi/processor.h> |
---|
22 | 18 | |
---|
23 | | -/* Support CPPCv2 and CPPCv3 */ |
---|
| 19 | +/* CPPCv2 and CPPCv3 support */ |
---|
24 | 20 | #define CPPC_V2_REV 2 |
---|
25 | 21 | #define CPPC_V3_REV 3 |
---|
26 | 22 | #define CPPC_V2_NUM_ENT 21 |
---|
.. | .. |
---|
104 | 100 | * today. |
---|
105 | 101 | */ |
---|
106 | 102 | struct cppc_perf_caps { |
---|
| 103 | + u32 guaranteed_perf; |
---|
107 | 104 | u32 highest_perf; |
---|
108 | 105 | u32 nominal_perf; |
---|
109 | 106 | u32 lowest_perf; |
---|
.. | .. |
---|
136 | 133 | cpumask_var_t shared_cpu_map; |
---|
137 | 134 | }; |
---|
138 | 135 | |
---|
| 136 | +extern int cppc_get_desired_perf(int cpunum, u64 *desired_perf); |
---|
139 | 137 | extern int cppc_get_perf_ctrs(int cpu, struct cppc_perf_fb_ctrs *perf_fb_ctrs); |
---|
140 | 138 | extern int cppc_set_perf(int cpu, struct cppc_perf_ctrls *perf_ctrls); |
---|
141 | 139 | extern int cppc_get_perf_caps(int cpu, struct cppc_perf_caps *caps); |
---|
142 | 140 | extern int acpi_get_psd_map(struct cppc_cpudata **); |
---|
143 | 141 | extern unsigned int cppc_get_transition_latency(int cpu); |
---|
| 142 | +extern bool cpc_ffh_supported(void); |
---|
| 143 | +extern int cpc_read_ffh(int cpunum, struct cpc_reg *reg, u64 *val); |
---|
| 144 | +extern int cpc_write_ffh(int cpunum, struct cpc_reg *reg, u64 val); |
---|
144 | 145 | |
---|
145 | 146 | #endif /* _CPPC_ACPI_H*/ |
---|