mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-24 02:01:36 +03:00
camera: oot: unmap buf in non atomic context
Call dma_buf_unmap_attachment from non atomic context. This will resolve the kernel BUG warning that appears when running argus tests, scf function tests and fusa capture tests. Bug 3953333 Change-Id: I9042b375856556fe5829981cb8aefd81e45b749b Signed-off-by: Ankur Pawar <ankurp@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2875756 Reviewed-by: svcacv <svcacv@nvidia.com> Reviewed-by: Frank Chen <frankc@nvidia.com> Reviewed-by: Ajith Kumar <ajithk@nvidia.com> Reviewed-by: Sudhir Vyas <svyas@nvidia.com> GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
This commit is contained in:
committed by
mobile promotions
parent
b5ec750ebb
commit
6b9c2cd8cc
@@ -352,10 +352,11 @@ void destroy_buffer_table(
|
||||
if (unlikely(tab == NULL))
|
||||
return;
|
||||
|
||||
write_lock(&tab->hlock);
|
||||
|
||||
hash_for_each_safe(tab->hhead, bkt, next, pin, hnode) {
|
||||
write_lock(&tab->hlock);
|
||||
hash_del(&pin->hnode);
|
||||
write_unlock(&tab->hlock);
|
||||
dma_buf_unmap_attachment(
|
||||
pin->atch, pin->sgt, flag_dma_direction(pin->flag));
|
||||
dma_buf_detach(pin->buf, pin->atch);
|
||||
@@ -363,7 +364,6 @@ void destroy_buffer_table(
|
||||
kmem_cache_free(tab->cache, pin);
|
||||
}
|
||||
|
||||
write_unlock(&tab->hlock);
|
||||
|
||||
kmem_cache_destroy(tab->cache);
|
||||
kfree(tab);
|
||||
|
||||
Reference in New Issue
Block a user