summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2020-10-15 01:42:56 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2020-10-15 01:42:56 +0000
commit8dbba0d798ed42afa75c07bd3d0cb4cedce53247 (patch)
tree9cc58ff50bdf7bd8af3de07abcd4c5cb36c30798 /sys
parentccbce81294d0b19326960888d5a45a0057419f9c (diff)
drm/amdgpu: move gpu_info parsing after common early init
From Alex Deucher 6e29c227a4976460ec6d4cc70b998e3a8c30c873 in mainline linux needed to load the correct gpu info firmware on raven2 (Ryzen 3 3200U/Ryzen 3 3250U/Athlon 300U/Athlon 3000G)
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/pci/drm/amd/amdgpu/amdgpu_device.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/dev/pci/drm/amd/amdgpu/amdgpu_device.c b/sys/dev/pci/drm/amd/amdgpu/amdgpu_device.c
index 2995a3fa78c..8ccf80d0a1c 100644
--- a/sys/dev/pci/drm/amd/amdgpu/amdgpu_device.c
+++ b/sys/dev/pci/drm/amd/amdgpu/amdgpu_device.c
@@ -1769,10 +1769,6 @@ static int amdgpu_device_ip_early_init(struct amdgpu_device *adev)
return -EINVAL;
}
- r = amdgpu_device_parse_gpu_info_fw(adev);
- if (r)
- return r;
-
amdgpu_amdkfd_device_probe(adev);
if (amdgpu_sriov_vf(adev)) {
@@ -1808,6 +1804,10 @@ static int amdgpu_device_ip_early_init(struct amdgpu_device *adev)
}
/* get the vbios after the asic_funcs are set up */
if (adev->ip_blocks[i].version->type == AMD_IP_BLOCK_TYPE_COMMON) {
+ r = amdgpu_device_parse_gpu_info_fw(adev);
+ if (r)
+ return r;
+
/* Read BIOS */
if (!amdgpu_get_bios(adev))
return -EINVAL;