From 9246575170a5158c940218b6ad286e8ab087550a Mon Sep 17 00:00:00 2001 From: jsg Date: Wed, 28 Aug 2024 06:09:36 +0000 Subject: [PATCH] change dev_set_drvdata() call to pci_set_drvdata() to match linux no functional change --- sys/dev/pci/drm/amd/amdgpu/amdgpu_drv.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/sys/dev/pci/drm/amd/amdgpu/amdgpu_drv.c b/sys/dev/pci/drm/amd/amdgpu/amdgpu_drv.c index 7cdb925c4be..e2bf839ce32 100644 --- a/sys/dev/pci/drm/amd/amdgpu/amdgpu_drv.c +++ b/sys/dev/pci/drm/amd/amdgpu/amdgpu_drv.c @@ -3491,8 +3491,9 @@ amdgpu_init_backlight(struct amdgpu_device *adev) void amdgpu_attachhook(struct device *self) { - struct amdgpu_device *adev = (struct amdgpu_device *)self; - struct drm_device *dev = &adev->ddev; + struct amdgpu_device *adev = (struct amdgpu_device *)self; + struct drm_device *dev = &adev->ddev; + struct pci_dev *pdev = adev->pdev; int r, acpi_status; struct rasops_info *ri = &adev->ro; struct drm_fb_helper *fb_helper; @@ -3500,7 +3501,7 @@ amdgpu_attachhook(struct device *self) struct drm_gem_object *obj; struct amdgpu_bo *rbo; - dev_set_drvdata(self, dev); + pci_set_drvdata(pdev, dev); r = amdgpu_driver_load_kms(adev, adev->flags); if (r) -- 2.20.1