summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-06-24sna: Add some more DBG around connector discoveryChris Wilson
References: https://bugs.freedesktop.org/show_bug.cgi?id=80355 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-24sna: Ensure serial is not 0 for runtime MST discoveryChris Wilson
We reserve serial==0 for the initial setup that is run before RandR is configured. After the server is running, we have to take extra steps to make the outputs visible to userspace. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-24sna: Fix the usual "x = y" typos in creating boxesChris Wilson
Fixes regression from commit 1d74b2e07d125ad95b9db6c9c032e90faf2bfa60 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Tue Jun 24 08:58:51 2014 +0100 sna: Decompose self-copy into overlapping/non-overlapping regions Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-24sna/glyphs: Clip damage to dstChris Wilson
We only check if the hardware will automatically discard writes outside of the target pixmap, but we must manually clip the damage before adding it to our tracker. Reported-by: Jiri Slaby <jirislaby@gmail.com> Reported-by: Zdenek Kabelac <zkabelac@redhat.com> References: https://bugs.freedesktop.org/show_bug.cgi?id=70461#c58 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-24sna: Trim composite region against dst clip extentsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-24intel: Wait for the DRM device to loadChris Wilson
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80397 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-24sna: Decompose self-copy into overlapping/non-overlapping regionsChris Wilson
We only need to stage the copy for the overlapping portion of the self-copy, for the rest we can do in a single pass. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-24sna/dri2: Add a dash more assertsChris Wilson
References: https://bugs.freedesktop.org/attachment.cgi?id=101618 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Disable CRTC after MST topology changeChris Wilson
In order to disable CRTC after marking outputs as removed after probing MST topology updates, we must manually mark the CRTCs as no longer enabled. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Silence compiler warning for shadowed variableChris Wilson
sna_display.c: In function 'sna_mode_redisplay': sna_display.c:6322:12: warning: declaration of 'fb_id' shadows a global declaration [-Wshadow] sna_display.c:223:24: warning: shadowed declaration is here [-Wshadow] CC sna_display_fake.lo Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Allow scratch pixmap to allocate linear GPU boChris Wilson
When allocating a scratch pixmap, we do so in the expectation that rendering on the GPU is always preferrable, so even allocate a small linear bo. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Promote to full GPU bo after forced migration away from CPU boChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Prefer rendering on the CPU to avoid damage migrationChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Force creation of GPU bo for drawing if need beChris Wilson
Now that we are more eager to transfer to the GPU bo if we expect rendering to the CPU bo to be either slow or risk potential corruption, we can find ourselves in a recursive loop when we also decide not to create the GPU bo. Prevent that by explicitly creating the GPU bo if desired. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna/gen6+: Initialise src offset before useChris Wilson
Fixes regression from commit 30348efd57135edee41fccb87133c572b6473aa8 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Mon Jun 23 11:14:25 2014 +0100 sna/gen6+: Avoid adjusting copy coordinates until commited to using them which assumed that the render state was being zeroed. Reported-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Fix flushing empty batchesChris Wilson
A logic inversion in commit 1909910fdf89216d18703e50728f4604f75d5d66 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Sun Jun 22 20:19:22 2014 +0100 sna: Inject a batch flush before adding a fresh bo also applied the injection to when the batch was empty. Reported-by: Jiri Slaby <jirislaby@gmail.com> References: https://bugs.freedesktop.org/show_bug.cgi?id=70461#c48 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Handle old busy_ioctl not reporting the active ringChris Wilson
If we have an old kernel, just presume that the bo was last active on the render ring. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna/gen6+: Avoid adjusting copy coordinates until commited to using themChris Wilson
If we need to fallback to the BLT unit, we need to pass it the original source/dest coordinates and not our transformed render coordinates. So keep the original values intact until we start emitting the render operation. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna/gen4+: Add some more asserts around recreating vertex buffersChris Wilson
References: https://bugs.freedesktop.org/show_bug.cgi?id=70461#c46 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Allow the CPU bo to be created if GPU rendering is forcedChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna/gen6+: Encourage the compiler to inline a couple of key functionsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Prefer to render over damage into the GPU boChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Do not set CAN_CREATE_GPU flag for untiled allocationsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Rename IGNORE_CPU to IGNORE_DAMAGE to better reflect its purposeChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Add DBG breadcrumbs to sna_output_discover()Chris Wilson
References: https://bugs.freedesktop.org/show_bug.cgi?id=80355 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna/gen4+: Add box emitters for the generic vertex pathsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Inject a batch flush before adding a fresh boChris Wilson
Fresh bo (those without a reservation already defined, ala presumed_offset) will cause the kernel to do a full relocation pass. So, if possible flush the already correct batch in the hope of trimming the amount of checking the kernel has to perform on this new batch. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-23sna: Add missing string for DBGChris Wilson
References: https://bugs.freedesktop.org/show_bug.cgi?id=80355#c12 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-22sna: Disable unused CRTC after undock eventsChris Wilson
If undocking removes output (as the MST topology changes and some outputs then become unreachable), we may leave dangling CRTC. This confuses us, so disable any enabled but unconnected CRTC after the undock event. Reported-by: Sree Harsha Totakura <freedesktop@h.totakura.in> References: https://bugs.freedesktop.org/show_bug.cgi?id=80355#c5 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-22sna: Track CRTC mode changes and discard old flipsChris Wilson
If we have a pending flip across a modeset we must be careful to drop the stale flip_bo after the modeset. Reported-by: Sree Harsha Totakura <freedesktop@h.totakura.in> References: https://bugs.freedesktop.org/show_bug.cgi?id=80355#c8 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-22sna: Clean up CRTC on CloseScreenChris Wilson
We need to do this to stop any stray references escaping through kernel events now that we are passing the CRTC through the event. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-21sna: Discard write hint from a couple more move-to-gpuChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-21sna: Clear the transform flag on disabling the CRTCChris Wilson
In places, we assume that if the flag is set, we must have an active CRTC. However, we were not clearing when disabling the CRTC. Reported-by: Sree Harsha Totakura <freedesktop@h.totakura.in> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80325 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-20sna: Avoid blending with the render engine on snoopable boChris Wilson
This seems slightly weird, as there is nothing to indicate that this would generate incorrect results only for snoopable bo. But no many of flushes make my pnv box happy, so adjust the placement logic to move the blending operation away from the snoopable target. This is sensible for reasons of avoiding snoops from the render pipeline anyway. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=80253 Reported-and-tested-by: Matti Hämäläinen <ccr@tnsp.org> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-20sna: Be more flexible in converting random subsamples to 8x8 tilesChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-20sna: Mark up const boxes to keep the compiler happyChris Wilson
Pass around const to suppress a few compiler warnings. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-20sna: Feed more operations into the 8x8 BLT tilerChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-20sna: Color patterns for BLT are required to be aligned to 256 byte boundariesChris Wilson
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>
2014-06-20test: Increase number of tiled sourcesChris Wilson
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>
2014-06-20sna/dri2: Don't decouple front buffer tracking for invalid SwapBuffer callsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-20sna: Mark upload from SHM segment as read-onlyChris Wilson
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>
2014-06-19sna: Mark upload from SHM segment as read-onlyChris Wilson
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>
2014-06-19sna: Missed fixing y tile offset in last commitChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-19sna: Use the right pattern origin for tiled 8x8 extractionChris Wilson
References: https://bugs.freedesktop.org/show_bug.cgi?id=80033 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-19sna: Fix up small extents for 8x8 tile constructionChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-19sna: Wrap pointer access for 8x8 tile constructionChris Wilson
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>
2014-06-19sna: Always readback shadow damage after replacing the bufferChris Wilson
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>
2014-06-19sna/dri2: Replace assertion with code to skip updating the back bufferChris Wilson
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>
2014-06-18sna: Fix modulus for partial conversion of tiles to 8x8 patternsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-18sna: Delete the silly typoChris Wilson
Not checking DAMAGE_IS_ALL() correctly leads to an assertion failure. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>