xserver: Branch 'master' - 4 commits

Adam Jackson ajax at kemper.freedesktop.org
Wed Oct 5 18:49:07 UTC 2016


 configure.ac         |    8 ++++----
 hw/xfree86/dri/dri.c |   22 +---------------------
 2 files changed, 5 insertions(+), 25 deletions(-)

New commits:
commit cc69d4f110bd8a87b9e6c238ebebf8d85cbd93ec
Author: Emil Velikov <emil.l.velikov at gmail.com>
Date:   Thu Sep 29 18:35:04 2016 +0100

    xfree86/dri: remove libdrm runtime checks
    
    As of last commit all the places in our configure.ac require version
    2.3.1 (released back in 2007) or later. With the latter introducing the
    1.3.0 version, as returned by drmGetLibVersion.
    
    Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
    Reviewed-by: Adam Jackson <ajax at redhat.com>

diff --git a/hw/xfree86/dri/dri.c b/hw/xfree86/dri/dri.c
index e4a21dc..0142b6e 100644
--- a/hw/xfree86/dri/dri.c
+++ b/hw/xfree86/dri/dri.c
@@ -158,9 +158,6 @@ DRIOpenDRMMaster(ScrnInfoPtr pScrn,
     Bool drmWasAvailable;
     DRIEntPrivPtr pDRIEntPriv;
     DRIEntPrivRec tmp;
-    drmVersionPtr drmlibv;
-    int drmlibmajor, drmlibminor;
-    const char *openBusID;
     int count;
     int err;
 
@@ -176,23 +173,6 @@ DRIOpenDRMMaster(ScrnInfoPtr pScrn,
 
     memset(&tmp, 0, sizeof(tmp));
 
-    /* Check the DRM lib version.
-     */
-
-    drmlibmajor = 1;
-    drmlibminor = 0;
-    drmlibv = drmGetLibVersion(-1);
-    if (drmlibv != NULL) {
-        drmlibmajor = drmlibv->version_major;
-        drmlibminor = drmlibv->version_minor;
-        drmFreeVersion(drmlibv);
-    }
-
-    /* Check if the libdrm can handle falling back to loading based on name
-     * if a busid string is passed.
-     */
-    openBusID = (drmlibmajor == 1 && drmlibminor >= 2) ? busID : NULL;
-
     tmp.drmFD = -1;
     sv.drm_di_major = 1;
     sv.drm_di_minor = 1;
@@ -201,7 +181,7 @@ DRIOpenDRMMaster(ScrnInfoPtr pScrn,
     saveSv = sv;
     count = 10;
     while (count--) {
-        tmp.drmFD = drmOpen(drmDriverName, openBusID);
+        tmp.drmFD = drmOpen(drmDriverName, busID);
 
         if (tmp.drmFD < 0) {
             DRIDrvMsg(-1, X_ERROR, "[drm] drmOpen failed.\n");
commit 962962e978e5cededc20e577a36f77eb24d14bda
Author: Emil Velikov <emil.l.velikov at gmail.com>
Date:   Thu Sep 29 18:35:03 2016 +0100

    configure.ac: bump the required libdrm version to 2.3.1
    
    It fixes a bug where the version reported by drmGetLibVersion() was
    'wrong'. See libdrm commit 79038751ffe("libdrm: add support for server
    side functionality in libdrm") for details.
    
    Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
    Reviewed-by: Adam Jackson <ajax at redhat.com>

diff --git a/configure.ac b/configure.ac
index 6bf7b83..4bb014d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -826,7 +826,7 @@ dnl List of libraries that require a specific version
 LIBAPPLEWM="applewm >= 1.4"
 LIBDMX="dmx >= 1.0.99.1"
 LIBDRI="dri >= 7.8.0"
-LIBDRM="libdrm >= 2.3.0"
+LIBDRM="libdrm >= 2.3.1"
 LIBEGL="egl"
 LIBGBM="gbm >= 10.2.0"
 LIBGL="gl >= 7.1.0"
commit 74a8b320fa5068cd86d8b8b8e73fa92caae9a8a6
Author: Emil Velikov <emil.l.velikov at gmail.com>
Date:   Thu Sep 29 18:35:02 2016 +0100

    configure.ac: use $LIBDRM over libdrm when using pkg-config
    
    The former contains the minimum required version which is required.
    Strictly speaking Xephyr/Xwayland may require version greater than the
    current 2.3.0, although I've personally haven't checked the specifics.
    
    Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
    Reviewed-by: Adam Jackson <ajax at redhat.com>

diff --git a/configure.ac b/configure.ac
index 7a8187e..6bf7b83 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2445,7 +2445,7 @@ if test "$KDRIVE" = yes; then
         XEPHYR_REQUIRED_LIBS="$XEPHYR_REQUIRED_LIBS xcb-xv"
     fi
     if test "x$DRI" = xyes && test "x$GLX" = xyes; then
-        XEPHYR_REQUIRED_LIBS="$XEPHYR_REQUIRED_LIBS libdrm xcb-glx xcb-xf86dri > 1.6"
+        XEPHYR_REQUIRED_LIBS="$XEPHYR_REQUIRED_LIBS $LIBDRM xcb-glx xcb-xf86dri > 1.6"
     fi
     if test "x$GLAMOR" = xyes; then
         XEPHYR_REQUIRED_LIBS="$XEPHYR_REQUIRED_LIBS x11-xcb"
@@ -2499,7 +2499,7 @@ AM_CONDITIONAL(XFAKESERVER, [test "x$KDRIVE" = xyes && test "x$XFAKE" = xyes])
 
 dnl Xwayland DDX
 
-XWAYLANDMODULES="wayland-client >= 1.3.0 wayland-protocols >= 1.1 libdrm epoxy"
+XWAYLANDMODULES="wayland-client >= 1.3.0 wayland-protocols >= 1.1 $LIBDRM epoxy"
 if test "x$XF86VIDMODE" = xyes; then
 	XWAYLANDMODULES="$XWAYLANDMODULES $VIDMODEPROTO"
 fi
commit 45e1220486139c483a69366323f8f590beffa19d
Author: Emil Velikov <emil.l.velikov at gmail.com>
Date:   Thu Sep 29 18:35:01 2016 +0100

    configure.ac: default to DRI=yes on solaris platforms
    
    Afaict there's little-to-no reason/way one would want xserver without
    DRI support on Solaris platforms.
    
    This will allow us to simplify/fix all the libdrm detection in the next
    commit.
    
    Cc: Alan Coopersmith <alan.coopersmith at oracle.com>
    Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
    Reviewed-by: Alan Coopersmith <alan.coopersmith at oracle.com>
    Reviewed-by: Adam Jackson <ajax at redhat.com>

diff --git a/configure.ac b/configure.ac
index f5c79ab..7a8187e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -411,7 +411,7 @@ case $host_os in
 	DRI=yes
 	;;
   *solaris*)
-	PKG_CHECK_EXISTS(libdrm, DRI=yes, DRI=no)
+	DRI=yes
 	;;
   darwin*)
 	AC_DEFINE(CSRG_BASED, 1, [System is BSD-like])


More information about the xorg-commit mailing list