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

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



 ChangeLog                  |  381 +++++++++++++++++++++++++++++++++++++++++++++
 configure.ac               |    2 
 debian/changelog           |    7 
 debian/control             |    2 
 saa/saa.c                  |    2 
 saa/saa_unaccel.c          |   44 +++--
 src/vmware.c               |    8 
 src/vmware_bootstrap.c     |   62 ++++++-
 src/vmwarevideo.c          |   16 +
 vmwgfx/vmwgfx_crtc.c       |   22 ++
 vmwgfx/vmwgfx_driver.c     |   37 +++-
 vmwgfx/vmwgfx_driver.h     |    2 
 vmwgfx/vmwgfx_overlay.c    |   29 ++-
 vmwgfx/vmwgfx_saa.c        |   17 +-
 vmwgfx/vmwgfx_saa_priv.h   |   11 +
 vmwgfx/vmwgfx_xa_surface.c |   61 ++++++-
 vmwgfx/vmwgfx_xmir.c       |    6 
 vmwgfx/vmwgfx_xwayland.c   |    2 
 18 files changed, 655 insertions(+), 56 deletions(-)

New commits:
commit 6e7d85c60f8182af995a4aa554fdbafddd698f90
Author: Maarten Lankhorst <maarten.lankhorst@ubuntu.com>
Date:   Tue Jan 20 12:48:07 2015 +0100

    New upstream release.
    
    Bump Standards-Version to 3.9.6 (no changes needed).

