diff options
author | Terje Bergstrom <tbergstrom@nvidia.com> | 2017-07-27 15:58:03 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2017-08-04 12:23:56 -0400 |
commit | b8efd9d04537d6129e2ce8b067417e46b0e7436f (patch) | |
tree | 1a40179a893e10c0fdcdd56797599bcdf6b55206 /drivers/gpu/nvgpu/gp106/hal_gp106.c | |
parent | c16797e35c2926bf34a61d5d8f37d5675ec23b1b (diff) |
gpu: nvgpu: Make LTC disabling common code
Refactor the sync_debugfs LTC HAL op so that the logic to enable
or disable LTC goes to common code nvgpu_ltc_sync_enabled() and
the LTC HAL set_enabled only performs the hardware register access.
Create a new common function nvgpu_init_ltc_support() to initialize
the LTC software variable, and move hardware initialization of LTC to
be called from it.
JIRA NVGPU-62
Change-Id: Ib1cf4f5b83ca3dac08407464ed56a732e0a33923
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1528262
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gp106/hal_gp106.c')
-rw-r--r-- | drivers/gpu/nvgpu/gp106/hal_gp106.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/gpu/nvgpu/gp106/hal_gp106.c b/drivers/gpu/nvgpu/gp106/hal_gp106.c index 38778da7..4a891a82 100644 --- a/drivers/gpu/nvgpu/gp106/hal_gp106.c +++ b/drivers/gpu/nvgpu/gp106/hal_gp106.c | |||
@@ -204,9 +204,7 @@ static const struct gpu_ops gp106_ops = { | |||
204 | .isr = gp10b_ltc_isr, | 204 | .isr = gp10b_ltc_isr, |
205 | .cbc_fix_config = NULL, | 205 | .cbc_fix_config = NULL, |
206 | .flush = gm20b_flush_ltc, | 206 | .flush = gm20b_flush_ltc, |
207 | #ifdef CONFIG_DEBUG_FS | 207 | .set_enabled = gp10b_ltc_set_enabled, |
208 | .sync_debugfs = gp10b_ltc_sync_debugfs, | ||
209 | #endif | ||
210 | }, | 208 | }, |
211 | .ce2 = { | 209 | .ce2 = { |
212 | .isr_stall = gp10b_ce_isr, | 210 | .isr_stall = gp10b_ce_isr, |