From a1ea7e012fc862de60ba675bed49fd3757122067 Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Thu, 5 Nov 2015 15:09:17 -0800 Subject: [PATCH] gpu: nvgpu: Do not panic if no page tables Do not panic at channel free time if page table allocation has failed. Bug 200150063 Change-Id: If31a4086cda07964dcce9cebdb11332d2a2d7c2c Signed-off-by: Terje Bergstrom Reviewed-on: http://git-master/r/828690 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Seshendra Gadagottu Reviewed-by: Winnie Hsu --- drivers/gpu/nvgpu/gk20a/mm_gk20a.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/nvgpu/gk20a/mm_gk20a.c b/drivers/gpu/nvgpu/gk20a/mm_gk20a.c index c36908b7dcc..394d98eda4b 100644 --- a/drivers/gpu/nvgpu/gk20a/mm_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/mm_gk20a.c @@ -529,7 +529,8 @@ void free_gmmu_pages(struct vm_gk20a *vm, DEFINE_DMA_ATTRS(attrs); gk20a_dbg_fn(""); - BUG_ON(entry->sgt == NULL); + if (!entry->sgt) + return; if (tegra_platform_is_linsim()) { free_gmmu_phys_pages(vm, entry); -- 2.39.2