From 437f02ce8d7e1e584dc94da5a13c70b97966e2e0 Mon Sep 17 00:00:00 2001 From: Guchun Chen Date: Wed, 21 Sep 2022 09:28:27 +0800 Subject: [PATCH] drm/amdgpu: fix build failure by redefinition of p2p_access This is a typo when cherry-picking code to dkms branch, not checking the code difference of p2p implementation between upstream and dkms branch. Signed-off-by: Guchun Chen --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c index 32b202e55fa92..caba3e60dc135 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c @@ -5588,9 +5588,9 @@ bool amdgpu_device_is_peer_accessible(struct amdgpu_device *adev, adev->gmc.aper_base + adev->gmc.aper_size - 1; #ifdef CONFIG_PCI_P2PDMA - bool p2p_access = !adev->gmc.xgmi.connected_to_cpu && - !(pci_p2pdma_distance_many(adev->pdev, - &peer_adev->dev, 1, true) < 0); + p2p_access = !adev->gmc.xgmi.connected_to_cpu && + !(pci_p2pdma_distance_many(adev->pdev, + &peer_adev->dev, 1, true) < 0); #endif return pcie_p2p && p2p_access && (adev->gmc.visible_vram_size && adev->gmc.real_vram_size == adev->gmc.visible_vram_size &&