diff --git a/hw/kdrive/fbdev/fb_glamor.c b/hw/kdrive/fbdev/fb_glamor.c index 2994c7e83d..2a421bb097 100644 --- a/hw/kdrive/fbdev/fb_glamor.c +++ b/hw/kdrive/fbdev/fb_glamor.c @@ -16,10 +16,15 @@ #include "fbdev.h" +#ifdef XV +#include "kxv.h" +#endif + const char *fbdev_glvnd_provider = "mesa"; Bool es_allowed = TRUE; Bool force_es = FALSE; +Bool fbXVAllowed = TRUE; static void fbdev_glamor_egl_cleanup(FbdevScrPriv *scrpriv) @@ -101,6 +106,12 @@ fbdevInitAccel(ScreenPtr pScreen) } #endif +#ifdef XV + if (fbXVAllowed) { + kd_glamor_xv_init(pScreen); + } +#endif + return TRUE; } diff --git a/hw/kdrive/fbdev/fbdev.h b/hw/kdrive/fbdev/fbdev.h index e6685b5879..8351733f4f 100644 --- a/hw/kdrive/fbdev/fbdev.h +++ b/hw/kdrive/fbdev/fbdev.h @@ -66,6 +66,9 @@ extern Bool fbDisableShadow; extern const char *fbdev_glvnd_provider; extern Bool es_allowed; extern Bool force_es; +#ifdef XV +extern Bool fbXVAllowed; +#endif #endif Bool fbdevCardInit(KdCardInfo * card); diff --git a/hw/kdrive/fbdev/fbinit.c b/hw/kdrive/fbdev/fbinit.c index c8d337ed10..edbadd39eb 100644 --- a/hw/kdrive/fbdev/fbinit.c +++ b/hw/kdrive/fbdev/fbinit.c @@ -76,6 +76,8 @@ ddxUseMsg(void) ("-force-gl Force glamor to only use GL contexts\n"); ErrorF ("-force-es Force glamor to only use GLES contexts\n"); + ErrorF + ("-noxv Disable X-Video support\n"); ErrorF("\n"); } @@ -115,6 +117,13 @@ ddxProcessArgument(int argc, char **argv, int i) force_es = TRUE; return 1; } + +#ifdef XV + if (!strcmp(argv[i], "-noxv")) { + fbXVAllowed = FALSE; + return 1; + } +#endif #endif return KdProcessArgument(argc, argv, i);