[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

xserver-xorg-video-vmware: Changes to 'debian-unstable'



 ChangeLog                  |  209 ++++++++++++++++
 configure.ac               |   14 +
 debian/changelog           |   10 
 debian/control             |    7 
 debian/watch               |    2 
 src/compat-api.h           |    5 
 src/svga_modes.h           |    1 
 vmwgfx/Makefile.am         |    2 
 vmwgfx/vmwgfx_crtc.c       |   26 +-
 vmwgfx/vmwgfx_ctrl.c       |    5 
 vmwgfx/vmwgfx_dri2.c       |    3 
 vmwgfx/vmwgfx_driver.c     |   44 ++-
 vmwgfx/vmwgfx_driver.h     |   33 ++
 vmwgfx/vmwgfx_drm.h        |    1 
 vmwgfx/vmwgfx_layout.c     |  265 +++++++++++++++++++++
 vmwgfx/vmwgfx_output.c     |  566 ++++++++++++++++++++++++++++++++++++++++-----
 vmwgfx/vmwgfx_overlay.c    |    3 
 vmwgfx/vmwgfx_rr_inlines.h |   92 +++++++
 vmwgfx/vmwgfx_saa.c        |   15 -
 vmwgfx/vmwgfx_saa.h        |    7 
 vmwgfx/vmwgfx_saa_priv.h   |    1 
 vmwgfx/vmwgfx_tex_video.c  |  278 +++++++++++++++++++++-
 22 files changed, 1494 insertions(+), 95 deletions(-)

New commits:
commit 322c5594dcf1cd669aea09b7eee08ce0f1c15e6c
Author: Timo Aaltonen <tjaalton@debian.org>
Date:   Thu Nov 17 14:50:43 2016 +0200

    upload to sid

diff --git a/debian/changelog b/debian/changelog
index 8ee0c20..94e5efd 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,4 +1,4 @@
-xserver-xorg-video-vmware (1:13.2.1-1) UNRELEASED; urgency=medium
+xserver-xorg-video-vmware (1:13.2.1-1) unstable; urgency=medium
 
   * New upstream release.
   * Use https URLs in Vcs-* control fields.
@@ -6,7 +6,7 @@ xserver-xorg-video-vmware (1:13.2.1-1) UNRELEASED; urgency=medium
   * watch: Use https url.
   * control: Add libudev-dev to build-depends on linux.
 
- -- Timo Aaltonen <tjaalton@debian.org>  Thu, 17 Nov 2016 13:59:45 +0200
+ -- Timo Aaltonen <tjaalton@debian.org>  Thu, 17 Nov 2016 14:50:15 +0200
 
 xserver-xorg-video-vmware (1:13.1.0-2) unstable; urgency=medium
 

commit bb9bb2f86f0fb412c137d1dbd4f90e87ec69b781
Author: Timo Aaltonen <tjaalton@debian.org>
Date:   Thu Nov 17 14:50:14 2016 +0200

    control: Add libudev-dev to build-depends on linux.

diff --git a/debian/changelog b/debian/changelog
index a87f52b..8ee0c20 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -4,6 +4,7 @@ xserver-xorg-video-vmware (1:13.2.1-1) UNRELEASED; urgency=medium
   * Use https URLs in Vcs-* control fields.
   * control: Bump policy to 3.9.8, no changes.
   * watch: Use https url.
+  * control: Add libudev-dev to build-depends on linux.
 
  -- Timo Aaltonen <tjaalton@debian.org>  Thu, 17 Nov 2016 13:59:45 +0200
 
diff --git a/debian/control b/debian/control
index 439d53e..e96b8c2 100644
--- a/debian/control
+++ b/debian/control
@@ -16,6 +16,7 @@ Build-Depends:
  x11proto-xinerama-dev,
  xutils-dev (>= 1:7.5+4),
  libdrm-dev [!hurd-i386],
+ libudev-dev [linux-any],
  libxext-dev,
  libx11-dev,
  libxatracker-dev [linux-any],

commit ec1e51276af384c261e43736232d2830d955ea75
Author: Timo Aaltonen <tjaalton@debian.org>
Date:   Thu Nov 17 14:14:25 2016 +0200

    watch: Use https url.

diff --git a/debian/changelog b/debian/changelog
index 6eaf37c..a87f52b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,6 +3,7 @@ xserver-xorg-video-vmware (1:13.2.1-1) UNRELEASED; urgency=medium
   * New upstream release.
   * Use https URLs in Vcs-* control fields.
   * control: Bump policy to 3.9.8, no changes.
+  * watch: Use https url.
 
  -- Timo Aaltonen <tjaalton@debian.org>  Thu, 17 Nov 2016 13:59:45 +0200
 
diff --git a/debian/watch b/debian/watch
index 4ec84e5..ea67154 100644
--- a/debian/watch
+++ b/debian/watch
@@ -1,4 +1,4 @@
 #git=git://anongit.freedesktop.org/xorg/driver/xf86-video-vmware
 version=3
 opts=pgpsigurlmangle=s/$/.sig/ \
-http://xorg.freedesktop.org/releases/individual/driver/ xf86-video-vmware-(.*)\.tar\.gz
+https://xorg.freedesktop.org/releases/individual/driver/ xf86-video-vmware-(.*)\.tar\.gz

commit 669cc564f29ea43dea5e1c0426c82aa6fc465ae8
Author: Timo Aaltonen <tjaalton@debian.org>
Date:   Thu Nov 17 14:02:00 2016 +0200

    control: Bump policy to 3.9.8, no changes.

diff --git a/debian/changelog b/debian/changelog
index 7403557..6eaf37c 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,7 @@ xserver-xorg-video-vmware (1:13.2.1-1) UNRELEASED; urgency=medium
 
   * New upstream release.
   * Use https URLs in Vcs-* control fields.
+  * control: Bump policy to 3.9.8, no changes.
 
  -- Timo Aaltonen <tjaalton@debian.org>  Thu, 17 Nov 2016 13:59:45 +0200
 
diff --git a/debian/control b/debian/control
index 69bdc73..439d53e 100644
--- a/debian/control
+++ b/debian/control
@@ -19,7 +19,7 @@ Build-Depends:
  libxext-dev,
  libx11-dev,
  libxatracker-dev [linux-any],
-Standards-Version: 3.9.6
+Standards-Version: 3.9.8
 Vcs-Git: https://anonscm.debian.org/git/pkg-xorg/driver/xserver-xorg-video-vmware.git
 Vcs-Browser: https://anonscm.debian.org/git/pkg-xorg/driver/xserver-xorg-video-vmware.git
 

commit d22aa061a91215d75d97b26dab286f293bf588dc
Author: Timo Aaltonen <tjaalton@debian.org>
Date:   Thu Nov 17 14:01:36 2016 +0200

    Use https URLs in Vcs-* control fields.

diff --git a/debian/changelog b/debian/changelog
index 68f4a4b..7403557 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,6 +1,7 @@
 xserver-xorg-video-vmware (1:13.2.1-1) UNRELEASED; urgency=medium
 
   * New upstream release.
+  * Use https URLs in Vcs-* control fields.
 
  -- Timo Aaltonen <tjaalton@debian.org>  Thu, 17 Nov 2016 13:59:45 +0200
 
diff --git a/debian/control b/debian/control
index 09c8a10..69bdc73 100644
--- a/debian/control
+++ b/debian/control
@@ -20,8 +20,8 @@ Build-Depends:
  libx11-dev,
  libxatracker-dev [linux-any],
 Standards-Version: 3.9.6
-Vcs-Git: git://git.debian.org/git/pkg-xorg/driver/xserver-xorg-video-vmware
-Vcs-Browser: http://git.debian.org/?p=pkg-xorg/driver/xserver-xorg-video-vmware.git
+Vcs-Git: https://anonscm.debian.org/git/pkg-xorg/driver/xserver-xorg-video-vmware.git
+Vcs-Browser: https://anonscm.debian.org/git/pkg-xorg/driver/xserver-xorg-video-vmware.git
 
 Package: xserver-xorg-video-vmware
 Architecture: any-amd64 any-i386

commit 0d665dac9052d48e8e911e70ccda0703427b298f
Author: Timo Aaltonen <tjaalton@debian.org>
Date:   Thu Nov 17 14:00:23 2016 +0200

    update changelogs

diff --git a/ChangeLog b/ChangeLog
index 8bfe3ed..97e3d2a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,12 +1,193 @@
-commit 891ee48e4c1baa2643eda048b4207f8263a37dca
+commit 0e94cd85b2fa1501d4d883de3c97074c5ea5c373
 Author: Thomas Hellstrom <thellstrom@vmware.com>
-Date:   Mon Jan 19 11:23:50 2015 +0100
+Date:   Wed Nov 16 11:22:53 2016 +0700
 
-    vmware: Bump version number for release
+    Bump minor for release.
     
     Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
 
-commit 79289b0ffc553ded902eea7b8b9803b098f340e3
+commit 3fd542b0394f9ab198b7750409ec2c0f16eb59da
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Nov 16 11:35:58 2016 +0700
+
+    vmware/vmwgfx: Add a missing source file for distribution
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+    (cherry picked from commit fade4f46e84e93153edc3472abb73635f87555e6)
+
+commit e53a7e42eb7597808a364f230a97ce64481f084b
+Author: Hans de Goede <hdegoede@redhat.com>
+Date:   Thu Sep 29 19:37:22 2016 +0200
+
+    Adapt Block/WakeupHandler signature for ABI 23
+    
+    Signed-off-by: Hans de Goede <hdegoede@redhat.com>
+    Acked-by: Thomas Hellstrom <thellstrom@vmware.com>
+    (cherry picked from commit d64d01c7a599dc3c79125701f076a3e459cefdc2)
+
+commit 0bcd4df1843f00f8e8507750401ec2a2a29330dc
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Thu Feb 11 09:45:58 2016 +0100
+
+    vmware: Bump minor to signal availability of new features
+    
+    While this may never be an official release, bump minor to enable the
+    new resolutionKMS functionality. This signals the availability of
+    autolayout and resolutionKMS support.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Brian Paul <brianp@vmware.com>
+
+commit 5036e9d11a899d831b1471f64132eefcf459b222
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Thu Feb 11 09:40:55 2016 +0100
+
+    vmware/vmwgfx: Don't require screen objects to run
+    
+    Using the vmwgfx ldu backend works just as fine except that we're limited
+    to implicit layout placement.
+    
+    With this test on, we may end up in the odd situation that the vmwgfx kernel
+    module and the vwmare legacy Xorg driver are enabled simultaneously, and that
+    is an unsupported configuration. It will also break resolutionKMS which will
+    be enabled based on vmwgfx version but should be disabled since the legacy
+    Xorg driver runs...
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Brian Paul <brianp@vmware.com>
+
+commit 57d4499cc252bd1c3362a569ca7fd99ba6b645ed
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Jan 20 19:08:21 2016 +0100
+
+    vmware/vmwgfx: Disable autolayout if we detect an old resolutionset
+    
+    While the autolayout feature should really avoid races both with the old
+    resolutionSet RandR12 code and with new compositor layout code, let's
+    disable the autolayout feature if someone tries to set the
+    layout / resolution through the vmwarectrl interface.
+    That's most likely an old resolutionSet.
+    
+    Autolayout is turned on on each new screen generation.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+
+commit 48fb82f13ca290e9fbb8c7f79aba5ee119a3ce7f
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Jan 20 14:21:40 2016 +0100
+
+    vmware/vmwgfx: Read the implicit output status from KMS if available.
+    
+    This information is used to switch to software cursors if we have
+    multiple overlapping explicit outputs and thus might need to display
+    two cursors simultaneously.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+
+commit a81e359d88151159e3a19ceb95027029fef0a9ba
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Jan 20 14:04:13 2016 +0100
+
+    vmware/vmwgfx: Avoid filling the log with modeline printouts
+    
+    There are specific debug options for that.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+
+commit 5978597da92898a424837ee89e66f66a8120480c
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Jan 20 13:01:21 2016 +0100
+
+    vmware/vmwgfx: Add a layout handler v2
+    
+    Add a handler that, on hotplug events, scans for a new GUI layout and
+    tries to set that layout using XRandR similar to what the RandR1.2 part of
+    vmware tools resolutionSet module is doing today.
+    
+    v2: Address review comments
+    - Keep the old layout in case of screen resizing errors
+    - Fix the vmwgfx_layout handler() declaration.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+
+commit 885e360b16fd88b48b40930c6277637615aab188
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Jan 20 12:09:22 2016 +0100
+
+    vmware/vmwgfx: Update RandR output properties on hotplug events v2
+    
+    Update also RandR output properties when we receive hotplug events;
+    the RRGetInfo function doesn't do this.
+    
+    This makes sure RandR sends out property change events to clients.
+    Also remove some debugging printouts.
+    
+    v2: Address review comment from Sinclair Yeh;
+    make sure struct output_private::drm_connector is always valid.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+
+commit ada41a5988df8414011ed37ec51cbb402c9c8716
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Jan 20 11:51:46 2016 +0100
+
+    vmware/vmwgfx: Add missing includes of the config.h header.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+
+commit 755e38f373a511bd774a61c9420a67f630f71037
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Thu Dec 18 10:46:42 2014 +0100
+
+    vmware/vmwgfx: Expose kernel connector attributes and react to hotplug events
+    
+    Much of this code is borrowed from the xf86-video-modesetting driver.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+
+commit 1e443c4717a8b107c0c9283e222482703ac0f358
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Feb 25 01:51:11 2015 -0800
+
+    vmware/vmwgfx: Try to use only_hw_present semantics if screen targets are enabled
+    
+    If screen targets are enabled and there is a reasonable chance that the vmwgfx
+    drm driver can use the surface backing a pixmap as a screen target surface,
+    then make that surface a modesetting framebuffer rather than the corresponding
+    DMA buffer. In practice this applies when we start scanning out from the
+    origin (0,0) of the pixmap. However, we would also like to apply the constraint
+    that the scanout area is the entire pixmap, since that is the constraint used
+    by the drm driver, but that would currently require drm framebuffer
+    reallocations and possible flicker, so disable that for now. The drm driver
+    will correctly handle the possibly oversized surface handed to it anyway, and
+    the cost we pay for this is an extra hardware copy of the dirtied area when
+    doing a software update of the scanout.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+
+commit 8f0cf7c03597532feb1a8ccf3bb1cafcd6170f89
+Author: Thomas Klausner <wiz@NetBSD.org>
+Date:   Sun Aug 10 11:04:51 2014 +0200
+
+    Add 2560x1440 to supported resolutions.
+    
+    Native resolution on iMac 27".
+    Reported missing by Benjamin Lorenz in
+    http://gnats.netbsd.org/49094
+    
+    Signed-off-by: Thomas Klausner <wiz@NetBSD.org>
+    Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
+
+commit ab5be2312023d8ccc7156a05ccc1b0abe7679244
 Author: Adam Jackson <ajax@redhat.com>
 Date:   Thu Dec 4 10:35:04 2014 -0500
 
@@ -20,6 +201,26 @@ Date:   Thu Dec 4 10:35:04 2014 -0500
     Signed-off-by: Adam Jackson <ajax@redhat.com>
     Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
 
+commit 3f7defa8dc595342e2502206ed2006f2be20a884
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Mon Nov 17 19:18:15 2014 +0100
+
+    vmware/vmwgfx: Make large Xv video blits cheaper
+    
+    As screens grow larger, attempt to make large Xv video blits cheaper by
+    performing the color conversion and scaling in two steps:
+    
+    1) Color conversion which has a 4x4 matrix multiplication shader is performed
+       to a bounce buffer the size of which is never larger than the source image.
+    2) Scaling is performed as a src composite blit to the destination image with
+       a simple copy shader.
+    
+    This split is done only if the destination image is substantially larger than
+    the source image / bounce buffer
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+
 commit 4664412d7a5266d2b392957406b34abc5db95e48
 Author: Stefan Dirsch <sndirsch@suse.de>
 Date:   Tue Oct 7 11:29:32 2014 +0200
