summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorOded Gabbay <ogabbay@kernel.org>2022-09-22 11:30:32 +0200
committerOded Gabbay <ogabbay@kernel.org>2022-11-23 15:13:39 +0100
commitea73ef14ddf93b8b1ae6ce1963846f43a81bb510 (patch)
treef14e870525fab877542ed57bc2f9f9a63ef0d2a0 /drivers
parenthabanalabs: allow control device open during reset (diff)
downloadlinux-ea73ef14ddf93b8b1ae6ce1963846f43a81bb510.tar.xz
linux-ea73ef14ddf93b8b1ae6ce1963846f43a81bb510.zip
habanalabs: Use simplified API for p2p dist calc
Use the simplified API that calculates distance between two devices. Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/misc/habanalabs/common/memory.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/misc/habanalabs/common/memory.c b/drivers/misc/habanalabs/common/memory.c
index ef28f3b37b93..99b1d6ce26ae 100644
--- a/drivers/misc/habanalabs/common/memory.c
+++ b/drivers/misc/habanalabs/common/memory.c
@@ -1689,7 +1689,7 @@ static int hl_dmabuf_attach(struct dma_buf *dmabuf,
hl_dmabuf = dmabuf->priv;
hdev = hl_dmabuf->ctx->hdev;
- rc = pci_p2pdma_distance_many(hdev->pdev, &attachment->dev, 1, true);
+ rc = pci_p2pdma_distance(hdev->pdev, attachment->dev, true);
if (rc < 0)
attachment->peer2peer = false;