mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-23 09:57:08 +03:00
If the dmabuf attachment is not stored in the dmabuf priv data, on re-mapping the buffer, new attachment is prepared and the same is detached on finding existing mapping. Prior attachment is not detached in nvgpu_vm_find_mapping. However mapped_buffer stores the recent attachment that is detached. Hence on last unmap it will result in NULL access. Hence, detach the attachment stored in mapped_buffer in nvgpu_vm_find_mapping. Bug 2834141 Change-Id: I0c3c0b1c684b4984dba4f39edb8610b94961291e Signed-off-by: Sagar Kamble <skamble@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2290313 Tested-by: Debarshi Dutta <ddutta@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> Reviewed-by: Debarshi Dutta <ddutta@nvidia.com> Reviewed-by: Lakshmanan M <lm@nvidia.com> Reviewed-by: Vaibhav Kachore <vkachore@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
9.2 KiB
9.2 KiB