-
- Downloads
panvk: Keep a ref to a pan_kmod_bo in panvk_image
We don't need the panfrost_bo object which contains both the BO and its CPU/GPU mappings. We store the GPU address at bind time and store it in the pimage object. While at it, keep a ref to the buffer object so we don't end up with a invalid deref (UAF) if the vulkan user does something silly like freeing the VkDeviceMemory object while the VkImage is still active. Flag this with a TODO to make sure we don't forget about it. Signed-off-by:Boris Brezillon <boris.brezillon@collabora.com> Reviewed-by:
Constantine Shablya <constantine.shablya@collabora.com> Reviewed-by:
Erik Faye-Lund <erik.faye-lund@collabora.com> Part-of: <mesa/mesa!26698>
Showing
- src/panfrost/vulkan/panvk_device.c 5 additions, 2 deletionssrc/panfrost/vulkan/panvk_device.c
- src/panfrost/vulkan/panvk_image.c 3 additions, 0 deletionssrc/panfrost/vulkan/panvk_image.c
- src/panfrost/vulkan/panvk_private.h 5 additions, 1 deletionsrc/panfrost/vulkan/panvk_private.h
- src/panfrost/vulkan/panvk_vX_device.c 1 addition, 1 deletionsrc/panfrost/vulkan/panvk_vX_device.c
- src/panfrost/vulkan/panvk_vX_image.c 1 addition, 1 deletionsrc/panfrost/vulkan/panvk_vX_image.c
- src/panfrost/vulkan/panvk_vX_meta_blit.c 2 additions, 2 deletionssrc/panfrost/vulkan/panvk_vX_meta_blit.c
- src/panfrost/vulkan/panvk_vX_meta_copy.c 4 additions, 4 deletionssrc/panfrost/vulkan/panvk_vX_meta_copy.c
Loading
Please register or sign in to comment