summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/amdkfd
diff options
context:
space:
mode:
authorHarish Kasiviswanathan <Harish.Kasiviswanathan@amd.com>2017-12-09 07:08:47 +0300
committerOded Gabbay <oded.gabbay@gmail.com>2017-12-09 07:08:47 +0300
commitd63f0ba27a3ee33211de4ec7f2c4287a03492cb2 (patch)
tree186e27d1367c3a52959528886833273b6822f69e /drivers/gpu/drm/amd/amdkfd
parentf7ce2fade6e143a333dc51d84f2080738d6831bf (diff)
downloadlinux-d63f0ba27a3ee33211de4ec7f2c4287a03492cb2.tar.xz
drm/amdkfd: Topology: Fix location_id
Fix location_id format to match Thunk specification. Signed-off-by: Harish Kasiviswanathan <Harish.Kasiviswanathan@amd.com> Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com> Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com> Signed-off-by: Oded Gabbay <oded.gabbay@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdkfd')
-rw-r--r--drivers/gpu/drm/amd/amdkfd/kfd_topology.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
index ca2e51a2fe75..b614746c2523 100644
--- a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
+++ b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
@@ -1166,8 +1166,8 @@ int kfd_topology_add_device(struct kfd_dev *gpu)
cu_info.cu_active_number;
dev->node_props.vendor_id = gpu->pdev->vendor;
dev->node_props.device_id = gpu->pdev->device;
- dev->node_props.location_id = (gpu->pdev->bus->number << 24) +
- (gpu->pdev->devfn & 0xffffff);
+ dev->node_props.location_id = PCI_DEVID(gpu->pdev->bus->number,
+ gpu->pdev->devfn);
/*
* TODO: Retrieve max engine clock values from KGD
*/