xf86-video-nv: src/nv_driver.c src/riva_driver.c
GitLab Mirror
gitlab-mirror at kemper.freedesktop.org
Sat Dec 16 17:21:12 UTC 2023
src/nv_driver.c | 5 +++++
src/riva_driver.c | 5 +++++
2 files changed, 10 insertions(+)
New commits:
commit e64b5ac6dbef000ad4c26a151cc4e3d4f21e2ad0
Author: Alan Coopersmith <alan.coopersmith at oracle.com>
Date: Thu Dec 7 18:23:53 2023 -0800
Don't call xf86DisableRandR in ABI_VIDEODRV_VERSION 24 & later
The API was removed by Xserver commit dd00e5466a0e4ea313d1860824da4123692827ed
in xorg-server-1.20.0 and later.
Found by gcc -Werror=implicit:
riva_driver.c: In function ‘RivaScreenInit’:
riva_driver.c:1213:12: error: implicit declaration of function
‘xf86DisableRandR’; did you mean ‘xf86DisableIO’?
[-Werror=implicit-function-declaration]
1213 | xf86DisableRandR();
| ^~~~~~~~~~~~~~~~
| xf86DisableIO
nv_driver.c: In function ‘NVScreenInit’:
nv_driver.c:2635:16: error: implicit declaration of function
‘xf86DisableRandR’; did you mean ‘xf86DisableIO’?
[-Werror=implicit-function-declaration]
2635 | xf86DisableRandR();
| ^~~~~~~~~~~~~~~~
| xf86DisableIO
Signed-off-by: Alan Coopersmith <alan.coopersmith at oracle.com>
diff --git a/src/nv_driver.c b/src/nv_driver.c
index c94a890..99b2990 100644
--- a/src/nv_driver.c
+++ b/src/nv_driver.c
@@ -2632,9 +2632,14 @@ NVScreenInit(SCREEN_INIT_ARGS_DECL)
case 32: refreshArea = NVRefreshArea32; break;
}
if(!pNv->RandRRotation) {
+#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 24
xf86DisableRandR();
xf86DrvMsg(pScrn->scrnIndex, X_INFO,
"Driver rotation enabled, RandR disabled\n");
+#else
+ xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+ "Driver rotation enabled\n");
+#endif
}
}
pNv->refreshArea = refreshArea;
diff --git a/src/riva_driver.c b/src/riva_driver.c
index 759501e..501266f 100644
--- a/src/riva_driver.c
+++ b/src/riva_driver.c
@@ -1210,9 +1210,14 @@ RivaScreenInit(SCREEN_INIT_ARGS_DECL)
case 16: refreshArea = RivaRefreshArea16; break;
case 32: refreshArea = RivaRefreshArea32; break;
}
+#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 24
xf86DisableRandR();
xf86DrvMsg(pScrn->scrnIndex, X_INFO,
"Driver rotation enabled, RandR disabled\n");
+#else
+ xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+ "Driver rotation enabled\n");
+#endif
}
ShadowFBInit(pScreen, refreshArea);
More information about the xorg-commit
mailing list