diff options
author | Supriya <ssharatkumar@nvidia.com> | 2015-12-10 02:26:59 -0500 |
---|---|---|
committer | Terje Bergstrom <tbergstrom@nvidia.com> | 2016-02-26 15:29:55 -0500 |
commit | 640cb6642fdb0ad5a4039aacf6c46e1ac30537a3 (patch) | |
tree | 338997402fccd97f28b7b653d1f1b64ca15678db /drivers/gpu/nvgpu/gm20b | |
parent | 6d585840ad5887407512dd292698100df50e5eed (diff) |
gpu: nvgpu: LRF, TEX, LTC, DRAM override
- Adding support for FECS mem overrides
Bug 1699676
Change-Id: I6c9ddcd98d57b29059513ee508c6f92b194c4fc7
Signed-off-by: Supriya <ssharatkumar@nvidia.com>
Reviewed-on: http://git-master/r/921253
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gm20b')
-rw-r--r-- | drivers/gpu/nvgpu/gm20b/acr_gm20b.c | 6 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/gm20b/acr_gm20b.h | 7 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/gm20b/gr_gm20b.c | 1 | ||||
-rw-r--r-- | drivers/gpu/nvgpu/gm20b/pmu_gm20b.c | 3 |
4 files changed, 14 insertions, 3 deletions
diff --git a/drivers/gpu/nvgpu/gm20b/acr_gm20b.c b/drivers/gpu/nvgpu/gm20b/acr_gm20b.c index ee64b90f..9f137246 100644 --- a/drivers/gpu/nvgpu/gm20b/acr_gm20b.c +++ b/drivers/gpu/nvgpu/gm20b/acr_gm20b.c | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * Copyright (c) 2015, NVIDIA CORPORATION. All rights reserved. | 2 | * Copyright (c) 2015-2016, 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, |
@@ -1300,6 +1300,8 @@ static int gm20b_init_pmu_setup_hw1(struct gk20a *g, | |||
1300 | pmu_enable_irq(pmu, false); | 1300 | pmu_enable_irq(pmu, false); |
1301 | pmu->isr_enabled = false; | 1301 | pmu->isr_enabled = false; |
1302 | mutex_unlock(&pmu->isr_mutex); | 1302 | mutex_unlock(&pmu->isr_mutex); |
1303 | /*Clearing mailbox register used to reflect capabilities*/ | ||
1304 | gk20a_writel(g, pwr_falcon_mailbox1_r(), 0); | ||
1303 | err = bl_bootstrap(pmu, desc, bl_sz); | 1305 | err = bl_bootstrap(pmu, desc, bl_sz); |
1304 | if (err) | 1306 | if (err) |
1305 | return err; | 1307 | return err; |
@@ -1436,6 +1438,8 @@ int pmu_wait_for_halt(struct gk20a *g, unsigned int timeout) | |||
1436 | if (completion) | 1438 | if (completion) |
1437 | gk20a_err(dev_from_gk20a(g), "ACR boot timed out"); | 1439 | gk20a_err(dev_from_gk20a(g), "ACR boot timed out"); |
1438 | else { | 1440 | else { |
1441 | g->acr.capabilities = gk20a_readl(g, pwr_falcon_mailbox1_r()); | ||
1442 | gm20b_dbg_pmu("ACR capabilities %x\n", g->acr.capabilities); | ||
1439 | data = gk20a_readl(g, pwr_falcon_mailbox0_r()); | 1443 | data = gk20a_readl(g, pwr_falcon_mailbox0_r()); |
1440 | if (data) { | 1444 | if (data) { |
1441 | gk20a_err(dev_from_gk20a(g), | 1445 | gk20a_err(dev_from_gk20a(g), |
diff --git a/drivers/gpu/nvgpu/gm20b/acr_gm20b.h b/drivers/gpu/nvgpu/gm20b/acr_gm20b.h index 58800c09..414e22b6 100644 --- a/drivers/gpu/nvgpu/gm20b/acr_gm20b.h +++ b/drivers/gpu/nvgpu/gm20b/acr_gm20b.h | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * GM20B ACR | 2 | * GM20B ACR |
3 | * | 3 | * |
4 | * Copyright (c) 2015, NVIDIA CORPORATION. All rights reserved. | 4 | * Copyright (c) 2015-2016, NVIDIA CORPORATION. All rights reserved. |
5 | * | 5 | * |
6 | * This program is free software; you can redistribute it and/or modify it | 6 | * This program is free software; you can redistribute it and/or modify it |
7 | * under the terms and conditions of the GNU General Public License, | 7 | * under the terms and conditions of the GNU General Public License, |
@@ -124,6 +124,10 @@ | |||
124 | #define FLCN_NL_UCODE_HDR_OS_OVL_SIZE_IND(N) \ | 124 | #define FLCN_NL_UCODE_HDR_OS_OVL_SIZE_IND(N) \ |
125 | (FLCN_NL_UCODE_HDR_APP_DATA_END_IND(N) + 2) | 125 | (FLCN_NL_UCODE_HDR_APP_DATA_END_IND(N) + 2) |
126 | 126 | ||
127 | enum acr_capabilities { | ||
128 | ACR_LRF_TEX_LTC_DRAM_PRIV_MASK_ENABLE_LS_OVERRIDE = (0x00000001), | ||
129 | }; | ||
130 | |||
127 | /*Externs*/ | 131 | /*Externs*/ |
128 | 132 | ||
129 | /*Structs*/ | 133 | /*Structs*/ |
@@ -397,6 +401,7 @@ struct acr_gm20b { | |||
397 | struct flcn_bl_dmem_desc bl_dmem_desc; | 401 | struct flcn_bl_dmem_desc bl_dmem_desc; |
398 | const struct firmware *pmu_fw; | 402 | const struct firmware *pmu_fw; |
399 | const struct firmware *pmu_desc; | 403 | const struct firmware *pmu_desc; |
404 | u32 capabilities; | ||
400 | }; | 405 | }; |
401 | 406 | ||
402 | void gm20b_init_secure_pmu(struct gpu_ops *gops); | 407 | void gm20b_init_secure_pmu(struct gpu_ops *gops); |
diff --git a/drivers/gpu/nvgpu/gm20b/gr_gm20b.c b/drivers/gpu/nvgpu/gm20b/gr_gm20b.c index 2a891647..67654cba 100644 --- a/drivers/gpu/nvgpu/gm20b/gr_gm20b.c +++ b/drivers/gpu/nvgpu/gm20b/gr_gm20b.c | |||
@@ -1232,4 +1232,5 @@ void gm20b_init_gr(struct gpu_ops *gops) | |||
1232 | gops->gr.mask_hww_warp_esr = gk20a_mask_hww_warp_esr; | 1232 | gops->gr.mask_hww_warp_esr = gk20a_mask_hww_warp_esr; |
1233 | gops->gr.handle_sm_exception = gr_gk20a_handle_sm_exception; | 1233 | gops->gr.handle_sm_exception = gr_gk20a_handle_sm_exception; |
1234 | gops->gr.handle_tex_exception = gr_gk20a_handle_tex_exception; | 1234 | gops->gr.handle_tex_exception = gr_gk20a_handle_tex_exception; |
1235 | gops->gr.get_lrf_tex_ltc_dram_override = NULL; | ||
1235 | } | 1236 | } |
diff --git a/drivers/gpu/nvgpu/gm20b/pmu_gm20b.c b/drivers/gpu/nvgpu/gm20b/pmu_gm20b.c index 4123e32a..ce3da2b6 100644 --- a/drivers/gpu/nvgpu/gm20b/pmu_gm20b.c +++ b/drivers/gpu/nvgpu/gm20b/pmu_gm20b.c | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * GM20B PMU | 2 | * GM20B PMU |
3 | * | 3 | * |
4 | * Copyright (c) 2015, NVIDIA CORPORATION. All rights reserved. | 4 | * Copyright (c) 2015-2016, NVIDIA CORPORATION. All rights reserved. |
5 | * | 5 | * |
6 | * This program is free software; you can redistribute it and/or modify it | 6 | * This program is free software; you can redistribute it and/or modify it |
7 | * under the terms and conditions of the GNU General Public License, | 7 | * under the terms and conditions of the GNU General Public License, |
@@ -308,4 +308,5 @@ void gm20b_init_pmu_ops(struct gpu_ops *gops) | |||
308 | gops->pmu.write_dmatrfbase = gm20b_write_dmatrfbase; | 308 | gops->pmu.write_dmatrfbase = gm20b_write_dmatrfbase; |
309 | gops->pmu.pmu_elpg_statistics = gk20a_pmu_elpg_statistics; | 309 | gops->pmu.pmu_elpg_statistics = gk20a_pmu_elpg_statistics; |
310 | gops->pmu.pmu_pg_grinit_param = NULL; | 310 | gops->pmu.pmu_pg_grinit_param = NULL; |
311 | gops->pmu.send_lrf_tex_ltc_dram_overide_en_dis_cmd = NULL; | ||
311 | } | 312 | } |