summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEmil Velikov <emil.velikov@collabora.com>2019-07-17 00:04:39 +0100
committerEmil Velikov <emil.l.velikov@gmail.com>2020-03-16 14:25:19 +0000
commit655b3c55b9a6233091d4dc5d2e80a0373aa3e2d6 (patch)
tree0ee6178d08d58d842b28f61e32a23b8a28044121 /src
parentb357a8474074d911d1c03572d4d9db3ee420633a (diff)
Reuse the existing busid string
Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Michel Dänzer <michel.daenzer@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'src')
-rw-r--r--src/drmmode_display.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/drmmode_display.c b/src/drmmode_display.c
index c410d0b..2c0b96c 100644
--- a/src/drmmode_display.c
+++ b/src/drmmode_display.c
@@ -3432,7 +3432,7 @@ Bool drmmode_pre_init(ScrnInfoPtr pScrn, drmmode_ptr drmmode, int cpp)
unsigned int crtcs_needed = 0;
unsigned int crtcs_got = 0;
drmModeResPtr mode_res;
- char *bus_id_string, *provider_name;
+ char *provider_name;
xf86CrtcConfigInit(pScrn, &drmmode_xf86crtc_config_funcs);
@@ -3495,9 +3495,7 @@ Bool drmmode_pre_init(ScrnInfoPtr pScrn, drmmode_ptr drmmode, int cpp)
/* workout clones */
drmmode_clones_init(pScrn, drmmode, mode_res);
- bus_id_string = DRICreatePCIBusID(info->PciInfo);
- XNFasprintf(&provider_name, "%s @ %s", pScrn->chipset, bus_id_string);
- free(bus_id_string);
+ XNFasprintf(&provider_name, "%s @ %s", pScrn->chipset, pAMDGPUEnt->busid);
xf86ProviderSetup(pScrn, NULL, provider_name);
free(provider_name);