Chris Wilson [Tue, 22 Jul 2014 08:15:01 +0000 (09:15 +0100)]
sna: Remove %# from DBG messages
LogF doesn't support the 0x-prefix instruction.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 22 Jul 2014 07:52:10 +0000 (08:52 +0100)]
sna: Assert that we do not overwrite an earlier COW entry
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 22 Jul 2014 07:48:58 +0000 (08:48 +0100)]
sna/dri3: Don't forget to add SHM pixmaps to the list of exported DRI3 bo
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sun, 20 Jul 2014 06:29:21 +0000 (07:29 +0100)]
sna/video: Bump the maximum size for sprites
A sprite plane is limited by the display engine who's maximum resolution
has increased since the 2kx2k limitations of 8xx, so let's set it
correctly to the reported maximum CRTC size (since we have no individual
query for maximum sprite plane sizes).
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sun, 20 Jul 2014 06:27:58 +0000 (07:27 +0100)]
dri3-test: Print line number for shm failures
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 18 Jul 2014 06:31:25 +0000 (07:31 +0100)]
configure: Double check xinerama's headers
Having the pkgconfig present doesn't always necessarily imply the
headers are installed correctly - just fail over gracefully for xinerama
and intel-virtual-output
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 18 Jul 2014 06:14:19 +0000 (07:14 +0100)]
sna/dri2: Protect compsiteext.h include with build check
We shouldn't include calls to the composite extension if it has not been
built.
Reported-by: Ben Widawsky <ben@bwidawsk.net>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Jul 2014 16:10:39 +0000 (17:10 +0100)]
sna: Fix compilation with older Xorg
sna_display.c: In function 'sna_crtc_disable_shadow':
sna_display.c:1375:39: error: dereferencing pointer to incomplete type
DamageUnregister(&crtc->slave_damage->drawable, crtc->slave_damage);
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Jul 2014 16:04:02 +0000 (17:04 +0100)]
sna: Support TearFree on slaved outputs
By always forcing the shadow intermediatory, we can enable TearFree even
ona slave scanout.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Jul 2014 15:14:16 +0000 (16:14 +0100)]
backlight: Prevent dereference of potential NULL argv
Adam Sampson spotted that
"It's possible (but not very sensible) to exec a program with an empty
argument list, so argv[0] is not necessarily a valid pointer. For
example:
$ cat exec0.c
int main(int argc, char *argv[]) {
char *empty[1] = { NULL };
execvp(argv[1], empty);
perror("execvp");
return 1;
}
$ ./exec0 /usr/libexec/xf86-video-intel-backlight-helper
Usage: (null) <iface>
"
He sensibly suggested that we hardcode the program name to avoid the
NULL dereference. Being the paranoid type, we should also be careful not
to write to any file descriptors outside of our control (i.e. stderr),
so disable the messages unless we are debugging.
Reported-by: Adam Sampson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Jul 2014 14:23:46 +0000 (15:23 +0100)]
sna: Assert that we never attempt to flip the slave scanout
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Jul 2014 14:01:06 +0000 (15:01 +0100)]
sna/dri2: Disable SwapLimit buffers with buggy prime implementations
If there is a GPU screen, we have to assume that the DRI2 code may pass
around the wrong pointers to ReuseBufferNotify until the fix is
released:
commit
4d92fab39c4225e89f2d157a1f559cb0618a6eaa
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Wed Jun 18 11:14:43 2014 +0100
dri2: Use the PrimeScreen when creating/reusing buffers
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Jul 2014 13:40:51 +0000 (14:40 +0100)]
sna: Handle rotated slaved scanouts
As per the usual handling of rotated scanouts with unsupported
rotations, we stage the drawing onto a backbuffer then rotate onto the
crtc later. The difference here is that we must read the contents from
the master pixmap rather than our own screen pixmap.
Spotted was looking at slaved scanouts mistakenly setting the CRTC
transformed flag.
Reported-by: Tomas Pruzina <pruzinat@gmail.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=81383
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Jul 2014 11:54:47 +0000 (12:54 +0100)]
sna: Add missing DBG parameters
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Jul 2014 09:06:06 +0000 (10:06 +0100)]
sna: Avoid confusing failure to flip and flipping zero CRTC
During the present unflip path we blindly try to restore the original
mode after a flip failure. However, it confuses flipping zero CRTC with
a genuine failure. This has the result of undoing a DPMS change (e.g.
xset dpms force dpms) under a DRI3 compositor.
Reported-by: Jiri Slaby <jirislaby@gmail.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=81456
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Jul 2014 08:20:35 +0000 (09:20 +0100)]
sna: Busy-wait for the kernel to catch up when flipping
If the kernel reports that it is busy, it has not yet finished
processing a pending flip and we have multiple CRTC queued, just wait
for the kernel to clear its backlog before submitting the next flip. On
the other hand, if we can just overwrite the pending flip results.
However, the EBUSY may actually be a genuine report by the kernel of an
error, so check for an invalid CRTC first.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Jul 2014 07:53:13 +0000 (08:53 +0100)]
sna: Silence valgrind when reading plane properties
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 17 Jul 2014 07:32:14 +0000 (08:32 +0100)]
sna: Remove extraneous function wrapping
Since we only have the single callsite for do_page_flip, the wrapper is
not adding any meaningful information.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 16 Jul 2014 11:53:02 +0000 (12:53 +0100)]
sna: And remove new bogus assertion
We assert that damage is valid as we delete the Pixmap, and so we cannot
assert that the Pixmap is still valid itself.
Reported-by: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 16 Jul 2014 07:05:34 +0000 (08:05 +0100)]
sna: Make the damage check more verbose
Print out the pixmap number and the damage extents for when the
assertion fails.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 16 Jul 2014 06:19:03 +0000 (07:19 +0100)]
sna/gen2+: Remove assertion on draw->type for fills
I overlooked the tiling-fill path passing down a temporary DrawableRec
into the fill_boxes callback - invalidating the assertion.
Fixes regression from
commit
43176b9bfafe389c4b9ed676f4e50e3b06f858c4
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Mon Jun 30 21:01:11 2014 +0100
sna/dri2: Pass around the correct DrawableRec for sampling from the foriegn bo
Reported-by: Jiri Slaby <jirislaby@gmail.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=70461#c62
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 11 Jul 2014 21:23:55 +0000 (22:23 +0100)]
sna: Use a stricter test for determining CRTC off before updating the cursor
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 9 Jul 2014 11:10:15 +0000 (12:10 +0100)]
sna: Reduce reflections onto rotations
In order to support a wider range of rotation/reflections, perform a
simple reduction of the requested rotation first.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 10 Jul 2014 20:01:57 +0000 (21:01 +0100)]
configure: Provide a poor man's replacement for getline()
uClibc is one such library that doesn't implement getline()
Reported-by: Ben Widawsky <benjamin.widawsky@intel.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 8 Jul 2014 10:53:13 +0000 (11:53 +0100)]
sna: Rewrite rotation setup on top of universal drm planes
The kernel interface has changed slightly since the early proposals. Now
the rotation property is only on the plane and so we have to lookup the
primary prime as well.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 5 Jul 2014 13:40:38 +0000 (14:40 +0100)]
sna: Fix a couple of DBG messages
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 5 Jul 2014 08:46:00 +0000 (09:46 +0100)]
test/lowlevel-blt-bench: Add common PDF operators
Applications are starting to use PDF operators, so far I have spotted
multiply, dodge and lighten.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Matthieu Herrb [Fri, 4 Jul 2014 16:26:09 +0000 (18:26 +0200)]
backlight: Fix security issues in handling of the interface path name.
- don't allow '/' in the interface name to avoid escaping the /sys
hierarchy
- check snprintf() return value for overflow.
Problems reported by Adam Sampson. Thanks.
Signed-off-by: Matthieu Herrb <matthieu@herrb.eu>
Reviewed-by: Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Chris Wilson [Fri, 4 Jul 2014 12:04:02 +0000 (13:04 +0100)]
sna: Discard operations to either CPU or GPU bo when overwriting with RenderRectangles
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 4 Jul 2014 11:43:55 +0000 (12:43 +0100)]
sna: Tweak number of threads for short areas
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 4 Jul 2014 11:39:01 +0000 (12:39 +0100)]
sna: Convert a clear tile into a solid fill
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 4 Jul 2014 11:26:43 +0000 (12:26 +0100)]
sna: Fix typo s/num_threads/max_threads/
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 4 Jul 2014 11:14:11 +0000 (12:14 +0100)]
sna: Do a quirk early check for short areas before threading
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 4 Jul 2014 11:10:10 +0000 (12:10 +0100)]
sna: Disable use of threaded compositor when using threaded renderer
Reported-by: Zdenek Kabelac <zkabelac@redhat.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 4 Jul 2014 10:02:39 +0000 (11:02 +0100)]
sna: Utilise existing cached upload for promoting to GPU bo
If we already have a buffer that represents the data on the GPU, we can
simply use that when we need to promote the pixmap onto the GPU.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 4 Jul 2014 09:43:35 +0000 (10:43 +0100)]
sna: Promote tile pixmaps to GPU when reused
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 4 Jul 2014 09:14:54 +0000 (10:14 +0100)]
sna/gen8: Disable the unaligned check
Note sure if this is strictly required -- but at the moment it fails for
1x1R solids, causing us to skip glyphs. The simulator doesn't complain,
so just skip the check for now.
Reported-by: Ben Widawsky <ben@bwidawsk.net>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 4 Jul 2014 08:55:04 +0000 (09:55 +0100)]
sna: Tighten assertions for using upload proxies concurrently with CPU reads
After relaxing some of the rules on when to discard the upload proxies,
we also need to relax some of the complementary asserts.
Reported-by: Zdenek Kabelac <zkabelac@redhat.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 4 Jul 2014 08:48:53 +0000 (09:48 +0100)]
sna: Prevent creating a GPU bo for an inplace read
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 3 Jul 2014 18:18:04 +0000 (18:18 +0000)]
sna: Wrap xf86DPMSSet
We need to wrap xf86DPMSSet() so that we can reintialize our bookkeeping
and auxiliary planes after disabling/re-enabling CRTC during DPMS
operations.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 3 Jul 2014 08:07:44 +0000 (09:07 +0100)]
sna: Clear the cursor reference from the CRTC if the update fails
This should allow it to be restored correctly the next time it gets
shown.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 2 Jul 2014 20:17:54 +0000 (21:17 +0100)]
sna: Limit the size of the tiling object to be smaller than either the originals
When we tile, we do so in order to fit an operation involving two
objects larger than the aperture. If we then choose an intermediate
tiling object that is larger than either of those two, the error will
persist and we will be forced to recuse.
In the worst case, this will provide an upper bound to the recursion.
Reported-by: Bruno Prémont <bonbons@linux-vserver.org>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 2 Jul 2014 09:16:07 +0000 (09:16 +0000)]
test: Create separate SHM segments for ref/out
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 2 Jul 2014 10:47:32 +0000 (10:47 +0000)]
sna: Use the threaded compositor for picture conversions
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 2 Jul 2014 10:31:54 +0000 (11:31 +0100)]
sna/gen6+: Tweak consideration of compositing on BLT
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 1 Jul 2014 16:54:49 +0000 (17:54 +0100)]
sna: Fix typo in LinearFramebuffer handling
Eeek, when not using LinearFramebuffer we still want to create the GPU
bo: s/,/;/
Reported-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 1 Jul 2014 16:53:56 +0000 (17:53 +0100)]
sna: Correct migration flags for initial scanout creation
We want to preserve any contents preloaded (not that there should be
any...)
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 1 Jul 2014 15:59:31 +0000 (16:59 +0100)]
sna/dri2: Add a DBG option to select copy method
Often when debugging it is useful to force either use of the BLT or 3D
pipelines for copies.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 1 Jul 2014 14:11:07 +0000 (15:11 +0100)]
sna: Enforce LinearFramebuffer option
This option should only be used for compatibility. Previously this was
done at a high level, this changes it to enforce the tiling as we apply
the CRTC.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 1 Jul 2014 13:31:32 +0000 (14:31 +0100)]
sna/dri2: Use CPU fallback if possible
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Tue, 1 Jul 2014 12:10:32 +0000 (13:10 +0100)]
sna/dri2: Set depth/bpp on scratch DrawableRec
We need to initialise both depth and bitsPerPixel on the drawable struct
we pass around as they are used for selecting for the format when
copying.
Reported-by: Vedran Rodic <vrodic@gmail.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Damien Lespiau [Mon, 30 Jun 2014 18:24:13 +0000 (19:24 +0100)]
intel: Use the i845 info structure for INTEL_I845G_IDS()
I assume the intention was to provide a different structure for each of
the gen 2 devices.
This doesn't change anything really.
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
Chris Wilson [Mon, 30 Jun 2014 18:56:39 +0000 (19:56 +0100)]
sna: Add DBG breadcrumbs before flushes in BLT
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 30 Jun 2014 20:01:11 +0000 (21:01 +0100)]
sna/dri2: Pass around the correct DrawableRec for sampling from the foriegn bo
One day, we will move the width/height/bpp to the bo itself...
Reported-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 30 Jun 2014 15:32:45 +0000 (16:32 +0100)]
sna/dri2: Apply the paraniod buffer clip in the correct coordinate system
We need to only clip to the extents of the copy in the buffer space -
which implies that we need to translate the region into that space before
doing the clip.
Reported-by: Ilia Mirkin <imirkin@alum.mit.edu>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 30 Jun 2014 13:13:13 +0000 (14:13 +0100)]
sna: Tweak preference for small GPU bo
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 30 Jun 2014 10:20:54 +0000 (11:20 +0100)]
test/lowlevel-blt-bench: Update progress more frequently
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 30 Jun 2014 10:05:33 +0000 (11:05 +0100)]
sna: Reduce assertion when using asynchronous CPU access
If we are not actually accessing the memory through the pointer, we do
not care if it not currently coherent.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 30 Jun 2014 09:55:20 +0000 (10:55 +0100)]
sna: Silence snarky compliers
0 != (void *)0
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 30 Jun 2014 09:46:00 +0000 (10:46 +0100)]
sna: Mollify assert to be consistent with the scanout flush
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 30 Jun 2014 07:44:33 +0000 (08:44 +0100)]
test/lowlevel-blt-bench: Exercise masks
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 30 Jun 2014 07:44:33 +0000 (08:44 +0100)]
test/lowlevel-blt-bench: Exercise SHM pixmaps
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Mon, 30 Jun 2014 06:44:25 +0000 (07:44 +0100)]
intel-virtual-output: Remove one redundant cleanup on error
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sun, 29 Jun 2014 14:25:19 +0000 (15:25 +0100)]
intel-virtual-output: Cleanup singleton on failure
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sun, 29 Jun 2014 07:29:36 +0000 (08:29 +0100)]
intel-virtual-output: Convert debugging messages to verbosity
Original patch by main.haarp:
"A verbose switch is quite useful for debugging, it shouldn't require
editing and recompilation to gain more useful output. I added it."
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80664
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sun, 29 Jun 2014 08:26:10 +0000 (09:26 +0100)]
sna: Ensure CPU bo is synchronized before writing
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sun, 29 Jun 2014 06:02:44 +0000 (07:02 +0100)]
sna: Update allocation of CPU bo to avoid creating active buffers
Since we now prefer CPU detiling, exactly when we want active/inactive
buffers is a little more complex - and we also need to take into account
when we want to use the CPU bo as a render target.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sun, 29 Jun 2014 06:00:58 +0000 (07:00 +0100)]
sna: Sync CPU bo before writes
Fixes regression from
commit
961139f5878572ebea268a0bbf47caf05af9093f [2.99.912]
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Fri May 30 09:45:15 2014 +0100
sna: Use manual detiling for downloads
Reported-by: Harald Judt <h.judt@gmx.at>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80560
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 28 Jun 2014 20:07:08 +0000 (21:07 +0100)]
sna: Only preferentially upload through the GTT for large transfers
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 28 Jun 2014 16:38:54 +0000 (17:38 +0100)]
sna: Prefer linear if below tile_width
Be stricter in order to allow greater use of CPU bo.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 28 Jun 2014 13:23:29 +0000 (14:23 +0100)]
sna/io: Prefer CPU copies on LLC
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 28 Jun 2014 13:22:17 +0000 (14:22 +0100)]
sna: Don't discard damage for SHM pixmaps
We don't really want to rendering into SHM pixmaps except for copying
back due to the strict serialisation requirements.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 28 Jun 2014 13:21:36 +0000 (14:21 +0100)]
sna: Check for a mappable GPU bo before migrating damage
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 28 Jun 2014 13:20:00 +0000 (14:20 +0100)]
sna: Skip adding damage if it is already contained
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 28 Jun 2014 13:19:22 +0000 (14:19 +0100)]
sna: Tidy calling memcpy_from_tiled
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 28 Jun 2014 13:18:23 +0000 (14:18 +0100)]
sna: Micro-optimise unswizzling tiling/detiling
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Sat, 28 Jun 2014 06:05:55 +0000 (07:05 +0100)]
sna/trapezoids: Handle mono traps just in case
I disabled a few paths and ended up in an assert that mono trapezoids
shouldn't get that far...
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 27 Jun 2014 15:26:24 +0000 (16:26 +0100)]
uxa: Update Screen Pixmap width/height first
Since commit
dd6db82680b05cde4a47116b7096c054f3837e20 [2.99.912]
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Fri May 9 20:26:19 2014 +0100
uxa: Add DRI3 and miSyncShm support
we verify that the attaching bo meets the constraints required for the
Pixmap. However, when updating the ScreenPixmap following a resize, we
did not update the Pixmap size until after we tried to update the bo,
resulting in a validation failure when shrinking the screen.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 27 Jun 2014 15:12:35 +0000 (16:12 +0100)]
test: Expand number of sources for basic benchmarking
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 27 Jun 2014 15:00:03 +0000 (16:00 +0100)]
sna/dri2: DBG compile fixes
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 27 Jun 2014 12:42:37 +0000 (13:42 +0100)]
sna/glyphs: Add DBG option for glyph tolerance
And bump it to 3 so that glyph filtering doesn't force us to use the
mask too often.
References: https://bugs.freedesktop.org/show_bug.cgi?id=77436
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 27 Jun 2014 11:56:43 +0000 (12:56 +0100)]
sna/glyphs: Add DBG option for forcing glyphs-to-dst
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 27 Jun 2014 09:38:59 +0000 (10:38 +0100)]
sna: Check source bo is suitable for BLT before doing so
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 26 Jun 2014 19:19:52 +0000 (20:19 +0100)]
sna: Only reuse pinned batches for 830/845
Trying to fly too close to the sun. :(
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80558
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 26 Jun 2014 19:24:05 +0000 (20:24 +0100)]
sna/dri2: Slightly improved DBG messages
Missing git add from
commit
2e8c09f3fe468abba9c307ba3d7b2d22908e1172
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Wed Jun 25 22:19:23 2014 +0100
sna/dri2: Hook into ClientGone callback to clear dangling references
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 26 Jun 2014 19:21:12 +0000 (20:21 +0100)]
sna: Tidy selection of a near-miss active buffer.
References: https://bugs.freedesktop.org/show_bug.cgi?id=80560
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 26 Jun 2014 11:42:30 +0000 (12:42 +0100)]
sna: Fix userptr defines to match i915_drm.h
Now that we are starting to see userptr in the headers, we see that the
definitions slightly changed.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 26 Jun 2014 08:25:06 +0000 (09:25 +0100)]
sna: Remove scare quotes from hotplug detection "enabled"
Tidy up the log message by improving its formatting, and making it more
accurate.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 25 Jun 2014 21:19:23 +0000 (22:19 +0100)]
sna/dri2: Hook into ClientGone callback to clear dangling references
As the Window may exist for multiple Clients, we cannot rely on the
destruction of the Window decoupling all outstanding events and
preventing chasing a stale Client pointer.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80157
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Thu, 26 Jun 2014 05:59:07 +0000 (06:59 +0100)]
sna: Make output destroy more defensive
We may never create the properties as it may be ignored or the
allocation may fail, so we need to be careful when freeing we do not
stumble over invalid pointers.
References: https://bugs.freedesktop.org/show_bug.cgi?id=80355#c28
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 25 Jun 2014 17:05:46 +0000 (18:05 +0100)]
sna/dri2: Compile fixes for ancient Xorg
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 25 Jun 2014 16:20:52 +0000 (17:20 +0100)]
sna: Fix uninitialisable variable
sna_render.c: In function 'sna_render_picture_downsample':
sna_render.c:822: warning: 'priv' may be used uninitialized in this function
introduced in
commit
ded05e8abb248664124d2b86f77c27497a252c4e
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date: Mon Jun 23 22:15:56 2014 +0100
sna: Allow scratch pixmap to allocate linear GPU bo
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 25 Jun 2014 13:19:33 +0000 (14:19 +0100)]
sna: Improve throttling during bo allocation
By controlling how long we may block during buffer allocation, we can
relax the throttle elsewhere to prevent render lag buildup.
References: https://bugs.freedesktop.org/show_bug.cgi?id=77436
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 25 Jun 2014 12:21:58 +0000 (13:21 +0100)]
sna: Only mark throttle as done after success
References: https://bugs.freedesktop.org/show_bug.cgi?id=77436
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 25 Jun 2014 10:18:01 +0000 (11:18 +0100)]
sna: Track desired flushes better after starting a new batch
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 25 Jun 2014 10:45:55 +0000 (11:45 +0100)]
intel: Fix weblinks (again)
Julien pointed out that I fail at checking links.
Reported-by: Julien Cristau <jcristau@debian.org>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 25 Jun 2014 10:31:58 +0000 (11:31 +0100)]
intel: Fix weblinks
Matti reported a few outdated links to intellinuxgraphics.org, now
superseded by 01.org.
Reported-by: Matti Hämäläinen <ccr@tnsp.org>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 25 Jun 2014 08:00:04 +0000 (09:00 +0100)]
sna: Tweak scanout flush
We now distinguish gpu_dirty whilst the bo is not flushed within a batch
and needs_flush for when it is dirty and still busy.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 25 Jun 2014 07:18:25 +0000 (08:18 +0100)]
sna: Throttle before doing a TearFree buffer replacement
If the client is rendering fast, he may be rendering too fast and
starting to build up a backlog.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Wed, 25 Jun 2014 07:05:22 +0000 (08:05 +0100)]
sna: And fix the typo...
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>