summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/exynos/exynos_drm_gem.c
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2016-03-30 11:40:46 +0200
committerDaniel Vetter <daniel.vetter@ffwll.ch>2016-04-20 12:57:54 +0200
commit8e97d9ef362e65f2533366527cdafa1842dab201 (patch)
treecbcc24e8193b0c71a5af524c1c5d1fbe1b69b5a1 /drivers/gpu/drm/exynos/exynos_drm_gem.c
parent91263622f1184b7650cac10f70b08aa7f142f900 (diff)
downloadlinux-8e97d9ef362e65f2533366527cdafa1842dab201.tar.bz2
drm/exynos: drop struct_mutex from exynos_gem_map_sgt_with_dma
The sg table isn't refcounted, there's no corresponding locking for unmapping and drm_map_sg is ok with being called concurrently. So drop the locking since it doesn't protect anything. Cc: Inki Dae <inki.dae@samsung.com> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1459330852-27668-8-git-send-email-daniel.vetter@ffwll.ch
Diffstat (limited to 'drivers/gpu/drm/exynos/exynos_drm_gem.c')
-rw-r--r--drivers/gpu/drm/exynos/exynos_drm_gem.c4
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu/drm/exynos/exynos_drm_gem.c
index 3b7209335df0..60b9975bb0b1 100644
--- a/drivers/gpu/drm/exynos/exynos_drm_gem.c
+++ b/drivers/gpu/drm/exynos/exynos_drm_gem.c
@@ -388,16 +388,12 @@ int exynos_gem_map_sgt_with_dma(struct drm_device *drm_dev,
{
int nents;
- mutex_lock(&drm_dev->struct_mutex);
-
nents = dma_map_sg(to_dma_dev(drm_dev), sgt->sgl, sgt->nents, dir);
if (!nents) {
DRM_ERROR("failed to map sgl with dma.\n");
- mutex_unlock(&drm_dev->struct_mutex);
return nents;
}
- mutex_unlock(&drm_dev->struct_mutex);
return 0;
}