[Freedreno] [PATCH RESEND 06/10] drm/msm: Fix deadlock calling msm_gem_new()
Jeykumar Sankaran
jsanka at codeaurora.org
Thu Mar 8 22:21:44 UTC 2018
On 2018-02-21 07:18, Sean Paul wrote:
> msm_gem_new() acquires the struct_mutex, so surrounding this call with
> locks causes deadlocks all day long.
>
> Signed-off-by: Sean Paul <seanpaul at chromium.org>
Reviewed-by: Jeykumar Sankaran <jsanka at codeaurora.org>
> ---
> drivers/gpu/drm/msm/disp/dpu1/dpu_hw_reg_dma_v1.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_reg_dma_v1.c
> b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_reg_dma_v1.c
> index fc2efec6360b..bb4547748ce9 100644
> --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_reg_dma_v1.c
> +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_reg_dma_v1.c
> @@ -601,10 +601,8 @@ static struct dpu_reg_dma_buffer
> *alloc_reg_dma_buf_v1(u32 size)
> if (!dma_buf)
> return ERR_PTR(-ENOMEM);
>
> - mutex_lock(®_dma->drm_dev->struct_mutex);
> dma_buf->buf = msm_gem_new(reg_dma->drm_dev,
> rsize, MSM_BO_UNCACHED);
> - mutex_unlock(®_dma->drm_dev->struct_mutex);
> if (IS_ERR_OR_NULL(dma_buf->buf)) {
> rc = -EINVAL;
> goto fail;
--
Jeykumar S
More information about the Freedreno
mailing list