From 858170e8a40c2fcd1c47750944c5d5c10178241f Mon Sep 17 00:00:00 2001 From: Emil Velikov Date: Thu, 1 Dec 2016 19:54:39 +0000 Subject: [PATCH] winsys/amdgpu: use drmGetDevice2 API MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Analogous to previous commit Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=98502 Signed-off-by: Emil Velikov Reviewed-by: Michel Dänzer Reviewed-by: Marek Olšák Reviewed-by: Eric Engestrom Tested-by: Mike Lothian --- src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c b/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c index bf7a0573990..37e01403113 100644 --- a/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c +++ b/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c @@ -108,9 +108,9 @@ static bool do_winsys_init(struct amdgpu_winsys *ws, int fd) drmDevicePtr devinfo; /* Get PCI info. */ - r = drmGetDevice(fd, &devinfo); + r = drmGetDevice2(fd, 0, &devinfo); if (r) { - fprintf(stderr, "amdgpu: drmGetDevice failed.\n"); + fprintf(stderr, "amdgpu: drmGetDevice2 failed.\n"); goto fail; } ws->info.pci_domain = devinfo->businfo.pci->domain; -- 2.30.2