diff options
author | Tomer Tayar <ttayar@habana.ai> | 2022-12-15 16:36:53 +0200 |
---|---|---|
committer | Oded Gabbay <ogabbay@kernel.org> | 2023-01-26 10:56:22 +0200 |
commit | 9b3d9f917f81aed559d19377c11d6fac3db89fd7 (patch) | |
tree | 640657ae7bdd2acda6b1130687db481c2cac0208 /drivers/clk | |
parent | 6bdb7bc990cbed81f703c4a265843f959359489c (diff) | |
download | linux-9b3d9f917f81aed559d19377c11d6fac3db89fd7.tar.gz linux-9b3d9f917f81aed559d19377c11d6fac3db89fd7.tar.bz2 linux-9b3d9f917f81aed559d19377c11d6fac3db89fd7.zip |
habanalabs: fix dma-buf release handling if dma_buf_fd() fails
The dma-buf private object is freed if a call to dma_buf_fd() fails,
and because a file was already associated with the dma-buf in
dma_buf_export(), the release op will be called and will use this
object.
Mark the 'priv' field as NULL in this case, and avoid accessing it from
the release op.
Signed-off-by: Tomer Tayar <ttayar@habana.ai>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
Diffstat (limited to 'drivers/clk')
0 files changed, 0 insertions, 0 deletions