diff --git a/ChangeLog b/ChangeLog
index f19a6ea..8bfe3ed 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,384 @@
+commit 891ee48e4c1baa2643eda048b4207f8263a37dca
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Mon Jan 19 11:23:50 2015 +0100
+
+    vmware: Bump version number for release
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+
+commit 79289b0ffc553ded902eea7b8b9803b098f340e3
+Author: Adam Jackson <ajax@redhat.com>
+Date:   Thu Dec 4 10:35:04 2014 -0500
+
+    saa: Adapt to GC client clip changes in xserver 1.17
+    
+    1.17 always stores the client clip as a region, so there's no longer a
+    clientClipType member to look at.  Change the code to just inspect
+    whether the clientClip is non-null, since that works both before and
+    after 1.17.
+    
+    Signed-off-by: Adam Jackson <ajax@redhat.com>
+    Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>
+
+commit 4664412d7a5266d2b392957406b34abc5db95e48
+Author: Stefan Dirsch <sndirsch@suse.de>
+Date:   Tue Oct 7 11:29:32 2014 +0200
+
+    xf86xv.h cannot be included without first including xorg-server.h.
+    
+    Without this the build fails on systems with the latest glibc,
+    throwing this error:
+    
+    In file included from /usr/include/string.h:634:0,
+                     from /usr/include/xorg/os.h:53,
+                     from /usr/include/xorg/misc.h:115,
+                     from /usr/include/xorg/screenint.h:50,
+                     from /usr/include/xorg/scrnintstr.h:50,
+                     from /usr/include/xorg/xvdix.h:55,
+                     from /usr/include/xorg/xf86xv.h:32,
+                     from vmwgfx_overlay.c:38:
+    /usr/include/xorg/os.h:579:1: error: expected identifier or '(' before '__extension__'
+    strndup(const char *str, size_t n);
+    
+    This is caused by HAVE_STRNDUP not being set (it is set from xorg-server.h),
+    causing os.h to redefine it.
+    
+    Signed-off-by: Stefan Dirsch <sndirsch@suse.de>
+    Reviewed-by: Daniel Stone <daniels@collabora.com>
+    Acked-by: Thomas Hellstrom <thellstrom@vmware.com>
+
+commit 8e1c4e5bd521ec2d4f1a21da432f110c606b3fde
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Mon Sep 22 12:09:13 2014 +0200
+
+    vmware/saa: Fix saa_check_poly_fill_rect_noreadback v2
+    
+    We were not clipping the dirty region correctly, Fix this.
+    Also actually do what the comment in the function says: If there are more than
+    an ad-hoc number of rectangles to read back, then revert to the default
+    saa_check_poly_fill_rect function that reads back the whole damage region.
+    
+    v2: Fix commit log message.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Brian Paul <brianp@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit c23fd33d8ce8491891255d93c04e053bf333bd4e
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Mon Sep 22 11:43:02 2014 +0200
+
+    vmware/saa: Fix saa_check_copy_window dirty region v3
+    
+    The saa_check_copy_window could dirty regions that were never touched, since
+    we were using the X server provided damage region rather than the more
+    detailed region actually copied. This would have been OK if we had first done
+    a read-back of the region to be dirtied, but since we want to avoid that,
+    instead compute the detailed destination region and use that for dirtying.
+    
+    This fixes rendering glitches seen with motif applications.
+    
+    v2: Fix whitespace error.
+    v3: Move dirty region computation.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Brian Paul <brianp@vmware.com>
+    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit f86434ac69bd288c7fba65d178c22a91a0f4f6c2
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Mon Sep 15 15:13:53 2014 +0200
+
+    Revert "vmware/saa: Disable the noreadback polyfillrect optimization"
+    
+    This reverts commit 88c487cb19aaf2882d582f7f887a52935ef8d92e.
+    
+    While the commit made the rendering artefacts less frequent, they didn't
+    disappear completely and are likely caused by something else, so revert this
+    commit.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Acked-by: Sinclair Yeh <syeh@vmware.com>
+
+commit 8545a166931617af0d2a9ca8175fd8b11c67e246
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Tue Sep 9 01:59:07 2014 -0700
+
+    vmware/vmwgfx: Fix cursor problem with multimon
+    
+    In a multimon environment, the cursor would sometimes disappear on the
+    newly enabled screen. Fix this.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit 32562129750077a23f26f2e69adc8403eb24bf3f
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Sep 3 07:08:41 2014 -0700
+
+    vmware/vmwgfx: Don't add pixmaps to the pixmap list if they're already on it
+    
+    This could cause loops through the list to spin indefinitely.
+    This would most likely occur at VT switches.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit 8b6316a312689d83ca8f8de939698bc137206f58
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Thu Aug 28 15:32:45 2014 +0200
+
+    vmware/legacy: Fix overlay related compile breakage on earlier X servers
+    
+    Introduced by commit:
+    vmware/legacy: Apply same fix to auto colrkey fill
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit 8a47e9a45036005d46a60cf8df366baffcb9a8d1
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Thu Aug 28 13:43:03 2014 +0200
+
+    vmware: Fix bootstrap related compile errors on earlier X servers
+    
+    Introduced by commit
+    Add support for XSERVER_PLATFORM_BUS
+    
+    Note that the vmware DriverRec declaration can be cleaned up
+    considerably using C99 designated initializers. Perhaps something for
+    the next release...
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit f5d8c8f1fe2de727018600f471b6a8829fe492ad
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Aug 20 13:02:58 2014 +0200
+
+    vmware: Clear the PITCHLOCK register if available before modeset
+    
+    In some situations the fbdev driver may have set this register before legacy
+    driver startup causing a weird-looking desktop. Make sure this register
+    is cleared on each modeset.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit b1697434348799b0808a6c9e9a899394075b980c
+Author: Jakob Bornecrantz <jakob@vmware.com>
+Date:   Thu Aug 14 16:42:05 2014 +0200
+
+    vmware/legacy: Fix out of bound array indexing
+    
+    Spotted by coverity.
+    
+    Reported-by: Adam Jackson <ajax@redhat.com>
+    Reviewed-by: Adam Jackson <ajax@redhat.com>
+    Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit 0825d98744b20a20af7bd81d347334ab4a1de015
+Author: Jakob Bornecrantz <jakob@vmware.com>
+Date:   Sat Aug 9 00:19:17 2014 +0200
+
+    vmware/vmwgfx: Fix compilation issue on older X servers
+    
+    Introduced in 268307 "Add support for server managed fds"
+    
+    Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
+    Reviewed-by: Brian Paul <brianp@vmware.com>
+
+commit 0a212afefd8670a1823c9b6474de8bf26d33bdeb
+Author: Jakob Bornecrantz <jakob@vmware.com>
+Date:   Fri Aug 8 21:37:38 2014 +0200
+
+    vmware/legacy: Fix uninitialized values in video commands
+    
+    Fixed bug where video stopped working on systems that didn't have the new kms
+    enabled kernel driver installed. Found on CentOS 6.4.
+    
+    After updating the register header SVGA_VIDEO_NUM_REGS value got upped by two
+    in order to support GMR and Screen Objects. Since this path is mostly used
+    on older hosts that may not support them, don't send them at all.
+    
+    Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
+    Reviewed-by: Brian Paul <brianp@vmware.com>
+
+commit 0a596fd0c92fdcf73071869a59029263a2596018
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Jul 2 14:21:45 2014 +0200
+
+    vmware/vmwgfx: Fix an error path segfault
+    
+    Part of freedesktop.org bugzilla bug #80645
+    If taking a scanout reference on a pixmap fails, the
+    struct vmwgfx_screen_entry::pixmap pointer must be set to NULL, otherwise
+    the driver will incorrectly attempt to remove the scanout reference in the
+    error path, causing a segfault.
+    
+    This problem is seen in the above-mentioned bug, but it is not the root
+    cause of the problem. With this patch applied, the server will terminate
+    cleanly instead of segfaulting.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit 4e378a730d2d2deffc915af2a3d013d2a994a1b0
+Author: Jakob Bornecrantz <jakob@vmware.com>
+Date:   Wed May 21 11:52:29 2014 +0200
+
+    vmware/legacy: Apply same fix to auto colorkey fill
+    
+    Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
+    Reviewed-by: Thomas Hellström <thellstrom@vmware.com>
+
+commit 82c9b0c1d34459c568d004521e3f35a69f5d7ae3
+Author: Jakob Bornecrantz <jakob@vmware.com>
+Date:   Wed May 21 11:51:46 2014 +0200
+
+    vmware/vmwgfx: Fix auto colorkey fill usage
+    
+    Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
+    Reviewed-by: Thomas Hellström <thellstrom@vmware.com>
+
+commit 43e043868fbd74e28cd392a3665b36abdfe87de0
+Author: Jakob Bornecrantz <jakob@vmware.com>
+Date:   Wed May 21 11:54:48 2014 +0200
+
+    vmware/vmwgfx: A bit more error logging when handling cursors
+    
+    Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
+    Reviewed-by: Thomas Hellström <thellstrom@vmware.com>
+
+commit aa7309254808e27a4ac5d3dc674be179646280b5
+Author: Jakob Bornecrantz <jakob@vmware.com>
+Date:   Wed May 21 11:54:24 2014 +0200
+
+    vmware/vmwgfx: Don't move cursors without images
+    
+    Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
+    Reviewed-by: Thomas Hellström <thellstrom@vmware.com>
+
+commit e8d6facf34adf1c601a3afd0a984ce90ad8fe059
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Tue May 20 06:29:19 2014 -0700
+
+    vmware/vmwgfx: Fix xwayland build on newer XA versions
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit 268307e85c06be27345a6808bcf2b3c9887bf8bc
+Author: Hans de Goede <hdegoede@redhat.com>
+Date:   Tue May 6 16:33:21 2014 +0200
+
+    Add support for server managed fds
+    
+    Signed-off-by: Hans de Goede <hdegoede@redhat.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit 675fe58eee8acdb302c3501236b86a3289991053
+Author: Hans de Goede <hdegoede@redhat.com>
+Date:   Tue May 6 16:00:50 2014 +0200
+
+    Add support for XSERVER_PLATFORM_BUS
+    
+    This is a preparation patch for adding support for server managed fds.
+    
+    Signed-off-by: Hans de Goede <hdegoede@redhat.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit 88c487cb19aaf2882d582f7f887a52935ef8d92e
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Fri May 9 09:35:59 2014 +0200
+
+    vmware/saa: Disable the noreadback polyfillrect optimization
+    
+    It causes rendering artefacts with some motif applications due to
+    damage area confusion. Until that is sorted out, temporarily disable the
+    optimization.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit f31eed4a578784329a7038aa01acaa10a2d0c246
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Thu May 8 09:24:04 2014 +0200
+
+    vmware/vmwgfx: Fix initial dirty region for pixmaps
+    
+    When storage is attached to pixmaps for the first time the dirty region is
+    set to cover either the hardware surface or the software buffer based on
+    the presence of the hardware surface.
+    
+    However, if the storage was created as part of an accelerated operation,
+    the dirty region was assigned before the hardware surface was assigned to the
+    pixmap, causing the dirty region to incorrectly cover the software buffer.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit 1ed14687a3f1092db8504fb9cf4f446451801665
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Thu Apr 10 14:05:24 2014 +0200
+
+    vmware/vmwgfx: Set desired modes after xMir screen init
+    
+    While XMir does initial mode configuration, it leaves setting initial
+    modes to the DDX driver.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Brian Paul <brianp@vmware.com>
+
+commit 64e0faf1480663a990e0f6aeef7af0e69845af49
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Wed Apr 2 14:05:23 2014 +0200
+
+    vmware/vmwgfx: Don't tell XA that we have a mask when we haven't
+    
+    In some cases, the X server sends us a composit operation with
+    mask_pict != NULL, but mask_pix == NULL. Assume there's no mask
+    involved in that case.
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Brian Paul <brianp@vmware.com>
+
+commit c062d08a50a26c99a3b8f565a8b2b00e8dc21c3f
+Author: Thomas Hellstrom <thellstrom@vmware.com>
+Date:   Thu Jan 16 18:27:57 2014 +0100
+
+    vmware/vmwgfx: Don't change backing-store of active scanout surfaces
+    
+    With option "HwPresents" on, the driver would sometimes change backing
+    store of active scanout surfaces, making the kernel module refuse to
+    present. This was caused by scanout surfaces not having the RENDERTARGET flag
+    on by default. So when rendered to, using copies or composites, they
+    would be reallocated. Fix this by adding the RENDERTARGET flag from start.
+    
+    Also add code that prints out an error message when we change backing store
+    of active scanout surfaces
+    
+    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+
+commit c42e1f750629f18144d065b8bba5e2eaf6cbf675
+Author: Julien Cristau <jcristau@debian.org>
+Date:   Tue Apr 1 10:11:13 2014 +0200
+
+    configure: fix build without xatracker
+    
+    ACTION-IF-NOT-FOUND is the fourth argument to PKG_CHECK_MODULES, not the
+    fifth.
+    
+    Debian bug#743239 <https://bugs.debian.org/743239>
+    
+    Reviewed-by: Thomas Klausner <wiz@NetBSD.org>
+    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
+    Signed-off-by: Julien Cristau <jcristau@debian.org>
+    Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
+
 commit cbd56b3759f01ec18ae0705d023e4c0b2ab38c25
 Author: Jakob Bornecrantz <jakob@vmware.com>
 Date:   Wed Mar 26 12:45:52 2014 +0100
