summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2014-06-11sna: Create a stable output name based on MST topologyChris Wilson
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>
2014-06-11sna: Ignore setting read-only for temporary userptr mapsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-11sna: Prefer to operate inplace on the GPU rather than stall on the CPUChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-11sna: Discard TearFree damage before checking for an overwriting uploadChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-11sna: Silence compiler warnings for discarding const Region pointsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-11sna: Squelch log messages for fb/pixmap tiling in the default caseChris Wilson
The output is confusing, so hide it unless it is modified by the user. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-11sna: Mark the GPU as all damaged when discarding CPU bo during uploadsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-10sna/dri2: Check that the window covers the whole CRTC before xchgChris Wilson
Fixes TearFre 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 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-10sna: Cast away compiler warningChris Wilson
sna_display.c: In function 'has_user_backlight_override': sna_display.c:595:3: warning: return discards 'const' qualifier from pointer target type [enabled by default] Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-10sna: Expand debugging to cover gen8 BLT variationsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-10sna: Fix arguments when flipping transformed TearFree outputsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-10sna: Tidy a few asserts on the state of crtc->flip_boChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-10sna: Handle the user passing "Backlight" ""Chris Wilson
Allow the user to disable the backlight control by passing the empty string in the xorg.conf. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-102.99.912 snapshot2.99.912Chris Wilson
2014-06-10sna: Queue a flip after fixing up a failed flipChris Wilson
After a flip fails, we try to update the CRTC manually to new fb. However, the caller is still expecting to receive an event though the drm device to notify when the flips are complete. In order to maintain that ABI, we need to queue another flip after the fixup (to the currently bound fb). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-09sna: Fix the typo in the last commitChris Wilson
Rewording the sentence and reordering the arguments was a mistake! Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-09sna: Add an extra error message before disabling a CRTCChris Wilson
One of the error paths to disable a pipe was lacking a log message. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-09configure: Allow disabling control over the backlightChris Wilson
Some OS prefer to control the backlight themselves through another daemon and so do not want X interfering. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-09sna: Defer the copy back from the shadow CRTC bo until we allocate the targetChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-09sna: Fix cut'n'paste DBG errorChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-09sna/dri2: Avoid trying to flip between bo with different pitchesChris Wilson
It could happen that we create front/back buffers with different pitches. The kernel refuses to flip between such buffers, and so we will hit some fallback paths that try to fix up the failed flips. Circumvent such by avoiding the flip. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-09sna: Fixup normal flips between different pitchesChris Wilson
Apply the manual CRTC fixup in case pageflipping fails. This can happen if the pitches between the front and back differ for example. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-09sna/dri2: Allow TearFree flipping to individual CRTCChris Wilson
Baby step. We first take advantage of TearFree to allow us to redirect a single CRTC to the DRI2 frontbuffer and so allow a fullscreen game covering a single monitor to avoid expensive blits when running in a multi-monitor setup. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-09sna: Do not rely on udev_monitor_receive_device() being non-blockingChris Wilson
The libudev documentation says that is it non-blocking by default, but experience shows otherwise. Reported-by: Sedat Dilek <sedat.dilek@gmail.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-08uxa: Do not FreePixmap(screen->devPrivate)Chris Wilson
Prevent the crash caused by commit 444a1f7a8802999e27ecf5f6eb598df2206f7277 Author: Brendan King <brendan.king@imgtec.com> Date: Thu Apr 24 11:37:45 2014 +0100 fb: fix screen pixmap leak on server reset Call FreePixmap() instead of free() to destroy the screen pixmap in fbCloseScreen(). Signed-off-by: Frank Binns <frank.binns@imgtec.com> Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Keith Packard <keithp@keithp.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-08sna/dri2: DBG compile fixChris Wilson
Typo in DBG message. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-08sna/dri2: Allow xchg to replace the frontbuffer when all outputs are offChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-08sna/dri2: Use xchg for offscreen drawables where applicableChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-08sna/dri2: Explicitly drain the pending event queue before swappingChris Wilson
As there may be some latency between the wakeup and the queue, do a final check if there is a pending vblank event before we decide whether to chain up or perform an immediate flip. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-08sna/dri2: Mark frames under constructionChris Wilson
As we may recurse into the vblank handler whilst waiting for the TearFree shadow, we need to be careful that we do not queue the frame from the vblank handler that we are in the process of constructing. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-08sna/dri2: Check the xchg against the Pixmap sizeChris Wilson
As the Window may be resized between the client sending the swap request and the xchg being processed, we need to validate the swap against the final target not the buffers supplied originally by the client. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-07sna: Restore backlight when switching to VTChris Wilson
fbcon doesn't adjust the backlight when it takes over. Therefore if X performs a VT switch whilst its outputs are off, fbcon wakes up with no backlight and users are unhappy. Make the assumption that whoever takes over the VT will set the outputs as it desires, and that the failsafe value is to then turn the backlight to full. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=67025 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-07sna: Fix reporting of TearFreeChris Wilson
The switch was moved after we checked whether pageflips are supported, but the log message was left in the old location. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-07sna: Release CRTC on VT switchChris Wilson
In order to free up memory and improve our bookkeeping when the X server is switched away from the current VT, disable the CRTC. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-07sna: Allow TearFree to be enabled by default via configureChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-07sna: Fix TearFree for non-compositorsChris Wilson
The tearfree code forgot to update the shadow bo, so after the first flip it would be rendering to the scanout anyway and flip to itself periodically. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-06sna: Fix no relaxed delta path for gen4+Chris Wilson
This is for debug purposes only. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-06sna: Auto-retire upload proxiesChris Wilson
This was disabled in commit 9f4f855ba37966fb91d31e9081d03cf72affb154 Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Mon May 26 07:06:18 2014 +0100 sna: Implicit release of upload buffers considered bad as retiring the buffers during the command setup could free one of the earlier bo used in the command. But discarding the snooped bo could still be advantageous. So restore the automatic discard of upload proxies, but make sure we only do between operations. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Matti Hämäläinen <ccr@tnsp.org>
2014-06-06sna: Only allow the inplace copy to replace a complete overwritten GPU boChris Wilson
And double check after recreating the new GPU bo that is still mappable. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-06sna: Rearrange scanout_flush checking to avoid potential crashChris Wilson
With a shadow, we may never attach a GPU bo to the frontbuffer, so be careful when checking the scanout not to dereference that NULL pointer. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-06sna: Report KMS driver versionChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-06man: Update notes about TearFreeChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-06sna/dri2: Restore flush on front buffers after swapping boChris Wilson
Fallout from commit 8369166349c92a20d9a2e7d0256e63f66fe2682b Author: Chris Wilson <chris@chris-wilson.co.uk> Date: Wed Jun 4 08:29:51 2014 +0100 sna/dri2: Enable immediate buffer exchanges We set the flush hint too early, as we may need to swap the GPU bo for a more appropriate buffer for DRI. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-06sna: Hook up a backlight udev monitor for external changesChris Wilson
Changes to the backlights are notified through uevents. Hooking up a udev monitor to listen out for external changes to the backlight (e.g. through ACPI function keys, or by the user writing to /sys/class/backlight directly) is easier than enabling polling on the backlight sysfs file using X's select() mechanism. Since we listen to backlight changes, we have to be careful not to confuse the side-effects of disabling connectors (which may cause either ourselves or the kernel to turn off the backlight) with the user value. Many thanks to Alexander Mezin for the suggestion to use udev for tracking the notifications for external changes to the backlight. Reported-by: Alexander Mezin <mezin.alexander@gmail.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=79699 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-05sna: When the output is off, report the cached backlight valueChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-05sna: Inline calls to save/restore backlight around output DPMSChris Wilson
The intertwined logic was a little confusing to read mixed between the functions, so inline it. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-05sna: Set initial output DPMS state from kernelChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-05sna: Make sure we recompute the vblank interval after reconfiguring the CRTCChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-05sna: Skip marking the CRTC as damaged for TearFreeChris Wilson
As we have reorder the application of damage on a TearFree frontbuffer to before we attach the CRTC, we do not need to then schedule the update afterwards (until it gets drawn by the client). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2014-06-05sna: Fix DBG compilationChris Wilson
Update the DBG to reflect the new arguments to sna_damage_reduce_all() Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>