From c21f5bca9ae81804130e30ea3e6f7a18d51203dc Mon Sep 17 00:00:00 2001 From: Alex Waterman Date: Wed, 10 May 2017 02:34:54 +0100 Subject: 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 Reviewed-on: http://git-master/r/1480227 Reviewed-by: mobile promotions Tested-by: mobile promotions --- drivers/gpu/nvgpu/gm20b/acr_gm20b.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'drivers/gpu/nvgpu/gm20b/acr_gm20b.c') diff --git a/drivers/gpu/nvgpu/gm20b/acr_gm20b.c b/drivers/gpu/nvgpu/gm20b/acr_gm20b.c index 666f629e..580ba5e5 100644 --- a/drivers/gpu/nvgpu/gm20b/acr_gm20b.c +++ b/drivers/gpu/nvgpu/gm20b/acr_gm20b.c @@ -388,7 +388,7 @@ int prepare_ucode_blob(struct gk20a *g) u32 wprsize; int i; struct mm_gk20a *mm = &g->mm; - struct vm_gk20a *vm = &mm->pmu.vm; + struct vm_gk20a *vm = mm->pmu.vm; struct wpr_carveout_info wpr_inf; struct page **pages; @@ -1067,7 +1067,7 @@ static int lsf_gen_wpr_requirements(struct gk20a *g, struct ls_flcn_mgr *plsfm) static int gm20b_bootstrap_hs_flcn(struct gk20a *g) { struct mm_gk20a *mm = &g->mm; - struct vm_gk20a *vm = &mm->pmu.vm; + struct vm_gk20a *vm = mm->pmu.vm; int err = 0; u64 *acr_dmem; u32 img_size_in_bytes = 0; @@ -1385,7 +1385,7 @@ static int gm20b_init_pmu_setup_hw1(struct gk20a *g, int pmu_exec_gen_bl(struct gk20a *g, void *desc, u8 b_wait_for_halt) { struct mm_gk20a *mm = &g->mm; - struct vm_gk20a *vm = &mm->pmu.vm; + struct vm_gk20a *vm = mm->pmu.vm; int err = 0; u32 bl_sz; struct acr_desc *acr = &g->acr; -- cgit v1.2.2