accel/habanalabs: set hl_dmabuf_priv.device_address only when needed
authorTomer Tayar <ttayar@habana.ai>
Sun, 20 Aug 2023 11:17:06 +0000 (14:17 +0300)
committerOded Gabbay <ogabbay@kernel.org>
Mon, 9 Oct 2023 09:37:22 +0000 (12:37 +0300)
commit878ebc14db049ae85225756b187fec81df8108b3
tree0b43afc58ae260494126b9342cd287bdfe74a547
parentbb644f61970ad44147c9466b0cb99a028de02138
accel/habanalabs: set hl_dmabuf_priv.device_address only when needed

The device_address member of 'struct hl_dmabuf_priv' is used only when
virtual device memory is not supported and dma-buf is exported from
address.
Set the value of this field only when it is relevant, and add "phys" to
its name so it would be clearer that it can't be a device virtual
address.

Signed-off-by: Tomer Tayar <ttayar@habana.ai>
Reviewed-by: Oded Gabbay <ogabbay@kernel.org>
Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
drivers/accel/habanalabs/common/habanalabs.h
drivers/accel/habanalabs/common/memory.c