[PATCH v2 5/9] drm/amdkfd: use helper pci_dev_id
Koenig, Christian
Christian.Koenig at amd.com
Thu Apr 25 06:57:58 UTC 2019
Am 24.04.19 um 21:14 schrieb Heiner Kallweit:
> Use new helper pci_dev_id() to simplify the code.
>
> Signed-off-by: Heiner Kallweit <hkallweit1 at gmail.com>
Acked-by: Christian König <christian.koenig at amd.com>
> ---
> drivers/gpu/drm/amd/amdkfd/kfd_topology.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
> index 2cb09e088..769dbc7be 100644
> --- a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
> +++ b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
> @@ -1272,8 +1272,7 @@ int kfd_topology_add_device(struct kfd_dev *gpu)
>
> dev->node_props.vendor_id = gpu->pdev->vendor;
> dev->node_props.device_id = gpu->pdev->device;
> - dev->node_props.location_id = PCI_DEVID(gpu->pdev->bus->number,
> - gpu->pdev->devfn);
> + dev->node_props.location_id = pci_dev_id(gpu->pdev);
> dev->node_props.max_engine_clk_fcompute =
> amdgpu_amdkfd_get_max_engine_clock_in_mhz(dev->gpu->kgd);
> dev->node_props.max_engine_clk_ccompute =
More information about the amd-gfx
mailing list