[PATCH libdrm] amdgpu: don't fail amdgpu_device_initialize if amdgpu.ids missing or unparseable
Xiaojie Yuan
Xiaojie.Yuan at amd.com
Mon Oct 9 09:11:02 UTC 2017
Signed-off-by: Xiaojie Yuan <Xiaojie.Yuan at amd.com>
---
amdgpu/amdgpu_device.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/amdgpu/amdgpu_device.c b/amdgpu/amdgpu_device.c
index 2b31c45..72dc6fa 100644
--- a/amdgpu/amdgpu_device.c
+++ b/amdgpu/amdgpu_device.c
@@ -286,10 +286,8 @@ int amdgpu_device_initialize(int fd,
amdgpu_vamgr_init(&dev->vamgr_32, start, max,
dev->dev_info.virtual_address_alignment);
- r = amdgpu_parse_asic_ids(&dev->asic_ids);
- if (r) {
- fprintf(stderr, "%s: Cannot parse ASIC IDs, 0x%x.",
- __func__, r);
+ if (amdgpu_parse_asic_ids(&dev->asic_ids) < 0) {
+ fprintf(stderr, "%s: Cannot parse ASIC IDs", __func__);
}
*major_version = dev->major_version;
--
2.7.4
More information about the amd-gfx
mailing list