diff --git a/debian/changelog b/debian/changelog
index c7660f8..68f4a4b 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+xserver-xorg-video-vmware (1:13.2.1-1) UNRELEASED; urgency=medium
+
+  * New upstream release.
+
+ -- Timo Aaltonen <tjaalton@debian.org>  Thu, 17 Nov 2016 13:59:45 +0200
+
 xserver-xorg-video-vmware (1:13.1.0-2) unstable; urgency=medium
 
   * Restrict architecture list to x86.

commit 0e94cd85b2fa1501d4d883de3c97074c5ea5c373
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Wed Nov 16 11:22:53 2016 +0700

    Bump minor for release.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>

diff --git a/configure.ac b/configure.ac
index 9cd793d..9f259ce 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@
 # Initialize Autoconf
 AC_PREREQ([2.60])
 AC_INIT([xf86-video-vmware],
-        [13.2.0],
+        [13.2.1],
         [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
         [xf86-video-vmware])
 AC_CONFIG_SRCDIR([Makefile.am])

commit 3fd542b0394f9ab198b7750409ec2c0f16eb59da
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Wed Nov 16 11:35:58 2016 +0700

    vmware/vmwgfx: Add a missing source file for distribution
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
    (cherry picked from commit fade4f46e84e93153edc3472abb73635f87555e6)

diff --git a/vmwgfx/Makefile.am b/vmwgfx/Makefile.am
index 19533e6..e486514 100644
--- a/vmwgfx/Makefile.am
+++ b/vmwgfx/Makefile.am
@@ -31,5 +31,6 @@ libvmwgfx_la_SOURCES = \
 	vmwgfx_xmir.c \
 	vmwgfx_xwayland.c \
 	vmwgfx_layout.c \
+	vmwgfx_rr_inlines.h \
 	wsbm_util.h
 endif

commit e53a7e42eb7597808a364f230a97ce64481f084b
Author: Hans de Goede <hdegoede@redhat.com>
Date:   Thu Sep 29 19:37:22 2016 +0200

    Adapt Block/WakeupHandler signature for ABI 23
    
    Signed-off-by: Hans de Goede <hdegoede@redhat.com>
    Acked-by: Thomas Hellstrom <thellstrom@vmware.com>
    (cherry picked from commit d64d01c7a599dc3c79125701f076a3e459cefdc2)

diff --git a/src/compat-api.h b/src/compat-api.h
index 205ac59..02876c5 100644
--- a/src/compat-api.h
+++ b/src/compat-api.h
@@ -75,8 +75,13 @@
 
 #define SCREEN_INIT_ARGS_DECL ScreenPtr pScreen, int argc, char **argv
 
+#if ABI_VIDEODRV_VERSION >= SET_ABI_VERSION(23, 0)
+#define BLOCKHANDLER_ARGS_DECL ScreenPtr arg, pointer pTimeout
+#define BLOCKHANDLER_ARGS arg, pTimeout
+#else
 #define BLOCKHANDLER_ARGS_DECL ScreenPtr arg, pointer pTimeout, pointer pReadmask
 #define BLOCKHANDLER_ARGS arg, pTimeout, pReadmask
+#endif
 
 #define CLOSE_SCREEN_ARGS_DECL ScreenPtr pScreen
 #define CLOSE_SCREEN_ARGS pScreen

commit 0bcd4df1843f00f8e8507750401ec2a2a29330dc
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Thu Feb 11 09:45:58 2016 +0100

    vmware: Bump minor to signal availability of new features
    
    While this may never be an official release, bump minor to enable the
    new resolutionKMS functionality. This signals the availability of
    autolayout and resolutionKMS support.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Brian Paul <brianp@vmware.com>

diff --git a/configure.ac b/configure.ac
index d33d6eb..9cd793d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@
 # Initialize Autoconf
 AC_PREREQ([2.60])
 AC_INIT([xf86-video-vmware],
-        [13.0.2],
+        [13.2.0],
         [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
         [xf86-video-vmware])
 AC_CONFIG_SRCDIR([Makefile.am])

commit 5036e9d11a899d831b1471f64132eefcf459b222
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Thu Feb 11 09:40:55 2016 +0100

    vmware/vmwgfx: Don't require screen objects to run
    
    Using the vmwgfx ldu backend works just as fine except that we're limited
    to implicit layout placement.
    
    With this test on, we may end up in the odd situation that the vmwgfx kernel
    module and the vwmare legacy Xorg driver are enabled simultaneously, and that
    is an unsupported configuration. It will also break resolutionKMS which will
    be enabled based on vmwgfx version but should be disabled since the legacy
    Xorg driver runs...
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Brian Paul <brianp@vmware.com>

diff --git a/vmwgfx/vmwgfx_driver.c b/vmwgfx/vmwgfx_driver.c
index 693b5ef..b9ee1db 100644
--- a/vmwgfx/vmwgfx_driver.c
+++ b/vmwgfx/vmwgfx_driver.c
@@ -554,18 +554,6 @@ drv_pre_init(ScrnInfoPtr pScrn, int flags)
 
     ms->check_fb_size = (vmwgfx_max_fb_size(ms->fd, &ms->max_fb_size) == 0);
 
-    if (vmwgfx_get_param(ms->fd, DRM_VMW_PARAM_HW_CAPS, &cap) != 0) {
-	xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "Failed to detect device "
-		   "screen object capability.\n");
-	goto out_depth;
-    }
-
-    if ((cap & SVGA_CAP_SCREEN_OBJECT_2) == 0) {
-	xf86DrvMsg(pScrn->scrnIndex, X_ERROR, "Device is not screen object "
-		   "capable.\n");
-	goto out_depth;
-    }
-
     switch (pScrn->depth) {
     case 15:
     case 16:

commit 57d4499cc252bd1c3362a569ca7fd99ba6b645ed
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Wed Jan 20 19:08:21 2016 +0100

    vmware/vmwgfx: Disable autolayout if we detect an old resolutionset
    
    While the autolayout feature should really avoid races both with the old
    resolutionSet RandR12 code and with new compositor layout code, let's
    disable the autolayout feature if someone tries to set the
    layout / resolution through the vmwarectrl interface.
    That's most likely an old resolutionSet.
    
    Autolayout is turned on on each new screen generation.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Sinclair Yeh <syeh@vmware.com>

diff --git a/vmwgfx/vmwgfx_ctrl.c b/vmwgfx/vmwgfx_ctrl.c
index 811ca0a..5b11f37 100644
--- a/vmwgfx/vmwgfx_ctrl.c
+++ b/vmwgfx/vmwgfx_ctrl.c
@@ -121,6 +121,7 @@ VMwareCtrlDoSetRes(ScrnInfoPtr pScrn,
    rect.w = x;
    rect.h = y;
 
+   ms->autoLayout = FALSE;
    ret = vmwgfx_update_gui_layout(ms->fd, 1, &rect);
    return (ret == 0);
 }
@@ -226,6 +227,7 @@ VMwareCtrlDoSetTopology(ScrnInfoPtr pScrn,
       rects[i].h = extents[i].height;
    }
 
+   ms->autoLayout = FALSE;
    ret = vmwgfx_update_gui_layout(ms->fd, number, rects);
 
    free(rects);
diff --git a/vmwgfx/vmwgfx_driver.c b/vmwgfx/vmwgfx_driver.c
index 301cf49..693b5ef 100644
--- a/vmwgfx/vmwgfx_driver.c
+++ b/vmwgfx/vmwgfx_driver.c
@@ -1033,6 +1033,7 @@ drv_screen_init(SCREEN_INIT_ARGS_DECL)
 
     xf86SetBlackWhitePixels(pScreen);
 
+    ms->autoLayout = TRUE;
     vmw_ctrl_ext_init(pScrn);
 
     if (ms->accelerate_render) {
diff --git a/vmwgfx/vmwgfx_driver.h b/vmwgfx/vmwgfx_driver.h
index 8113b22..7c7177f 100644
--- a/vmwgfx/vmwgfx_driver.h
+++ b/vmwgfx/vmwgfx_driver.h
@@ -152,6 +152,7 @@ typedef struct _modesettingRec
     InputHandlerProc uevent_handler;
     struct vmwgfx_layout *layout;
 #endif
+    Bool autoLayout;
 } modesettingRec, *modesettingPtr;
 
 #define modesettingPTR(p) ((modesettingPtr)((p)->driverPrivate))
diff --git a/vmwgfx/vmwgfx_output.c b/vmwgfx/vmwgfx_output.c
index 03ec310..486514a 100644
--- a/vmwgfx/vmwgfx_output.c
+++ b/vmwgfx/vmwgfx_output.c
@@ -785,7 +785,8 @@ vmwgfx_handle_uevents(int fd, void *closure)
     if (pScreen)
 	RRGetInfo(pScreen, TRUE);
 
-    vmwgfx_layout_handler(scrn);
+    if (ms->autoLayout)
+	vmwgfx_layout_handler(scrn);
 
     udev_device_unref(dev);
 }

commit 48fb82f13ca290e9fbb8c7f79aba5ee119a3ce7f
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Wed Jan 20 14:21:40 2016 +0100

    vmware/vmwgfx: Read the implicit output status from KMS if available.
    
    This information is used to switch to software cursors if we have
    multiple overlapping explicit outputs and thus might need to display
    two cursors simultaneously.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Sinclair Yeh <syeh@vmware.com>

diff --git a/vmwgfx/vmwgfx_output.c b/vmwgfx/vmwgfx_output.c
index c06cd66..03ec310 100644
--- a/vmwgfx/vmwgfx_output.c
+++ b/vmwgfx/vmwgfx_output.c
@@ -73,9 +73,9 @@ struct output_private
     int num_props;
     struct output_prop *props;
     int c;
-    Bool is_implicit;
     int suggested_x;
     int suggested_y;
+    int implicit_placement;
     xf86CrtcPtr saved_crtc;
     Bool saved_crtc_enabled;
 };
