Chris Wilson [Fri, 20 Jun 2014 13:29:43 +0000 (14:29 +0100)]
sna: Color patterns for BLT are required to be aligned to 256 byte boundaries
This so far appears to be the most restrictive alignment required, so
simply increase the upload alignment to 256 bytes.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80033
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 20 Jun 2014 07:28:32 +0000 (08:28 +0100)]
test: Increase number of tiled sources
Significantly improve the stress impose upon the tiled BLT operations.
Also start dumping pngs of the failures.
References: https://bugs.freedesktop.org/show_bug.cgi?id=80033
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 20 Jun 2014 06:28:02 +0000 (07:28 +0100)]
sna/dri2: Don't decouple front buffer tracking for invalid SwapBuffer calls
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 19 Jun 2014 19:39:59 +0000 (20:39 +0100)]
sna: Mark upload from SHM segment as read-only
As this may be mapped by the Xserver using a read-only SHM segment, we
are forced to treat it always as read-only. And this being X, that it is
using a SHM segment is opaque to the driver. Fantastic middlelayer.
This was incorrectly removed in
commit
e680e54eab6ffa72e5e1eb6cc0e3fe4b235b06a1
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Wed Jun 11 10:48:26 2014 +0100
sna: Ignore setting read-only for temporary userptr maps
Also let's not forget the ShmPutImage -> CopyArea path.
Reported-by: Christoph Haag <haagch.christoph@googlemail.com>
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=78411
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 19 Jun 2014 19:39:59 +0000 (20:39 +0100)]
sna: Mark upload from SHM segment as read-only
As this may be mapped by the Xserver using a read-only SHM segment, we
are forced to treat it always as read-only. And this being X, that it is
using a SHM segment is opaque to the driver. Fantastic middlelayer.
This was incorrectly removed in
commit
e680e54eab6ffa72e5e1eb6cc0e3fe4b235b06a1
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Wed Jun 11 10:48:26 2014 +0100
sna: Ignore setting read-only for temporary userptr maps
Reported-by: Christoph Haag <haagch.christoph@googlemail.com>
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=78411
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 19 Jun 2014 11:29:58 +0000 (12:29 +0100)]
sna: Missed fixing y tile offset in last commit
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 19 Jun 2014 10:51:00 +0000 (11:51 +0100)]
sna: Use the right pattern origin for tiled 8x8 extraction
References: https://bugs.freedesktop.org/show_bug.cgi?id=80033
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 19 Jun 2014 10:14:25 +0000 (11:14 +0100)]
sna: Fix up small extents for 8x8 tile construction
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 19 Jun 2014 09:49:09 +0000 (10:49 +0100)]
sna: Wrap pointer access for 8x8 tile construction
The kernel can quite happily send a SIGBUS whenever we read from an bo
(due to oom), so catch it and handle it.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 19 Jun 2014 08:47:02 +0000 (09:47 +0100)]
sna: Always readback shadow damage after replacing the buffer
Instead track what we explicitly want to discard for the next operation,
so that we don't have to copy back the whole buffer if we have to
replace the shadow and intend to overwrite it all.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 19 Jun 2014 06:40:16 +0000 (07:40 +0100)]
sna/dri2: Replace assertion with code to skip updating the back buffer
After a window resize or redirection, the DRI2BufferPtr become stale but
it may take a while for the Client to notice and reconfigure. Just
skip touching stale backbuffers and let the Client catch up.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 21:15:42 +0000 (22:15 +0100)]
sna: Fix modulus for partial conversion of tiles to 8x8 patterns
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 20:28:11 +0000 (21:28 +0100)]
sna: Delete the silly typo
Not checking DAMAGE_IS_ALL() correctly leads to an assertion failure.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 19:55:02 +0000 (20:55 +0100)]
sna: Do not treat both src/dst having no clones as being the same
Fixes regression from
commit
62aaf2ff4f8597067cf387865707baa00ed9a123
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Wed Jun 18 18:41:15 2014 +0100
sna: Skip redundant copies when already cloned
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 18:59:14 +0000 (19:59 +0100)]
sna: Add log breadcrumbs with valgrind
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 17:47:14 +0000 (18:47 +0100)]
sna: Fix DBG compilation
Missed updaing the DBG message in
commit
83c0f034454ef0f474126a3398e5e790ac5ef842
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Wed Jun 18 16:51:46 2014 +0100
sna: Pass desired CRTC viewport for completing single CRTC flips
References: https://bugs.freedesktop.org/show_bug.cgi?id=80157
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 17:41:15 +0000 (18:41 +0100)]
sna: Skip redundant copies when already cloned
References: https://bugs.freedesktop.org/show_bug.cgi?id=77436
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 15:51:46 +0000 (16:51 +0100)]
sna: Pass desired CRTC viewport for completing single CRTC flips
We cannot simply compare against the crtc->shadow_bo for all our needs,
so pass in exactly the setup we want and apply that. In particular this
is required when flipping away from the single CRTC setup on secondary
pipes.
Fixes TearFree multi-monitor regression from
commit
3932e97057fca16615adaefbc1eb25a0d51a1d8b [2.99.912]
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Mon Jun 9 08:58:15 2014 +0100
sna/dri2: Allow TearFree flipping to individual CRTC
Reported-by: Leo Wolf <jclw@ymail.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80191
Hans de Goede [Wed, 18 Jun 2014 13:01:37 +0000 (15:01 +0200)]
uxa: Mark the output as off before making pipe changes
This is a partial "backport" of commit
c6cd10f536, which makes the same
change for sna, to avoid users still using uxa ending up with a blackscreen
after plugging in an external monitor.
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1032978
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1103806
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Hans de Goede [Wed, 18 Jun 2014 13:01:36 +0000 (15:01 +0200)]
uxa: When the output is off, report the cached backlight value
This is a "backport" of commit
b545e10c50cb to uxa, so that users who are
still using uxa, don't end up with a black screen after suspend / resume.
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1032978
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1103806
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Chris Wilson [Wed, 18 Jun 2014 13:48:33 +0000 (14:48 +0100)]
sna/gen8: Fix cleanup after failing to convert channel
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 13:44:09 +0000 (14:44 +0100)]
sna/gen8: Fix unaligned() to return true when not aligned
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 13:34:04 +0000 (14:34 +0100)]
sna: Assert that we do not try to mmap a proxy
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Hans de Goede [Wed, 18 Jun 2014 13:11:05 +0000 (14:11 +0100)]
backlight: Fix compiler error
/usr/include/xorg/os.h around line 579 reads:
extern _X_EXPORT char *
strndup(const char *str, size_t n);
However strndup is already defined by glibc, and this redefine causes a
compile error.
This gets triggered because backlight.c does:
Without first doing:
Causing HAVE_STRNDUP to not be defined.
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Chris Wilson [Wed, 18 Jun 2014 09:18:26 +0000 (10:18 +0100)]
sna: Use nxm tiled blits for small regions of large tiles
If the region we are blitting is either narrow or short, we may be able
to construct a tiling pattern out of a large pixmap.
In the process, spot a regression due to
commit
542aeca6e67fc64f9133ca3e27ac8eca28af6d25
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Tue Jun 17 12:26:30 2014 +0100
sna: Tweak creation 8x8 tiled patterns
which copied too much from the source line.
References: https://bugs.freedesktop.org/show_bug.cgi?id=79888
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 09:17:02 +0000 (10:17 +0100)]
sna: Simplify sna_pixmap_get_source
kgem_bo_upload_image was open-coded, so replace it with a call to the
common function
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 09:16:26 +0000 (10:16 +0100)]
sna: Add DBG option to disable snoop bo cacheing
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 18 Jun 2014 06:37:00 +0000 (07:37 +0100)]
sna/dri2: fix invalid DBG string
References: https://bugs.freedesktop.org/show_bug.cgi?id=80157
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 17 Jun 2014 22:27:16 +0000 (23:27 +0100)]
sna: Set the correct mapping type after calling mmap__async
References: https://bugs.freedesktop.org/show_bug.cgi?id=80001
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 17 Jun 2014 21:23:02 +0000 (22:23 +0100)]
sna: Fix computing source bo for BLT operations
If we migrate the pixmap to the GPU, use the GPU bo. This may fix an issue
where we might end up using the CPU bo in a rare circumstance.
References: https://bugs.freedesktop.org/show_bug.cgi?id=80033
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 17 Jun 2014 21:25:05 +0000 (22:25 +0100)]
sna: Align some function parameters
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 17 Jun 2014 16:06:05 +0000 (17:06 +0100)]
sna: Remove invalid assert
Present and flip fallback may queue self-flips, so the assertion that
the crtc->flip_bo != crtc->bo is false.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 17 Jun 2014 13:08:06 +0000 (14:08 +0100)]
sna: Cache small pixmaps rather than forcing a large fallback for BLT operations
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 17 Jun 2014 12:47:32 +0000 (13:47 +0100)]
sna: Relax PREFER_GPU so that we don't needless create small GPU bo
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 17 Jun 2014 11:26:30 +0000 (12:26 +0100)]
sna: Tweak creation 8x8 tiled patterns
Avoid reading back from a GTT mmapping.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 17 Jun 2014 09:54:39 +0000 (10:54 +0100)]
sna/dri2: Fixup failure to do a render copy for DRI2CopyRegion
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 17 Jun 2014 07:51:00 +0000 (08:51 +0100)]
sna: Add a few missing checks for all-damaged
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 17 Jun 2014 07:30:55 +0000 (08:30 +0100)]
sna: Discard GPU damage for the magic upload proxy
The magic upload proxy is initially considered damaged in both the GPU
and CPU.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 17 Jun 2014 07:12:42 +0000 (08:12 +0100)]
sna/glyphs: DBG compile fix
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 16 Jun 2014 13:25:16 +0000 (14:25 +0100)]
sna: Regularly check the cache level on bo
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 16 Jun 2014 11:53:34 +0000 (12:53 +0100)]
sna/dri2: Allow single crtc exchanges to be queued up
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 16 Jun 2014 11:51:08 +0000 (12:51 +0100)]
uxa: Allocate frontbuffer to meet old fence constaints
libdrm is a little lax and does not allocate sufficient space for us to
safely use buffers on old gen. So compute the size we want for
ourselves.
Reported-by: Cem Aydin <cem.aydin@gmx.ch>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80088
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 16 Jun 2014 09:33:07 +0000 (10:33 +0100)]
sna/glyphs: Add DBG option to force use of the glyph image mask
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 16 Jun 2014 09:27:16 +0000 (10:27 +0100)]
uxa: Add some explanation to why bo were rejected
References: https://bugs.freedesktop.org/show_bug.cgi?id=80088
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 16 Jun 2014 09:13:09 +0000 (10:13 +0100)]
sna: Fix logic inversion for final placement in is_gpu_dst()
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 16 Jun 2014 08:46:54 +0000 (09:46 +0100)]
sna: Promote better active buffer reuse
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 16 Jun 2014 08:24:45 +0000 (09:24 +0100)]
sna/glyphs: Show number of glyphs in DBG
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 16 Jun 2014 07:03:21 +0000 (08:03 +0100)]
sna: Fix some batch DBG
Helps to check for a successful read when we want to show the batch
after execution.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sun, 15 Jun 2014 20:42:10 +0000 (21:42 +0100)]
sna: Clear our private hints about front rendering exported bo
Unlike GLXWindows, GLXPixmaps are rendered directly into, without a
staging copy. Therefore we must treat those carefully when exported and
clear our hints everytime control passes back to the Client.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=79999
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sun, 15 Jun 2014 19:55:30 +0000 (20:55 +0100)]
sna: Add more DBG to track transitions between CRTC and its shadow or flip bo
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sun, 15 Jun 2014 13:04:50 +0000 (14:04 +0100)]
test: Add a simple SHM test skeleton
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 20:41:36 +0000 (21:41 +0100)]
sna: Enable TearFree by default for systems with PSR
Panel Self-Refresh requires us to avoid frontbuffer rendering in order
to be power efficient. This is a job for TearFree!
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 14 Jun 2014 05:51:34 +0000 (06:51 +0100)]
sna: Fix assertions for discarding upload caches
The upload caches are special, along with having a bo->proxy, they also
claim to be completely damaged on both the GPU and CPU. Allow that to
pass through when discarding the proxy.
Reported-by: Nick Bowler <nbowler@draconx.ca>
Bugzilla; https://bugs.freedesktop.org/show_bug.cgi?id=79992
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 19:30:25 +0000 (20:30 +0100)]
sna: Use the right is-clipped hint
The region here has yet to be clipped, and so the only valid is-clipped
hint is from the flags computed from the PolyRect extents. Make sure we
use those when determining whether it is valid to discard damage.
Fixes regression from
commit
ad0390068832ad4727371902fe41a85a53de1894 [2.99.903]
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Tue Sep 24 10:00:03 2013 +0100
sna: Separate out copy preferrence from operating in place decision
Reported-by: Nick Bowler <nbowler@draconx.ca>
Tested-by: Nick Bowler <nbowler@draconx.ca>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=79992
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 17:56:57 +0000 (18:56 +0100)]
sna: Only discard the CPU bo if we have a GPU bo to transfer the damage to
References: https://bugs.freedesktop.org/show_bug.cgi?id=79992
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 20:41:16 +0000 (21:41 +0100)]
intel-virtual-output: Compile fixes
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 18:59:16 +0000 (19:59 +0100)]
intel-virtual-output: Disable outputs on remote displays upon shutdown
References: https://bugs.freedesktop.org/show_bug.cgi?id=79994
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 18:29:41 +0000 (19:29 +0100)]
intel-virtual-output: Initialise image after clone
As the image inherits its width/height from the clone, we need to set
those first on the clone.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=79994
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 18:15:08 +0000 (19:15 +0100)]
intel-virtual-output: Only call XShmDetach on a valid SHM segment
Saves a couple of extraneous XErrors.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 17:37:15 +0000 (18:37 +0100)]
intel-virtual-output: Check for an error creating the DRI3 fd
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=79994
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 15:14:43 +0000 (16:14 +0100)]
sna: Refine decision whether to use the GPU or render inplace
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 14:06:13 +0000 (15:06 +0100)]
sna: Track the pageflip bo's busyness
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 12:50:34 +0000 (13:50 +0100)]
intel: Check that the fd points to i915 after authorising
The call to GETPARAM requires either a rendernode or authorisation.
Therefore we can only assert that the fd is a valid i915 handle after
authorise() and not before.
Reported-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 11:32:12 +0000 (12:32 +0100)]
sna/gen6+: Prefer the BLT for large overlapping copies
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 09:52:47 +0000 (10:52 +0100)]
sna: Try to reuse the current cursor if we fail to update
As a last resort, continue to display the old cursor if we tried and
failed to create a new cursor.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 08:31:50 +0000 (09:31 +0100)]
xvmc: Refactor mutex locking
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 08:14:47 +0000 (09:14 +0100)]
xvmc: Sanitize compile and library flags
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 08:15:30 +0000 (09:15 +0100)]
configure: Fix DRI2 build
One s/DRI2/have_dri2/ too far.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 07:51:20 +0000 (08:51 +0100)]
sna: Reorder ignore_cpu_damage() to avoid asserts
Tricksy asserts making sure that the correct arguments are passed
around!
Reported-by: Arkadiusz Miskiewicz <arekm@maven.pl
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 07:32:34 +0000 (08:32 +0100)]
sna/gen8: Allow reads from scanout to be cached
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 07:27:05 +0000 (08:27 +0100)]
sna/gen8: Check for WT support before attempting to use the WT mocs
It appears the kernel has a better idea when WT is supported on which
gen8 parts. I assumed it was always supported, but experience suggests
otherwise, so only use WT support when advertised.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=79967
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 13 Jun 2014 06:48:15 +0000 (07:48 +0100)]
configure: Allow manual disabling of each DRI level
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 12 Jun 2014 08:52:50 +0000 (09:52 +0100)]
sna: Try to use CPU uploads before BLT uploads
As the BLT upload implies a sync (and a likely GPU boost), only do so if
we cannot do an immediate upload with the CPU, either directly to
backing memory or through the GTT.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 12 Jun 2014 08:26:14 +0000 (09:26 +0100)]
sna: Refactor USE_INPLACE debug macro
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 20:14:00 +0000 (21:14 +0100)]
sna/gen8: Clear a couple more push constants
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 18:10:22 +0000 (19:10 +0100)]
sna: Remove bogus assertion
The sna_pixmap is cleared afterwards, it does not need to be clear on
free.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 17:07:46 +0000 (18:07 +0100)]
sna: Fix direction flags for memmove
Under a compositor, the current deltas may invert the sense of the copy
direction, causing scrolling corruption. Simplify handling those flags
by making them invariant for the function.
Reported-by: Bruno Prémont <bonbons@linux-vserver.org>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=79843
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 16:43:33 +0000 (17:43 +0100)]
sna: Use the pixmap header creation routine
A few more places could use the common pixmap creator, just remember to
handle the SHMPixmap complication!
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 15:41:22 +0000 (16:41 +0100)]
sna/gen6+: On small GT avoid the intermediate copy for overlaps
If the memory bw is constrained on the GPU avoid doing the 2-pass copy
for overlaps on the render ring, and do the single pass slower BLT copy
instead - as since it has to transfer less data it will be faster.
Reported-by: Ildar Nurislamov <absorbb@gmail.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=77436
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 15:21:13 +0000 (16:21 +0100)]
sna/gen6+: Overlapping bo by definition have compatible depths
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 15:12:26 +0000 (16:12 +0100)]
sna: First copy to overlap temporary must be using GXcopy
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 14:49:43 +0000 (15:49 +0100)]
sna: Remove debugging hunk
Stray hunk in self-copy boxes.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 14:40:25 +0000 (15:40 +0100)]
sna: Update damage pointer after the implicit reduction
sna_damage_contains_box() routine implicitly reduces the damage before
performing its check. This may alter and even destroy the damage entry,
so pass in the handle so that it can be updated correctly.
References: https://bugs.freedesktop.org/show_bug.cgi?id=77436
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 14:29:59 +0000 (15:29 +0100)]
sna: Fix scanout creation routine for old kernels <= 3.11
With an old kernel, we would fail to actually mark the display as part
of the scanout domain, but proceed to assign it a fb id. This caused our
asserts to report our bookkeeping error.
Reported-by: Pavel Ondračka <pavel.ondracka@email.cz>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=79909
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 13:34:33 +0000 (14:34 +0100)]
sna: Add some DBG to the memmove path
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 13:22:26 +0000 (14:22 +0100)]
sna: Tweak self-copy boxes to hit the GPU more often
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 13:08:31 +0000 (14:08 +0100)]
sna: Recheck source bo after migrating dst (in case of src == dst)
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 13:00:04 +0000 (14:00 +0100)]
sna: Skip redundant clears
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 12:59:46 +0000 (13:59 +0100)]
sna/glyphs: Always print some DBG when performing fallback
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 12:18:33 +0000 (13:18 +0100)]
sna: Add some asserts to track redundant damage operations
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 6 Jun 2014 07:30:59 +0000 (08:30 +0100)]
sna/gen8: Check offset alignment before using a userptr for RENDER
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=79053
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Apr 2014 20:04:15 +0000 (21:04 +0100)]
sna: Support efficient cursor updates for old machines
Given a kernel patch to fix coherency of physical objects, we can use a
more efficient method for updating cursors.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 6 Jun 2014 11:00:35 +0000 (12:00 +0100)]
sna: MST topologies may change on any hotplug event
As the kernel does not send out an explicit DISCOVER event, we have to
reinspect every connector after every hotplug event to detect topology
changes.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 8 May 2014 07:04:58 +0000 (08:04 +0100)]
sna: Create a stable output name based on MST topology
In order to provide persistent names for MST devices, which may change
topology dynamically, the kernel exports a PATH blob. We can then use
this path to generate the output name, and so reuse existing XID when a
monitor is plugged back in.
Based on the patch for -modesetting by Dave Airlie.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 09:48:26 +0000 (10:48 +0100)]
sna: Ignore setting read-only for temporary userptr maps
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 09:35:50 +0000 (10:35 +0100)]
sna: Prefer to operate inplace on the GPU rather than stall on the CPU
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 09:12:01 +0000 (10:12 +0100)]
sna: Discard TearFree damage before checking for an overwriting upload
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 08:29:50 +0000 (09:29 +0100)]
sna: Silence compiler warnings for discarding const Region points
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 07:39:42 +0000 (08:39 +0100)]
sna: Squelch log messages for fb/pixmap tiling in the default case
The output is confusing, so hide it unless it is modified by the user.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 11 Jun 2014 06:59:41 +0000 (07:59 +0100)]
sna: Mark the GPU as all damaged when discarding CPU bo during uploads
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>