xserver-multidpi/hw/xfree86/modes
Alex Goins 1bdbc7e764 randr/xf86: Add PRIME Synchronization / Double Buffer
Changes PRIME to use double buffering and synchronization if all required
driver functions are available.

rrcrtc.c:
    Changes rrSetupPixmapSharing() to use double buffering and
    synchronization in the case that all required driver functions are
    available. Otherwise, falls back to unsynchronized single buffer.

    Changes RRCrtcDetachScanoutPixmap() to properly clean up in the case of
    double buffering.

    Moves StopPixmapTracking() from rrDestroySharedPixmap() to
    RRCrtcDetachScanoutPixmap().

    Changes RRReplaceScanoutPixmap() to fail if we are using double buffering,
    as it would need a second ppix parameter to function with double buffering,
    and AFAICT no driver I've implemented double buffered source support in uses
    RRReplaceScanoutPixmap().

randrstr.h:
    Adds scanout_pixmap_back to struct _rrCrtc to facilitate PRIME
    double buffering.

xf86Crtc.h:
    Adds current_scanout_back to _xf86Crtc to facilitate detection
    of changes to it in xf86RandR12CrtcSet().

xf86RandR12.c:
    Changes xf86RandR12CrtcSet() to detect changes in
    scanout_pixmap_back.

    Adds scanout_pixmap_back to struct _rrCrtc to facilitate PRIME double
    buffering.

v1: Initial commit
v2: Rename PresentTrackedFlippingPixmap to PresentSharedPixmap
v3: Refactor to accomodate moving (rr)StartFlippingPixmapTracking and
    (rr)(Enable/Disable)SharedPixmapFlipping to rrScrPrivRec from ScreenRec
    Add fallback if flipping funcs fail
v4: Detach scanout pixmap when destroying scanout_pixmap_back, to avoid
    dangling pointers in some drivers
v5: Disable RRReplaceScanoutPixmap for double-buffered PRIME, it would need an
    ABI change with support for 2 pixmaps if it were to be supported, but AFAICT
    no driver that actually supports double-buffered PRIME uses it.
    Refactor to use rrEnableSharedPixmapFlipping() as a substitute for
    rrCrtcSetScanoutPixmap() in the flipping case.
    Remove extraneous pSlaveScrPriv from DetachScanoutPixmap()
    Remove extraneous protopix and pScrPriv from rrSetupPixmapSharing()
v6: Rebase onto ToT
v7: Unchanged

Reviewed-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: Alex Goins <agoins@nvidia.com>
2016-06-28 12:56:17 -04:00
..
Makefile.am xfree86: Remove DisplayID support 2014-09-26 15:27:18 -04:00
xf86Crtc.c xf86Crtc: don't set the root window property on slave GPUs. 2016-05-04 15:33:10 -04:00
xf86Crtc.h randr/xf86: Add PRIME Synchronization / Double Buffer 2016-06-28 12:56:17 -04:00
xf86Cursors.c xfree86/modes: Simplify in_range logic in xf86_crtc_set_cursor_position 2016-06-21 10:40:05 +09:00
xf86cvt.c Drop trailing whitespaces 2014-11-12 10:25:00 +10:00
xf86DiDGA.c Convert hw/xfree86 to new *allocarray functions 2015-04-21 16:58:08 -07:00
xf86EdidModes.c xfree86: Fix the 1792x1344-75 EST III mode 2015-09-23 13:18:22 -04:00
xf86gtf.c Drop trailing whitespaces 2014-11-12 10:25:00 +10:00
xf86Modes.c xfree86 warning reduction 2014-01-12 10:14:49 -08:00
xf86Modes.h Eliminate the use of xf86Rename.h 2013-04-24 10:22:20 -07:00
xf86RandR12.c randr/xf86: Add PRIME Synchronization / Double Buffer 2016-06-28 12:56:17 -04:00
xf86RandR12.h Eliminate the use of xf86Rename.h 2013-04-24 10:22:20 -07:00
xf86Rotate.c xfree86/modes: Disambiguate driverIsPerformingTransform 2016-06-21 10:39:13 +09:00