diff --git a/debian/changelog b/debian/changelog
index 62a7de6..357d281 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+xserver-xorg-video-vmware (1:13.1.0-1) UNRELEASED; urgency=medium
+
+  * New upstream release.
+  * Bump Standards-Version to 3.9.6 (no changes needed).
+
+ -- Maarten Lankhorst <maarten.lankhorst@ubuntu.com>  Tue, 20 Jan 2015 11:21:26 +0100
+
 xserver-xorg-video-vmware (1:13.0.2-3) unstable; urgency=medium
 
   * rules: avoid mixing implicit and normal rules; make 4 doesn't like that
diff --git a/debian/control b/debian/control
index cf23096..e973fdd 100644
--- a/debian/control
+++ b/debian/control
@@ -20,7 +20,7 @@ Build-Depends:
  libxext-dev,
  libx11-dev,
  libxatracker-dev [linux-any],
-Standards-Version: 3.9.1
+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
 

commit 891ee48e4c1baa2643eda048b4207f8263a37dca
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Mon Jan 19 11:23:50 2015 +0100

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

diff --git a/configure.ac b/configure.ac
index be40ed7..97f2f85 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.1.0],
         [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
         [xf86-video-vmware])
 AC_CONFIG_SRCDIR([Makefile.am])

commit 79289b0ffc553ded902eea7b8b9803b098f340e3
Author: Adam Jackson <ajax@redhat.com>
Date:   Thu Dec 4 10:35:04 2014 -0500

    saa: Adapt to GC client clip changes in xserver 1.17
    
    1.17 always stores the client clip as a region, so there's no longer a
    clientClipType member to look at.  Change the code to just inspect
    whether the clientClip is non-null, since that works both before and
    after 1.17.
    
    Signed-off-by: Adam Jackson <ajax@redhat.com>
    Reviewed-by: Thomas Hellstrom <thellstrom@vmware.com>

