[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <be83952d-d411-d0c8-e05f-ad50a8ba9c0e@linaro.org>
Date: Fri, 15 Apr 2022 00:22:50 +0300
From: Dmitry Baryshkov <dmitry.baryshkov@...aro.org>
To: Rob Clark <robdclark@...il.com>, dri-devel@...ts.freedesktop.org
Cc: linux-arm-msm@...r.kernel.org, freedreno@...ts.freedesktop.org,
Dmitry Osipenko <dmitry.osipenko@...labora.com>,
Rob Clark <robdclark@...omium.org>,
Sean Paul <sean@...rly.run>,
Abhinav Kumar <quic_abhinavk@...cinc.com>,
David Airlie <airlied@...ux.ie>,
Daniel Vetter <daniel@...ll.ch>,
open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v4 03/10] drm/msm/gem: Convert some missed GEM_WARN_ON()s
On 12/04/2022 00:58, Rob Clark wrote:
> From: Rob Clark <robdclark@...omium.org>
>
> Signed-off-by: Rob Clark <robdclark@...omium.org>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@...aro.org>
> ---
> drivers/gpu/drm/msm/msm_gem_vma.c | 10 +++++-----
> 1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/msm/msm_gem_vma.c b/drivers/gpu/drm/msm/msm_gem_vma.c
> index f914ddbaea89..64906594fc65 100644
> --- a/drivers/gpu/drm/msm/msm_gem_vma.c
> +++ b/drivers/gpu/drm/msm/msm_gem_vma.c
> @@ -44,7 +44,7 @@ void msm_gem_purge_vma(struct msm_gem_address_space *aspace,
> unsigned size = vma->node.size << PAGE_SHIFT;
>
> /* Print a message if we try to purge a vma in use */
> - if (WARN_ON(vma->inuse > 0))
> + if (GEM_WARN_ON(vma->inuse > 0))
> return;
>
> /* Don't do anything if the memory isn't mapped */
> @@ -61,7 +61,7 @@ void msm_gem_purge_vma(struct msm_gem_address_space *aspace,
> void msm_gem_unmap_vma(struct msm_gem_address_space *aspace,
> struct msm_gem_vma *vma)
> {
> - if (!WARN_ON(!vma->iova))
> + if (!GEM_WARN_ON(!vma->iova))
> vma->inuse--;
> }
>
> @@ -73,7 +73,7 @@ msm_gem_map_vma(struct msm_gem_address_space *aspace,
> unsigned size = npages << PAGE_SHIFT;
> int ret = 0;
>
> - if (WARN_ON(!vma->iova))
> + if (GEM_WARN_ON(!vma->iova))
> return -EINVAL;
>
> /* Increase the usage counter */
> @@ -100,7 +100,7 @@ msm_gem_map_vma(struct msm_gem_address_space *aspace,
> void msm_gem_close_vma(struct msm_gem_address_space *aspace,
> struct msm_gem_vma *vma)
> {
> - if (WARN_ON(vma->inuse > 0 || vma->mapped))
> + if (GEM_WARN_ON(vma->inuse > 0 || vma->mapped))
> return;
>
> spin_lock(&aspace->lock);
> @@ -120,7 +120,7 @@ int msm_gem_init_vma(struct msm_gem_address_space *aspace,
> {
> int ret;
>
> - if (WARN_ON(vma->iova))
> + if (GEM_WARN_ON(vma->iova))
> return -EBUSY;
>
> spin_lock(&aspace->lock);
--
With best wishes
Dmitry
Powered by blists - more mailing lists