amdgpu: Use bo_release to free DRI images.

Previously these would get leaked if we had multiple bo structs
pointing to the same image/GEM BO as each has their own DRI image,
but bo_destroy only gets called on the last struct.

To mitigate this we have a new callback for every struct where we
can free the DRI image.

TEST=Repeatedly open/close camera app on Grunt.

Change-Id: I6188346b5bf9e5cbbbbf32a3db621a3fe0276d4f
Tested-by: Bas Nieuwenhuizen <>
Reviewed-by: Yiwei Zhang <>
Commit-Queue: Bas Nieuwenhuizen <>
3 files changed