diff --git a/saa/saa.c b/saa/saa.c
index f2d68e9..be9520e 100644
--- a/saa/saa.c
+++ b/saa/saa.c
@@ -349,7 +349,7 @@ saa_gc_reads_destination(DrawablePtr pDrawable, GCPtr pGC)
 {
     return ((pGC->alu != GXcopy && pGC->alu != GXclear && pGC->alu != GXset &&
 	     pGC->alu != GXcopyInverted) || pGC->fillStyle == FillStippled ||
-	    pGC->clientClipType != CT_NONE ||
+	    pGC->clientClip != NULL ||
 	    !SAA_PM_IS_SOLID(pDrawable, pGC->planemask));
 }
 

commit 4664412d7a5266d2b392957406b34abc5db95e48
Author: Stefan Dirsch <sndirsch@suse.de>
Date:   Tue Oct 7 11:29:32 2014 +0200

    xf86xv.h cannot be included without first including xorg-server.h.
    
    Without this the build fails on systems with the latest glibc,
    throwing this error:
    
    In file included from /usr/include/string.h:634:0,
                     from /usr/include/xorg/os.h:53,
                     from /usr/include/xorg/misc.h:115,
                     from /usr/include/xorg/screenint.h:50,
                     from /usr/include/xorg/scrnintstr.h:50,
                     from /usr/include/xorg/xvdix.h:55,
                     from /usr/include/xorg/xf86xv.h:32,
                     from vmwgfx_overlay.c:38:
    /usr/include/xorg/os.h:579:1: error: expected identifier or '(' before '__extension__'
    strndup(const char *str, size_t n);
    
    This is caused by HAVE_STRNDUP not being set (it is set from xorg-server.h),
    causing os.h to redefine it.
    
    Signed-off-by: Stefan Dirsch <sndirsch@suse.de>
    Reviewed-by: Daniel Stone <daniels@collabora.com>
    Acked-by: Thomas Hellstrom <thellstrom@vmware.com>

diff --git a/vmwgfx/vmwgfx_overlay.c b/vmwgfx/vmwgfx_overlay.c
index ef1d541..2b05b0e 100644
--- a/vmwgfx/vmwgfx_overlay.c
+++ b/vmwgfx/vmwgfx_overlay.c
@@ -35,6 +35,7 @@
  */
 
 
