summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/pstate/pstate.h
diff options
context:
space:
mode:
authorThomas Fleury <tfleury@nvidia.com>2016-09-08 20:35:13 -0400
committerDeepak Nibade <dnibade@nvidia.com>2016-12-27 04:56:50 -0500
commitdb529935a5f50e9e683d44d2eb01d0d76a915792 (patch)
tree6d1b3f63aaa5e5abd937cf0c3aec733b9e2e0d08 /drivers/gpu/nvgpu/pstate/pstate.h
parent776ab920a7a4d31c6180e7dcb9f3fcea611e92bd (diff)
gpu: nvgpu: parse performance table
Parse VBIOS performance table to retrieve clock ranges. Jira DNVGPU-125 Change-Id: Ia8e4ede158de5c5374205a510099d00b497fe1a6 Signed-off-by: Thomas Fleury <tfleury@nvidia.com> Reviewed-on: http://git-master/r/1218935 (cherry picked from commit b5b7c789e98a20eb4cc5c30f0e2eb45d4a882cc4) Reviewed-on: http://git-master/r/1232593 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/pstate/pstate.h')
-rw-r--r--drivers/gpu/nvgpu/pstate/pstate.h32
1 files changed, 32 insertions, 0 deletions
diff --git a/drivers/gpu/nvgpu/pstate/pstate.h b/drivers/gpu/nvgpu/pstate/pstate.h
index fb49adf3..11fa4c77 100644
--- a/drivers/gpu/nvgpu/pstate/pstate.h
+++ b/drivers/gpu/nvgpu/pstate/pstate.h
@@ -12,8 +12,40 @@
12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
13 * more details. 13 * more details.
14 */ 14 */
15#ifndef __PSTATE_H__
16#define __PSTATE_H__
15 17
16#include "gk20a/gk20a.h" 18#include "gk20a/gk20a.h"
19#include "clk/clk.h"
20
21#define CTRL_PERF_PSTATE_TYPE_3X 0x3
22
23#define CLK_SET_INFO_MAX_SIZE (32)
24
25struct clk_set_info {
26 enum nv_pmu_clk_clkwhich clkwhich;
27 u32 nominal_mhz;
28 u32 min_mhz;
29 u32 max_mhz;
30};
31
32struct clk_set_info_list {
33 u32 clksetinfolistsize;
34 struct clk_set_info clksetinfo[CLK_SET_INFO_MAX_SIZE];
35};
36
37struct pstate {
38 struct boardobj super;
39 u32 num;
40 struct clk_set_info_list clklist;
41};
42
43struct pstates {
44 struct boardobjgrp_e32 super;
45 u32 num_levels;
46};
17 47
18int gk20a_init_pstate_support(struct gk20a *g); 48int gk20a_init_pstate_support(struct gk20a *g);
19int gk20a_init_pstate_pmu_support(struct gk20a *g); 49int gk20a_init_pstate_pmu_support(struct gk20a *g);
50
51#endif /* __PSTATE_H__ */