This is quite trivial to hit given the 2k limits on gen2/gen3. We
compromise on image quality by pre-downscaling the source by a fixed
factor to make it fit into the pipeline in preference to performing the
entire operation on the CPU.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Remove the PCI ID device checks by using the simpler check on the
generation id for errata pertaining to 830/845.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
...so that CPU pixmap is correctly invalidated for the next readback.
For instance, if you were to take a screenshot on a composited destkop.
Reported-by: Sitosfe Wheeler <sitsofe@yahoo.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
As we use GTT mappings if writing directly into the tiled buffer and the
available aperture is reported by the kernel as the total GTT and not
limited to the fenceable/mappable region, we need to manually probe this
value and ensure that our creation and fenced routines observe this
distinct limit.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Eeek, the wait-for-target-msc was using the immediate swap path, meaning
that for copy-swaps the copy was submitting immediately but the client
throttled waiting upon the target vblank. What is actually intended is
for the presentation to be delayed until the target_msc.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
The secret is not to cheat and render directly to the front buffer, but
remember to mark the Window as damaged.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
The front-buffer of a DRI2 drawable, may not in fact be pointing to the
scanout pixmap. So override the destination for swapbuffers to update
the scanout.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
We either conflated bpp (which fails given a mixture of depth-24 and
depth-30 pixmaps) or neglected to check at all.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
It is to prepare for Xv on Ivybridge. The difference from Sandybridge
is that all message payload must be in GRF registers instead of MRF registers
on Ivybridge. We will only redefine some M4 macros for Ivybridge
Signed-off-by: Xiang, Haihao <haihao.xiang@intel.com>
Fixes a regression from d0362a. In bypassing the is_wedged checked, we
also ended up bypassing the checks that we could indeed render to the
target bo. With the result that we were creating GPU buffers for SHM
surfaces, something that requires Xserver fixes before we can actually
enable...
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
...both to correct the placement of the fbcon into the smaller scanout and
to ensure that we correctly clip the boxes to be copied.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
So in order not to block server shutdown, check that the fd is readable
before attempting to read from it.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Otherwise if we fail to check, then we create a 0x0 surface to sample
with the operation -- net result is that we end up using a clear source
instead of the desired mask.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
I'd like it to not be in the SDK anymore, and we're not using anything
from it.
Signed-off-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Otherwise we end up doing work for no reason, ala the regression in
grads-heat-map. However, it is important that the damage is reduced at
some point or else it may grow unbounded. Hopefully normal usage will
never hit the pathologocial case...
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
For the broken shader workaround, we need to reset the pipeline state
before every blt as the state is changed by the magic CA pass. So we
need to check that we actually have sufficient space to emit the
pipelined pointers before doing so.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
In order to attach a scanout (and use swrast) on a wedged GPU, we need to
bypass the safety checks for normal pixmap creation.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
SNA requires some pending bug fixes to the xserver so it makes little
sense to conditionalise the code and deliberately cause broken
behaviour.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=3843
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This patch has been carried by the distributions every since they
started doing graphical boot splashes. Time to integrate it and give it
some TLC.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
We only use it for the id. Everything else stored on it, like the
buffer_id, is not permanent and we need to query the current status as
required.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>