@@ -134,6 +134,24 @@ vmwgfx_output_origin(xf86OutputPtr output, int *x, int *y)
 }
 
 /**
+ * vmwgfx_output_is_implicit - Whether an output uses implicit placement
+ *
+ * output: The output to consider.
+ *
+ * Returns: TRUE if the output uses implicit placement. False otherwise.
+ */
+static Bool
+vmwgfx_output_is_implicit(xf86OutputPtr output)
+{
+    struct output_private *vmwgfx_output = output->driver_private;
+
+    if (vmwgfx_output->implicit_placement == -1)
+	return TRUE;
+
+    return !!vmwgfx_output->props[vmwgfx_output->implicit_placement].value;
+}
+
+/**
  * output_property_ignore - Function to determine whether to ignore or
  * to re-export a drm property.
  *
@@ -186,6 +204,8 @@ output_create_resources(xf86OutputPtr output)
 	    vmwgfx_output->suggested_x = j;
 	if (!strcmp(drmmode_prop->name,"suggested Y"))
 	    vmwgfx_output->suggested_y = j;
+	if (!strcmp(drmmode_prop->name,"implicit_placement"))
+	    vmwgfx_output->implicit_placement = j;
 	vmwgfx_output->num_props++;
 	j++;
     }
@@ -522,7 +542,6 @@ vmwgfx_output_explicit_overlap(ScrnInfoPtr pScrn)
     RegionRec output_union;
     RegionRec cur_output;
     RegionRec result;
-    struct output_private *priv;
     xf86CrtcPtr crtc;
     Bool overlap = FALSE;
     int i;
@@ -537,10 +556,9 @@ vmwgfx_output_explicit_overlap(ScrnInfoPtr pScrn)
      */
     for (i = 0; i < config->num_output; i++) {
 	output = config->output[i];
-	priv = output->driver_private;
 	crtc = output->crtc;
 
-	if (!crtc || !crtc->enabled || !priv->is_implicit)
+	if (!crtc || !crtc->enabled || !vmwgfx_output_is_implicit(output))
 	    continue;
 
 	REGION_RESET(pScreen, &cur_output, &crtc->bounds);
@@ -552,10 +570,9 @@ vmwgfx_output_explicit_overlap(ScrnInfoPtr pScrn)
      */
     for (i = 0; i < config->num_output; i++) {
 	output = config->output[i];
-	priv = output->driver_private;
 	crtc = output->crtc;
 
-	if (!crtc || !crtc->enabled || priv->is_implicit)
+	if (!crtc || !crtc->enabled || vmwgfx_output_is_implicit(output))
 	    continue;
 
 	REGION_RESET(pScreen, &cur_output, &crtc->bounds);
@@ -594,8 +611,6 @@ xorg_output_init(ScrnInfoPtr pScrn)
     }
 
     for (c = 0; c < res->count_connectors; c++) {
-	Bool is_implicit = TRUE;
-
 	drm_connector = drmModeGetConnector(ms->fd, res->connectors[c]);
 	if (!drm_connector)
 	    goto out;
@@ -620,9 +635,9 @@ xorg_output_init(ScrnInfoPtr pScrn)
 	    continue;
 	}
 
-	priv->is_implicit = is_implicit;
 	priv->suggested_x = -1;
 	priv->suggested_y = -1;
+	priv->implicit_placement = -1;
 
 	drm_encoder = drmModeGetEncoder(ms->fd, drm_connector->encoders[0]);
 	if (drm_encoder) {

commit a81e359d88151159e3a19ceb95027029fef0a9ba
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Wed Jan 20 14:04:13 2016 +0100

    vmware/vmwgfx: Avoid filling the log with modeline printouts
    
    There are specific debug options for that.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Sinclair Yeh <syeh@vmware.com>

diff --git a/vmwgfx/vmwgfx_output.c b/vmwgfx/vmwgfx_output.c
index ddd8d5c..c06cd66 100644
--- a/vmwgfx/vmwgfx_output.c
+++ b/vmwgfx/vmwgfx_output.c
@@ -322,7 +322,6 @@ output_get_modes(xf86OutputPtr output)
 		mode->type |= M_T_DRIVER;
 	    xf86SetModeDefaultName(mode);
 	    modes = xf86ModesAdd(modes, mode);
-	    xf86PrintModeline(0, mode);
 	}
     }
 

