mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-24 10:11:26 +03:00
nvmap: Fix coherency issues while creating subhandle
Make sure that all handles, from which sub-buffer handle needs to be created, have same cache coherency, are of type RW, not created from VA. Set the cache coherency of the sub-buffer handle same as the cache coherency of the main handles, so that explicit cache flush is not needed during vma fault. Bug 3494980 Change-Id: I878568e4cdc4529fb3d1a6682e38798769dad9c0 Signed-off-by: Ketan Patil <ketanp@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2819129 Reviewed-by: Puneet Saxena <puneets@nvidia.com> Reviewed-by: Krishna Reddy <vdumpa@nvidia.com> Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com> Reviewed-by: svc_kernel_abi <svc_kernel_abi@nvidia.com> Reviewed-by: Sachin Nikam <snikam@nvidia.com> GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
This commit is contained in:
committed by
Laxman Dewangan
parent
ec9ee786c4
commit
abb244025f
@@ -229,13 +229,6 @@ static int nvmap_vma_fault(struct vm_area_struct *vma, struct vm_fault *vmf)
|
||||
if (PageAnon(page) && (vma->vm_flags & VM_SHARED))
|
||||
return VM_FAULT_SIGSEGV;
|
||||
|
||||
if (priv->handle->is_subhandle) {
|
||||
pr_err("sub_handle page:%p\n", page);
|
||||
kaddr = kmap(page);
|
||||
BUG_ON(!kaddr);
|
||||
inner_cache_maint(NVMAP_CACHE_OP_WB_INV, kaddr, PAGE_SIZE);
|
||||
kunmap(page);
|
||||
}
|
||||
if (!nvmap_handle_track_dirty(priv->handle))
|
||||
goto finish;
|
||||
mutex_lock(&priv->handle->lock);
|
||||
|
||||
Reference in New Issue
Block a user