diff options
author | Alex Waterman <alexw@nvidia.com> | 2017-05-09 21:34:54 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2017-06-06 20:09:16 -0400 |
commit | c21f5bca9ae81804130e30ea3e6f7a18d51203dc (patch) | |
tree | fb1a2d67532df19d70468610ad2a62c3464876c1 /drivers/gpu/nvgpu/gk20a/gr_gk20a.c | |
parent | c2b63150cd947557b8d17637258b988459b8e0ec (diff) |
gpu: nvgpu: Remove extraneous VM init/deinit APIs
Support only VM pointers and ref-counting for maintaining VMs. This
dramatically reduces the complexity of the APIs, avoids the API
abuse that has existed, and ensures that future VM usage is
consistent with current usage.
Also remove the combined VM free/instance block deletion. Any place
where this was done is now replaced with an explict free of the
instance block and a nvgpu_vm_put().
JIRA NVGPU-12
JIRA NVGPU-30
Change-Id: Ib73e8d574ecc9abf6dad0b40a2c5795d6396cc8c
Signed-off-by: Alex Waterman <alexw@nvidia.com>
Reviewed-on: http://git-master/r/1480227
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/gr_gk20a.c')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gr_gk20a.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c index f8e05818..b2ae77c3 100644 --- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c | |||
@@ -2191,7 +2191,7 @@ static void gr_gk20a_start_falcon_ucode(struct gk20a *g) | |||
2191 | static int gr_gk20a_init_ctxsw_ucode_vaspace(struct gk20a *g) | 2191 | static int gr_gk20a_init_ctxsw_ucode_vaspace(struct gk20a *g) |
2192 | { | 2192 | { |
2193 | struct mm_gk20a *mm = &g->mm; | 2193 | struct mm_gk20a *mm = &g->mm; |
2194 | struct vm_gk20a *vm = &mm->pmu.vm; | 2194 | struct vm_gk20a *vm = mm->pmu.vm; |
2195 | struct gk20a_ctxsw_ucode_info *ucode_info = &g->ctxsw_ucode_info; | 2195 | struct gk20a_ctxsw_ucode_info *ucode_info = &g->ctxsw_ucode_info; |
2196 | int err; | 2196 | int err; |
2197 | 2197 | ||
@@ -2265,7 +2265,7 @@ static int gr_gk20a_copy_ctxsw_ucode_segments( | |||
2265 | int gr_gk20a_init_ctxsw_ucode(struct gk20a *g) | 2265 | int gr_gk20a_init_ctxsw_ucode(struct gk20a *g) |
2266 | { | 2266 | { |
2267 | struct mm_gk20a *mm = &g->mm; | 2267 | struct mm_gk20a *mm = &g->mm; |
2268 | struct vm_gk20a *vm = &mm->pmu.vm; | 2268 | struct vm_gk20a *vm = mm->pmu.vm; |
2269 | struct gk20a_ctxsw_bootloader_desc *fecs_boot_desc; | 2269 | struct gk20a_ctxsw_bootloader_desc *fecs_boot_desc; |
2270 | struct gk20a_ctxsw_bootloader_desc *gpccs_boot_desc; | 2270 | struct gk20a_ctxsw_bootloader_desc *gpccs_boot_desc; |
2271 | struct nvgpu_firmware *fecs_fw; | 2271 | struct nvgpu_firmware *fecs_fw; |
@@ -5195,7 +5195,7 @@ static int gk20a_init_gr_bind_fecs_elpg(struct gk20a *g) | |||
5195 | { | 5195 | { |
5196 | struct nvgpu_pmu *pmu = &g->pmu; | 5196 | struct nvgpu_pmu *pmu = &g->pmu; |
5197 | struct mm_gk20a *mm = &g->mm; | 5197 | struct mm_gk20a *mm = &g->mm; |
5198 | struct vm_gk20a *vm = &mm->pmu.vm; | 5198 | struct vm_gk20a *vm = mm->pmu.vm; |
5199 | int err = 0; | 5199 | int err = 0; |
5200 | 5200 | ||
5201 | u32 size; | 5201 | u32 size; |