From 0663bb119a1199fa14846879cf22c59fe0814f7b Mon Sep 17 00:00:00 2001 From: "Enrico Weigelt, metux IT consult" Date: Wed, 27 Mar 2024 19:08:38 +0100 Subject: [PATCH] xfree86: modesetting: fix warning on unused variable MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fix warning: ../hw/xfree86/drivers/modesetting/driver.c:1612:19: warning: unused variable ‘pEnt’ [-Wunused-variable] 1612 | EntityInfoPtr pEnt = ms->pEnt; | ^~~~ Signed-off-by: Enrico Weigelt, metux IT consult Part-of: --- hw/xfree86/drivers/modesetting/driver.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/hw/xfree86/drivers/modesetting/driver.c b/hw/xfree86/drivers/modesetting/driver.c index b33091cdc..66a074e0e 100644 --- a/hw/xfree86/drivers/modesetting/driver.c +++ b/hw/xfree86/drivers/modesetting/driver.c @@ -1609,7 +1609,6 @@ msEnableSharedPixmapFlipping(RRCrtcPtr crtc, PixmapPtr front, PixmapPtr back) ScreenPtr screen = crtc->pScreen; ScrnInfoPtr scrn = xf86ScreenToScrn(screen); modesettingPtr ms = modesettingPTR(scrn); - EntityInfoPtr pEnt = ms->pEnt; xf86CrtcPtr xf86Crtc = crtc->devPrivate; if (!xf86Crtc) @@ -1624,9 +1623,9 @@ msEnableSharedPixmapFlipping(RRCrtcPtr crtc, PixmapPtr front, PixmapPtr back) return FALSE; #ifdef XSERVER_PLATFORM_BUS - if (pEnt->location.type == BUS_PLATFORM) { - char *syspath = - xf86_platform_device_odev_attributes(pEnt->location.id.plat)-> + if (ms->pEnt->location.type == BUS_PLATFORM) { + const char *syspath = + xf86_platform_device_odev_attributes(ms->pEnt->location.id.plat)-> syspath; /* Not supported for devices using USB transport due to misbehaved