Skip to contentSkip to conversation

drm/amdkfd: report the real PCI bus number

PATCH In review Evan Quan 2 participants 2 messages May 21, 2020

Subsystems (3)
lore
Share & tools
lore

Evan Quan

author
#0 lore raw

PATCH 1/1 drm/amdkfd: report the real PCI bus number

Since the PCI bus number retrieved by PCI_BUS_NUM(pdev->devfn) is wrong.

Change-Id I882a8531a65cdf91be20e34a034aca1f43f658b4
---
 drivers/gpu/drm/amd/amdkfd/kfd_iommu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/amdkfd/kfd_iommu.c +1 -1
index 8d871514671e..7c8786b9eb0a 100644
@@ -192,7 +192,7 @@ static int iommu_invalid_ppr_cb(struct pci_dev *pdev, int pasid,
 
 	dev_warn_ratelimited(kfd_device,
 			"Invalid PPR device %x:%x.%x pasid 0x%x address 0x%lX flags 0x%X",
-			PCI_BUS_NUM(pdev->devfn),
+			pdev->bus->number,
 			PCI_SLOT(pdev->devfn),
 			PCI_FUNC(pdev->devfn),
 			pasid,
Signature · 6 lines
2.26.2

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
maintainer Reviewed-by on v1 1/1
#1 lore raw

Am 2020-05-20 um 11:34 p.m. schrieb Evan Quan:

Quoted 5 lines

Since the PCI bus number retrieved by PCI_BUS_NUM(pdev->devfn) is wrong.

Change-Id I882a8531a65cdf91be20e34a034aca1f43f658b4
Quoted 9 lines
---
 drivers/gpu/drm/amd/amdkfd/kfd_iommu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/amd/amdkfd/kfd_iommu.c +0 -0
index 8d871514671e..7c8786b9eb0a 100644

drivers/gpu/drm/amd/amdkfd/kfd_iommu.c static int iommu_invalid_ppr_cb(struct pci_dev *pdev, int pasid, · line 198

Quoted 8 lines
drivers/gpu/drm/amd/amdkfd/kfd_iommu.c +1 -1
@@ -192,7 +192,7 @@ static int iommu_invalid_ppr_cb(struct pci_dev *pdev, int pasid,
 
 	dev_warn_ratelimited(kfd_device,
 			"Invalid PPR device %x:%x.%x pasid 0x%x address 0x%lX flags 0x%X",
-			PCI_BUS_NUM(pdev->devfn),
+			pdev->bus->number,
 			PCI_SLOT(pdev->devfn),
 			PCI_FUNC(pdev->devfn),
 			pasid,

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx