summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gk20a/hw_therm_gk20a.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/hw_therm_gk20a.h')
-rw-r--r--drivers/gpu/nvgpu/gk20a/hw_therm_gk20a.h82
1 files changed, 21 insertions, 61 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/hw_therm_gk20a.h b/drivers/gpu/nvgpu/gk20a/hw_therm_gk20a.h
index 5d6397b4..42a31c5d 100644
--- a/drivers/gpu/nvgpu/gk20a/hw_therm_gk20a.h
+++ b/drivers/gpu/nvgpu/gk20a/hw_therm_gk20a.h
@@ -1,5 +1,5 @@
1/* 1/*
2 * Copyright (c) 2012-2013, NVIDIA CORPORATION. All rights reserved. 2 * Copyright (c) 2012-2014, NVIDIA CORPORATION. All rights reserved.
3 * 3 *
4 * This program is free software; you can redistribute it and/or modify it 4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms and conditions of the GNU General Public License, 5 * under the terms and conditions of the GNU General Public License,
@@ -66,70 +66,10 @@ static inline u32 therm_evt_ext_therm_2_r(void)
66{ 66{
67 return 0x00020708; 67 return 0x00020708;
68} 68}
69static inline u32 therm_evt_ba_w0_t1h_r(void)
70{
71 return 0x00020750;
72}
73static inline u32 therm_weight_1_r(void) 69static inline u32 therm_weight_1_r(void)
74{ 70{
75 return 0x00020024; 71 return 0x00020024;
76} 72}
77static inline u32 therm_peakpower_config1_r(u32 i)
78{
79 return 0x00020154 + i*4;
80}
81static inline u32 therm_peakpower_config1_window_period_2m_v(void)
82{
83 return 0x0000000f;
84}
85static inline u32 therm_peakpower_config1_window_period_2m_f(void)
86{
87 return 0xf;
88}
89static inline u32 therm_peakpower_config1_ba_sum_shift_s(void)
90{
91 return 6;
92}
93static inline u32 therm_peakpower_config1_ba_sum_shift_f(u32 v)
94{
95 return (v & 0x3f) << 8;
96}
97static inline u32 therm_peakpower_config1_ba_sum_shift_m(void)
98{
99 return 0x3f << 8;
100}
101static inline u32 therm_peakpower_config1_ba_sum_shift_v(u32 r)
102{
103 return (r >> 8) & 0x3f;
104}
105static inline u32 therm_peakpower_config1_ba_sum_shift_20_f(void)
106{
107 return 0x1400;
108}
109static inline u32 therm_peakpower_config1_window_en_enabled_f(void)
110{
111 return 0x80000000;
112}
113static inline u32 therm_peakpower_config2_r(u32 i)
114{
115 return 0x00020170 + i*4;
116}
117static inline u32 therm_peakpower_config4_r(u32 i)
118{
119 return 0x000201c0 + i*4;
120}
121static inline u32 therm_peakpower_config6_r(u32 i)
122{
123 return 0x00020270 + i*4;
124}
125static inline u32 therm_peakpower_config8_r(u32 i)
126{
127 return 0x000202e8 + i*4;
128}
129static inline u32 therm_peakpower_config9_r(u32 i)
130{
131 return 0x000202f4 + i*4;
132}
133static inline u32 therm_config1_r(void) 73static inline u32 therm_config1_r(void)
134{ 74{
135 return 0x00020050; 75 return 0x00020050;
@@ -222,4 +162,24 @@ static inline u32 therm_hubmmu_idle_filter_value_m(void)
222{ 162{
223 return 0xffffffff << 0; 163 return 0xffffffff << 0;
224} 164}
165static inline u32 therm_clk_slowdown_r(u32 i)
166{
167 return 0x00020160 + i*4;
168}
169static inline u32 therm_clk_slowdown_idle_factor_f(u32 v)
170{
171 return (v & 0x3f) << 16;
172}
173static inline u32 therm_clk_slowdown_idle_factor_m(void)
174{
175 return 0x3f << 16;
176}
177static inline u32 therm_clk_slowdown_idle_factor_v(u32 r)
178{
179 return (r >> 16) & 0x3f;
180}
181static inline u32 therm_clk_slowdown_idle_factor_disabled_f(void)
182{
183 return 0x0;
184}
225#endif 185#endif