commit 5978597da92898a424837ee89e66f66a8120480c
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Wed Jan 20 13:01:21 2016 +0100

    vmware/vmwgfx: Add a layout handler v2
    
    Add a handler that, on hotplug events, scans for a new GUI layout and
    tries to set that layout using XRandR similar to what the RandR1.2 part of
    vmware tools resolutionSet module is doing today.
    
    v2: Address review comments
    - Keep the old layout in case of screen resizing errors
    - Fix the vmwgfx_layout handler() declaration.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Sinclair Yeh <syeh@vmware.com>

diff --git a/vmwgfx/Makefile.am b/vmwgfx/Makefile.am
index 81b9e08..19533e6 100644
--- a/vmwgfx/Makefile.am
+++ b/vmwgfx/Makefile.am
@@ -30,5 +30,6 @@ libvmwgfx_la_SOURCES = \
 	vmwgfx_hosted_priv.h \
 	vmwgfx_xmir.c \
 	vmwgfx_xwayland.c \
+	vmwgfx_layout.c \
 	wsbm_util.h
 endif
diff --git a/vmwgfx/vmwgfx_driver.h b/vmwgfx/vmwgfx_driver.h
index 080ec8c..8113b22 100644
--- a/vmwgfx/vmwgfx_driver.h
+++ b/vmwgfx/vmwgfx_driver.h
@@ -88,6 +88,7 @@ enum xorg_throttling_reason {
 
 struct vmwgfx_hosted;
 struct xf86_platform_device;
+struct vmwgfx_layout;
 
 typedef struct _modesettingRec
 {
@@ -149,6 +150,7 @@ typedef struct _modesettingRec
 #ifdef HAVE_LIBUDEV
     struct udev_monitor *uevent_monitor;
     InputHandlerProc uevent_handler;
+    struct vmwgfx_layout *layout;
 #endif
 } modesettingRec, *modesettingPtr;
 
@@ -196,6 +198,24 @@ void
 vmwgfx_uevent_init(ScrnInfoPtr scrn, modesettingPtr ms);
 void
 vmwgfx_uevent_fini(ScrnInfoPtr scrn, modesettingPtr ms);
+Bool
+vmwgfx_output_has_origin(xf86OutputPtr output);
+void
+vmwgfx_output_origin(xf86OutputPtr output, int *x, int *y);
+void
+vmwgfx_outputs_off(ScrnInfoPtr pScrn);
+void
+vmwgfx_outputs_on(ScrnInfoPtr pScrn);
+
+/***********************************************************************
+ * vmwgfx_layout.c
+ */
+struct vmwgfx_layout *
+vmwgfx_layout_from_kms(ScrnInfoPtr pScrn);
+void
+vmwgfx_layout_configuration(ScrnInfoPtr pScrn, struct vmwgfx_layout *layout);
+void
+vmwgfx_layout_handler(ScrnInfoPtr pScrn);
 
 /***********************************************************************
  * xorg_xv.c
diff --git a/vmwgfx/vmwgfx_layout.c b/vmwgfx/vmwgfx_layout.c
new file mode 100644
index 0000000..2c67dd5
--- /dev/null
+++ b/vmwgfx/vmwgfx_layout.c
@@ -0,0 +1,265 @@
+/**************************************************************************
+ * Copyright © 2016 VMware, Inc., Palo Alto, CA., USA
+ * All Rights Reserved.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the
+ * "Software"), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sub license, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ *
+ * The above copyright notice and this permission notice (including the
+ * next paragraph) shall be included in all copies or substantial portions
+ * of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
+ * THE COPYRIGHT HOLDERS, AUTHORS AND/OR ITS SUPPLIERS BE LIABLE FOR ANY CLAIM,
+ * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+ * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+ * USE OR OTHER DEALINGS IN THE SOFTWARE.
+ *
+ **************************************************************************/
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#ifdef HAVE_LIBUDEV
+#include "vmwgfx_driver.h"
+#include <xf86Crtc.h>
+#include "vmwgfx_rr_inlines.h"
+
+/**
+ * struct vmwgfx_layout_box - Struct representing a GUI layout rect
+ *
+ * @x: X value of the origin.
+ * @y: Y value of the origin.
+ * @width: Width of the rect.
+ * @height: Height of the rect.
+ */
+struct vmwgfx_layout_box {
+    int x, y, width, height;
+};
+
+/**
+ * struct vmwgfx_layout - Struct representing a complete GUI layout
+ *
+ * @connected: Number of connected outputs.
+ * @root_width: Width of full desktop.
+ * @root_height: Height of full desktop.
+ * @boxes: Array of GUI layout rects.
+ */
+struct vmwgfx_layout {
+    int connected;
+    int root_width;
+    int root_height;
+    struct vmwgfx_layout_box boxes[];
+};
+
+/**
+ * vmwgfx_layout_debug - Log debug info of a layout struct.
+ *
+ * @pScrn: ScrnInfoPtr: Pointer to the ScrnInfo struct for the screen the
+ * layout should be logged for.
+ * @l1: Pointer to a valid struct vmwgfx_layout.
+ */
+static void
+vmwgfx_layout_debug(ScrnInfoPtr pScrn, const struct vmwgfx_layout *l1)
+{
+    int i;
+
+    xf86DrvMsg(pScrn->scrnIndex, X_DEBUG, "New layout.\n");
+    for (i = 0; i < l1->connected; ++i)
+	xf86DrvMsg(pScrn->scrnIndex, X_DEBUG,
+		   "%d: %d %d %d %d\n", i, l1->boxes[i].x,
+		   l1->boxes[i].y, l1->boxes[i].width, l1->boxes[i].height);
+    xf86DrvMsg(pScrn->scrnIndex, X_DEBUG, "\n");
+}
+
+/**
+ * vmwgfx_layouts_equal - Determine whether two layouts are equal.
+ *
+ * @l1: Pointer to the first struct vmwgfx_layout.
+ * @l2: Pointer to the second struct vmwgfx_layout.
+ *
+ * Returns: TRUE if the layouts are equal. FALSE otherwise.
+ */
+static Bool
+vmwgfx_layouts_equal(const struct vmwgfx_layout *l1,
+		     const struct vmwgfx_layout *l2)
+{
+    if (l1->connected != l2->connected)
+	return FALSE;
+
+    if (!l1->connected)
+	return TRUE;
+
+    return !memcmp(l1->boxes, l2->boxes,
+		   l1->connected*sizeof(struct vmwgfx_layout_box));
+}
+
+/**
+ * vmwgfx_layout_from_kms - Construct a struct vmwgfx_layout from KMS info.
+ *
+ * @pScrn: Pointer to a ScrnInfo struct.
+ *
+ * Returns: A pointer to a newly allocated struct vmwgfx_layout if
+ * successful. NULL otherwise.
+ */
+struct vmwgfx_layout *
+vmwgfx_layout_from_kms(ScrnInfoPtr pScrn)
+{
+    xf86CrtcConfigPtr config = XF86_CRTC_CONFIG_PTR(pScrn);
+    int i, connected;
+    struct vmwgfx_layout *layout;
+    size_t size;
+    int min_x = INT_MAX, max_x = INT_MIN, min_y = INT_MAX, max_y = INT_MIN;
+
+    for (i = 0; i < config->num_output; ++i) {
+	xf86OutputPtr output = config->output[i];
+
+	if (!vmwgfx_output_has_origin(output))
+	    return NULL;
+
+	if (output->status != XF86OutputStatusConnected)
+	    break;
+    }
+    connected = i;
+
+    size = offsetof(struct vmwgfx_layout, boxes) +
+	connected * sizeof(struct vmwgfx_layout_box);
+    layout = calloc(1, size);
+    if (!layout)
+	return NULL;


Reply to: