[PATCH] drm/amdgpu: Don't warn on destroying a pinned BO

Mike Lothian mike at fireburn.co.uk
Mon Jul 23 17:30:52 UTC 2018


Hi

I was hitting this

Feel free to add my tested by

Tested-by: Mike Lothian <mike at fireburn.co.uk>

Cheers

Mike

On Mon, 23 Jul 2018 at 17:50 Michel Dänzer <michel at daenzer.net> wrote:

> On 2018-07-19 05:39 PM, Michel Dänzer wrote:
> > From: Michel Dänzer <michel.daenzer at amd.com>
> >
> > The warning turned out to be not so useful, as BO destruction tends to
> > be deferred to a workqueue.
> >
> > Also, we should be preventing any damage from this now, so not really
> > important anymore to fix code doing this.
> >
> > Signed-off-by: Michel Dänzer <michel.daenzer at amd.com>
> > ---
> >  drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
> b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
> > index b12526ce1a9d..3010f0136de9 100644
> > --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
> > +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
> > @@ -89,7 +89,7 @@ static void amdgpu_ttm_bo_destroy(struct
> ttm_buffer_object *tbo)
> >       struct amdgpu_device *adev = amdgpu_ttm_adev(tbo->bdev);
> >       struct amdgpu_bo *bo = ttm_to_amdgpu_bo(tbo);
> >
> > -     if (WARN_ON_ONCE(bo->pin_count > 0))
> > +     if (bo->pin_count > 0)
> >               amdgpu_bo_subtract_pin_size(bo);
> >
> >       if (bo->kfd_bo)
> >
>
> Any feedback?
>
>
> --
> Earthling Michel Dänzer               |               http://www.amd.com
> Libre software enthusiast             |             Mesa and X developer
> _______________________________________________
> amd-gfx mailing list
> amd-gfx at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/amd-gfx/attachments/20180723/37e8eb96/attachment.html>


More information about the amd-gfx mailing list