mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-25 02:52:51 +03:00
gpu: nvgpu: Set pd_cache to NULL after it's freed
Clear the pointer to the non-existent pd_cache after the pd_cache is freed. This is good practice and makes it easier to verify that this function has accomplished its intended purpose in the unit tests. JIRA NVGPU-1323 Change-Id: I1e1c20344a385bc96b293f2007485e7f4d99f947 Signed-off-by: Alex Waterman <alexw@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1941535 Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: svc-misra-checker <svc-misra-checker@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Scott Long <scottl@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
3a87a0c998
commit
40b50c059a
@@ -215,6 +215,7 @@ void nvgpu_pd_cache_fini(struct gk20a *g)
|
||||
}
|
||||
|
||||
nvgpu_kfree(g, g->mm.pd_cache);
|
||||
g->mm.pd_cache = NULL;
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user