diff options
author | Seema Khowala <seemaj@nvidia.com> | 2017-12-01 15:15:36 -0500 |
---|---|---|
committer | Alexander Van Brunt <avanbrunt@nvidia.com> | 2017-12-06 16:04:44 -0500 |
commit | 7d65ec92d8eea59ccb02baf63848e21a76b6f304 (patch) | |
tree | b79d289a6ff1e0ffdbea1e0035b0b11bd9f964c5 /drivers/gpu/nvgpu/gv11b/acr_gv11b.c | |
parent | 5791b47d81b9135e7944aedd681424b0e1ab6717 (diff) |
gpu: nvgpu: gv11b: init alloc_blob_space fn ptr
Use NVGPU_DMA_FORCE_CONTIGUOUS for non-wpr blob alloc.
CPU writes some data to non WPR blob (sysmem). ACR binary executing
from PMU, first copies that data to DMEM and then copies that data into WPR.
Without NVGPU_DMA_FORCE_CONTIGUOUS, secure boot fails due to ACR writing
wrong bootloader data to PMU DMEM.
Bug 200355756
Change-Id: I18982caff62b2e7cbe64ea98c1bb935496cfe91c
Signed-off-by: Seema Khowala <seemaj@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1610491
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gv11b/acr_gv11b.c')
-rw-r--r-- | drivers/gpu/nvgpu/gv11b/acr_gv11b.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/gpu/nvgpu/gv11b/acr_gv11b.c b/drivers/gpu/nvgpu/gv11b/acr_gv11b.c index 41695fa6..799b2db4 100644 --- a/drivers/gpu/nvgpu/gv11b/acr_gv11b.c +++ b/drivers/gpu/nvgpu/gv11b/acr_gv11b.c | |||
@@ -54,6 +54,18 @@ static void flcn64_set_dma(struct falc_u64 *dma_addr, u64 value) | |||
54 | 54 | ||
55 | /*Forwards*/ | 55 | /*Forwards*/ |
56 | 56 | ||
57 | int gv11b_alloc_blob_space(struct gk20a *g, | ||
58 | size_t size, struct nvgpu_mem *mem) | ||
59 | { | ||
60 | int err; | ||
61 | |||
62 | gv11b_dbg_pmu("alloc blob space: NVGPU_DMA_FORCE_CONTIGUOUS"); | ||
63 | err = nvgpu_dma_alloc_flags_sys(g, NVGPU_DMA_FORCE_CONTIGUOUS, | ||
64 | size, mem); | ||
65 | |||
66 | return err; | ||
67 | } | ||
68 | |||
57 | /*Loads ACR bin to FB mem and bootstraps PMU with bootloader code | 69 | /*Loads ACR bin to FB mem and bootstraps PMU with bootloader code |
58 | * start and end are addresses of ucode blob in non-WPR region*/ | 70 | * start and end are addresses of ucode blob in non-WPR region*/ |
59 | int gv11b_bootstrap_hs_flcn(struct gk20a *g) | 71 | int gv11b_bootstrap_hs_flcn(struct gk20a *g) |