drmmode: fix screen resize without acceleration
PATCH 1/2 drmmode: fix screen resize without acceleration
This got broken with commit 86024cee back in 2014! drmmode_pixmap/nouveau_pixmap expect there to be EXA wrapping around the pixmap now, which is not there without accel.
--- src/drmmode_display.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
src/drmmode_display.c +1 -1
@@ -1561,7 +1561,7 @@ drmmode_xf86crtc_resize(ScrnInfoPtr scrn, int width, int height) } ppix = screen->GetScreenPixmap (screen); -if (pNv->AccelMethod >=NONE ) +if (pNv->AccelMethod >NONE )nouveau_bo_ref (pNv->scanout, &drmmode_pixmap (ppix)->bo); screen->ModifyPixmapHeader(ppix, width, height, -1, -1, pitch, (pNv->AccelMethod > NONE || pNv->ShadowPtr) ?
Signature · 1 line
2.26.2
A message that is not in the archive (sent off-list or not yet received): 20200718225319.27884-1-imirkin-FrUbXkNCsVf2fBVCVOL8/[email protected]
PATCH 2/2 present: don't enable if there's no acceleration
All the present logic relies on EXA being used to wrap everything. Unclear if present could even be used without the other things EXA enables, but better be safe.
--- src/nv_driver.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
src/nv_driver.c +1 -1
@@ -1489,7 +1489,7 @@ NVScreenInit(SCREEN_INIT_ARGS_DECL)xf86SetBlackWhitePixels (pScreen); -if (nouveau_present_init (pScreen)) +if (pNv->AccelMethod ==EXA &&nouveau_present_init (pScreen))xf86DrvMsg (pScrn->scrnIndex,X_INFO ,"Hardware support for Present enabled\n" );else
Signature · 1 line
2.26.2