+#include "xorg-server.h"
 #include "xf86xv.h"
 #include "fourcc.h"
 #define debug_printf(...)

commit 8e1c4e5bd521ec2d4f1a21da432f110c606b3fde
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Mon Sep 22 12:09:13 2014 +0200

    vmware/saa: Fix saa_check_poly_fill_rect_noreadback v2
    
    We were not clipping the dirty region correctly, Fix this.
    Also actually do what the comment in the function says: If there are more than
    an ad-hoc number of rectangles to read back, then revert to the default
    saa_check_poly_fill_rect function that reads back the whole damage region.
    
    v2: Fix commit log message.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Brian Paul <brianp@vmware.com>
    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>

diff --git a/saa/saa_unaccel.c b/saa/saa_unaccel.c
index 08a64b0..cff0587 100644
--- a/saa/saa_unaccel.c
+++ b/saa/saa_unaccel.c
@@ -421,17 +421,20 @@ saa_check_poly_fill_rect_noreadback(DrawablePtr pDrawable, GCPtr pGC,
     if (!region)
 	goto out_no_region;
 
-    REGION_TRANSLATE(pGC->pScreen, region, xoff + pDrawable->x,
-		     yoff + pDrawable->y);
-
+    REGION_TRANSLATE(pGC->pScreen, region, pDrawable->x, pDrawable->y);
+    REGION_INTERSECT(pGC->pScreen, region, fbGetCompositeClip(pGC), region);
+    REGION_TRANSLATE(pGC->pScreen, region, xoff, yoff);
 
     access = SAA_ACCESS_W;
     if (saa_gc_reads_destination(pDrawable, pGC)) {
 	/*
 	 * We need to do a readback anyway. In case of more than an
-	 * ad hoc number of say 10 rectangles, we might as well do a
+	 * ad hoc number of say 4 rectangles, we might as well do a
 	 * readback of the whole damage area to avoid fragmentation.
 	 */
+	if (REGION_NUM_RECTS(region) > 4)
+	    goto out_no_access;
+
 	access |= SAA_ACCESS_R;
 	ret = saa_prepare_access_pixmap(pPixmap, access, region);
     } else
@@ -451,13 +454,8 @@ saa_check_poly_fill_rect_noreadback(DrawablePtr pDrawable, GCPtr pGC,
     saa_finish_access_pixmap(pPixmap, access);
 
     if (spix->damage) {
-	/*
-	 * Not sure why the region can be larger than the pending damage region
-	 * at this point, (happens on clipped-away drawables). To avoid potential
-	 * rendering problems, we clip to the pending damage region.
-	 */
-	REGION_INTERSECT(pGC->pScreen, region, region, saa_pix_damage_pending(spix));
-
+	REGION_INTERSECT(pGC->pScreen, region, region,
+			 saa_pix_damage_pending(spix));
 	saa_pixmap_dirty(pPixmap, FALSE, region);
     }
 

commit c23fd33d8ce8491891255d93c04e053bf333bd4e
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Mon Sep 22 11:43:02 2014 +0200

    vmware/saa: Fix saa_check_copy_window dirty region v3
    
    The saa_check_copy_window could dirty regions that were never touched, since
    we were using the X server provided damage region rather than the more
    detailed region actually copied. This would have been OK if we had first done
    a read-back of the region to be dirtied, but since we want to avoid that,
    instead compute the detailed destination region and use that for dirtying.
    
    This fixes rendering glitches seen with motif applications.
    
    v2: Fix whitespace error.
    v3: Move dirty region computation.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Brian Paul <brianp@vmware.com>
    Reviewed-by: Sinclair Yeh <syeh@vmware.com>
    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>

diff --git a/saa/saa_unaccel.c b/saa/saa_unaccel.c
index e2bf3ac..08a64b0 100644
--- a/saa/saa_unaccel.c
+++ b/saa/saa_unaccel.c
@@ -617,10 +617,32 @@ saa_check_copy_window(WindowPtr pWin, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
 	goto out_no_access;;
 
     if (saa_prepare_access_pixmap(pPixmap, SAA_ACCESS_W, NULL)) {
+	struct saa_pixmap *spix;
+	RegionRec rgnDst;
+
+	REGION_NULL(pScreen, &rgnDst);
+	REGION_COPY(pScreen, &rgnDst, prgnSrc);
+
 	saa_swap(sscreen, pScreen, CopyWindow);
 	pScreen->CopyWindow(pWin, ptOldOrg, prgnSrc);
 	saa_swap(sscreen, pScreen, CopyWindow);
-	saa_fad_write(pDrawable, SAA_ACCESS_W);
+	saa_finish_access_pixmap(pPixmap, SAA_ACCESS_W);
+
+	spix = saa_get_saa_pixmap(pPixmap);
+	if (spix->damage) {
+	    int dx, dy;
+
+	    dx = ptOldOrg.x - pWin->drawable.x;
+	    dy = ptOldOrg.y - pWin->drawable.y;
+	    REGION_TRANSLATE(pScreen, &rgnDst, -dx, -dy);
+	    REGION_INTERSECT(pSreen, &rgnDst, &pWin->borderClip, &rgnDst);
+	    REGION_TRANSLATE(pScreen, &rgnDst, xoff, yoff);
+
+	    REGION_INTERSECT(pScreen, &rgnDst, &rgnDst,
+			     saa_pix_damage_pending(spix));
+	    saa_pixmap_dirty(pPixmap, FALSE, &rgnDst);
+	}
+	REGION_UNINIT(pScreen, &rgnDst);
     }
     saa_fad_read(pDrawable);
  out_no_access:

commit f86434ac69bd288c7fba65d178c22a91a0f4f6c2
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Mon Sep 15 15:13:53 2014 +0200

    Revert "vmware/saa: Disable the noreadback polyfillrect optimization"
    
    This reverts commit 88c487cb19aaf2882d582f7f887a52935ef8d92e.
    
    While the commit made the rendering artefacts less frequent, they didn't
    disappear completely and are likely caused by something else, so revert this
    commit.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Acked-by: Sinclair Yeh <syeh@vmware.com>

diff --git a/saa/saa_unaccel.c b/saa/saa_unaccel.c
index deaeb8b..e2bf3ac 100644
--- a/saa/saa_unaccel.c
+++ b/saa/saa_unaccel.c
@@ -396,7 +396,6 @@ saa_check_poly_arc(DrawablePtr pDrawable, GCPtr pGC, int narcs, xArc * pArcs)
  * region fragmentation. In any case, this greatly improves on the performance of
  * shaped windows on top of accelerated contents, for example unscaled OSD in xine.
  */
-#if 0
 static Bool
 saa_check_poly_fill_rect_noreadback(DrawablePtr pDrawable, GCPtr pGC,
 				    int nrect, xRectangle *prect)
@@ -477,7 +476,7 @@ saa_check_poly_fill_rect_noreadback(DrawablePtr pDrawable, GCPtr pGC,
 
     return FALSE;
 }
-#endif
+
 void
 saa_check_poly_fill_rect(DrawablePtr pDrawable, GCPtr pGC,
 			 int nrect, xRectangle * prect)
@@ -488,17 +487,8 @@ saa_check_poly_fill_rect(DrawablePtr pDrawable, GCPtr pGC,
 
     SAA_FALLBACK(("to %p (%c)\n", pDrawable, saa_drawable_loc(pDrawable)));
 
-
-    /*
-     * Disable saa_check_poly_fill_rect_noreadback as it causes rendering
-     * artefacts with some motif applications. There seems to be some
-     * confusion with the damage area.
-     */
-
-#if 0
     if (saa_check_poly_fill_rect_noreadback(pDrawable, pGC, nrect, prect))
 	return;
-#endif
 
     sscreen->fallback_count++;
 

commit 8545a166931617af0d2a9ca8175fd8b11c67e246
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Tue Sep 9 01:59:07 2014 -0700

    vmware/vmwgfx: Fix cursor problem with multimon
    
    In a multimon environment, the cursor would sometimes disappear on the
    newly enabled screen. Fix this.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>

diff --git a/vmwgfx/vmwgfx_crtc.c b/vmwgfx/vmwgfx_crtc.c
index 4f9cdda..dad8815 100644
--- a/vmwgfx/vmwgfx_crtc.c
+++ b/vmwgfx/vmwgfx_crtc.c
@@ -213,6 +213,15 @@ crtc_set_mode_major(xf86CrtcPtr crtc, DisplayModePtr mode,
     crtc->active = TRUE;
 #endif
 
+    /*
+     * Strictly, this needs to be done only once per configuration change,
+     * not once per crtc, but there's no better place to put this. Since
+     * Intel wrote the crtc code, let's do what the xf86-video-intel driver
+     * does.
+     */
+    if (pScreen)
+	xf86_reload_cursors(pScreen);
+
     return TRUE;
 }
 

commit 32562129750077a23f26f2e69adc8403eb24bf3f
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Wed Sep 3 07:08:41 2014 -0700

    vmware/vmwgfx: Don't add pixmaps to the pixmap list if they're already on it
    
    This could cause loops through the list to spin indefinitely.
    This would most likely occur at VT switches.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>

diff --git a/vmwgfx/vmwgfx_saa.c b/vmwgfx/vmwgfx_saa.c
index b9204c6..bca3d93 100644
--- a/vmwgfx/vmwgfx_saa.c
+++ b/vmwgfx/vmwgfx_saa.c
@@ -694,7 +694,8 @@ vmwgfx_modify_pixmap_header (PixmapPtr pixmap, int w, int h, int depth,
 
     vmwgfx_pix_resize(pixmap, old_pitch, old_height, old_width);
     vmwgfx_pixmap_free_storage(vpix);
-    WSBMLISTADDTAIL(&vpix->pixmap_list, &vsaa->pixmaps);
+    if (WSBMLISTEMPTY(&vpix->pixmap_list))
+	WSBMLISTADDTAIL(&vpix->pixmap_list, &vsaa->pixmaps);
 
     return TRUE;
 

commit 8b6316a312689d83ca8f8de939698bc137206f58
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Thu Aug 28 15:32:45 2014 +0200

    vmware/legacy: Fix overlay related compile breakage on earlier X servers
    
    Introduced by commit:
    vmware/legacy: Apply same fix to auto colrkey fill
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>

diff --git a/src/vmwarevideo.c b/src/vmwarevideo.c
index 816f1ca..634af69 100644
--- a/src/vmwarevideo.c
+++ b/src/vmwarevideo.c
@@ -58,6 +58,10 @@
      ((GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) == 1) && \
       (GET_ABI_MINOR(ABI_VIDEODRV_VERSION) >= 2)))
 
+#if HAVE_FILLKEYHELPERDRAWABLE
+#include <damage.h>
+#endif
+
 #define MAKE_ATOM(a) MakeAtom(a, sizeof(a) - 1, TRUE)
 
 /*

commit 8a47e9a45036005d46a60cf8df366baffcb9a8d1
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Thu Aug 28 13:43:03 2014 +0200

    vmware: Fix bootstrap related compile errors on earlier X servers
    
    Introduced by commit
    Add support for XSERVER_PLATFORM_BUS
    
    Note that the vmware DriverRec declaration can be cleaned up
    considerably using C99 designated initializers. Perhaps something for
    the next release...
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>

diff --git a/src/vmware_bootstrap.c b/src/vmware_bootstrap.c
index 1635876..d7ab070 100644
--- a/src/vmware_bootstrap.c
+++ b/src/vmware_bootstrap.c
@@ -30,7 +30,6 @@
 #endif
 
 #include "xf86.h"
-#include <xorgVersion.h>
 #include "compiler.h"
 #include "xf86Pci.h"		/* pci */
 #include "vm_device_version.h"
@@ -497,7 +496,7 @@ VMWareDriverFunc(ScrnInfoPtr pScrn,
 			      pScrn->yDpi / 2) / pScrn->yDpi;
       }
       return TRUE;
-#if XORG_VERSION_CURRENT >= XORG_VERSION_NUMERIC(1,15,99,902,0)
+#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) >= 18
    case SUPPORTS_SERVER_FDS:
       return TRUE;
 #endif
@@ -523,6 +522,7 @@ _X_EXPORT DriverRec vmware = {
 #if VMWARE_DRIVER_FUNC
     VMWareDriverFunc,
 #endif
+#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) >= 4
 #if XSERVER_LIBPCIACCESS
     VMwareDeviceMatch,
     VMwarePciProbe,
@@ -530,11 +530,14 @@ _X_EXPORT DriverRec vmware = {
     NULL,
     NULL,
 #endif
+#endif
+#if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) >= 13
 #ifdef XSERVER_PLATFORM_BUS
     VMwarePlatformProbe,
 #else
     NULL,
 #endif
+#endif
 };
 
 

commit f5d8c8f1fe2de727018600f471b6a8829fe492ad
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Wed Aug 20 13:02:58 2014 +0200

    vmware: Clear the PITCHLOCK register if available before modeset
    
    In some situations the fbdev driver may have set this register before legacy
    driver startup causing a weird-looking desktop. Make sure this register
    is cleared on each modeset.
    
    Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
    Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>

diff --git a/src/vmware.c b/src/vmware.c
index 17434ab..12f12ed 100644
--- a/src/vmware.c
+++ b/src/vmware.c
@@ -375,7 +375,8 @@ VMWAREPreInit(ScrnInfoPtr pScrn, int flags)
 #ifdef ACCELERATE_OPS
     pVMWARE->vmwareCapability = vmwareReadReg(pVMWARE, SVGA_REG_CAPABILITIES);
 #else
-    pVMWARE->vmwareCapability = 0;
+    pVMWARE->vmwareCapability = vmwareReadReg(pVMWARE, SVGA_REG_CAPABILITIES) &
+	SVGA_CAP_PITCHLOCK;
 #endif
 
     pVMWARE->bitsPerPixel = vmwareReadReg(pVMWARE,
@@ -858,6 +859,8 @@ VMWAREModeInit(ScrnInfoPtr pScrn, DisplayModePtr mode, Bool rebuildPixmap)
         return FALSE;
     pScrn->vtSema = TRUE;
 
+    if (pVMWARE->vmwareCapability & SVGA_CAP_PITCHLOCK)
+	vmwareWriteReg(pVMWARE, SVGA_REG_PITCHLOCK, 0);
     vmwareReg->svga_reg_enable = 1;
     vmwareReg->svga_reg_width = max(mode->HDisplay, pScrn->virtualX);
     vmwareReg->svga_reg_height = max(mode->VDisplay, pScrn->virtualY);

commit b1697434348799b0808a6c9e9a899394075b980c
Author: Jakob Bornecrantz <jakob@vmware.com>
Date:   Thu Aug 14 16:42:05 2014 +0200

    vmware/legacy: Fix out of bound array indexing
    
    Spotted by coverity.
    
    Reported-by: Adam Jackson <ajax@redhat.com>
    Reviewed-by: Adam Jackson <ajax@redhat.com>
    Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>

diff --git a/src/vmwarevideo.c b/src/vmwarevideo.c
index 261e579..816f1ca 100644
--- a/src/vmwarevideo.c
+++ b/src/vmwarevideo.c
@@ -837,7 +837,7 @@ vmwareVideoPlay(ScrnInfoPtr pScrn, VMWAREVideoPtr pVid,
     cmdSetRegs.body.streamId = pVid->streamId;
 
     items = cmdSetRegs.body.items;
-    for (i = SVGA_VIDEO_ENABLED; i < SVGA_VIDEO_NUM_REGS; i++) {
+    for (i = SVGA_VIDEO_ENABLED; i < SVGA_VIDEO_DATA_GMRID; i++) {
         items[i].regId = i;
     }
 

commit 0825d98744b20a20af7bd81d347334ab4a1de015
Author: Jakob Bornecrantz <jakob@vmware.com>
Date:   Sat Aug 9 00:19:17 2014 +0200

    vmware/vmwgfx: Fix compilation issue on older X servers
    
    Introduced in 268307 "Add support for server managed fds"
    
    Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
    Reviewed-by: Brian Paul <brianp@vmware.com>

diff --git a/vmwgfx/vmwgfx_driver.c b/vmwgfx/vmwgfx_driver.c
index 03103a8..2925227 100644
--- a/vmwgfx/vmwgfx_driver.c
+++ b/vmwgfx/vmwgfx_driver.c
@@ -491,8 +491,10 @@ drv_pre_init(ScrnInfoPtr pScrn, int flags)
 	goto out_err_bus;
     }
 
+#ifdef XSERVER_PLATFORM_BUS
     if (pEnt->location.type == BUS_PLATFORM)
         ms->platform_dev = pEnt->location.id.plat;
+#endif
 
     xf86SetPrimInitDone(pScrn->entityList[0]);
 

commit 0a212afefd8670a1823c9b6474de8bf26d33bdeb
Author: Jakob Bornecrantz <jakob@vmware.com>
Date:   Fri Aug 8 21:37:38 2014 +0200

    vmware/legacy: Fix uninitialized values in video commands
    
    Fixed bug where video stopped working on systems that didn't have the new kms
    enabled kernel driver installed. Found on CentOS 6.4.
    
    After updating the register header SVGA_VIDEO_NUM_REGS value got upped by two
    in order to support GMR and Screen Objects. Since this path is mostly used
    on older hosts that may not support them, don't send them at all.
    
    Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
    Reviewed-by: Brian Paul <brianp@vmware.com>

diff --git a/src/vmwarevideo.c b/src/vmwarevideo.c
index a82110d..261e579 100644
--- a/src/vmwarevideo.c
+++ b/src/vmwarevideo.c
@@ -794,7 +794,8 @@ vmwareVideoPlay(ScrnInfoPtr pScrn, VMWAREVideoPtr pVid,
     struct PACKED _body {
         uint32 escape;
         uint32 streamId;
-        struct _item items[SVGA_VIDEO_NUM_REGS];
+        /* Old hosts can not handle more then these regs */
+        struct _item items[SVGA_VIDEO_DATA_GMRID];
     };
 
     struct PACKED _cmdSetRegs {

commit 0a596fd0c92fdcf73071869a59029263a2596018
Author: Thomas Hellstrom <thellstrom@vmware.com>
Date:   Wed Jul 2 14:21:45 2014 +0200

    vmware/vmwgfx: Fix an error path segfault
    
    Part of freedesktop.org bugzilla bug #80645
    If taking a scanout reference on a pixmap fails, the
    struct vmwgfx_screen_entry::pixmap pointer must be set to NULL, otherwise
    the driver will incorrectly attempt to remove the scanout reference in the
    error path, causing a segfault.
    
    This problem is seen in the above-mentioned bug, but it is not the root


Reply to: