Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RandR backports (X.org commits 2016+17) #391

Open
wants to merge 33 commits into
base: 3.6.x
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
5a2587d
os/xdmcp: Just send XDMCP keepalive packets once every three minute
keith-packard Feb 9, 2017
94d277d
Xserver/include/list.h: Add list.h from X.org (from X.org commit 63f8…
sunweaver Feb 9, 2017
cd728ff
os: Add NotifyFd interfaces
keith-packard Feb 9, 2017
f6a4bf2
Move the code for resetting the DPMS mode in response to input events…
Feb 9, 2017
56a5b91
os: Implement support for NotifyFd X_NOTIFY_WRITE and removal of AddE…
keith-packard Feb 9, 2017
1c438c1
nxagent: Use SetNotifyFd to receive events.
sunweaver Feb 9, 2017
2afe095
os: Initialize NotifyFds earlier in startup
sunweaver Feb 24, 2017
af51430
randr: Do not update ConnectionInfo if NULL
ofourdan Mar 10, 2017
2b7d520
xrandrprovider: Do not use separate lists for unbound / source / offl…
jwrdegoede Mar 10, 2017
76d5d64
randr: Adjust master's last set time with slaves
nmahale Mar 10, 2017
6374843
randr: Fix crtc_bounds when using rotation combined with reflection
jwrdegoede Mar 10, 2017
64ee3a3
randr: rrCheckPixmapBounding: Do not substract crtc non 0 x,y from sc…
jwrdegoede Mar 10, 2017
086630f
randr: rrCheckPixmapBounding: do not shrink the screen_pixmap
jwrdegoede Mar 10, 2017
c2d9adf
xinerama: Swap the response in RRXineramaWriteMonitor
Mar 10, 2017
6f638c3
randr: fix xserver crash when xrandr setprovideroutputsource
yuq Mar 10, 2017
52fdf57
Add CreatePixmap allocation hints.
aaronp24 Feb 22, 2017
edb2a9e
Mesa.patches: Adapt Mesa to CreatePixmap allocation hint ABI bump.
sunweaver Mar 11, 2017
3377b02
hw/nxagent/Pixmap.c et al.: Propagate usage_hint through nxagentCreat…
sunweaver Feb 22, 2017
03850d6
Save pixmap allocation hints into the PixmapRec.
sunweaver Feb 22, 2017
953a7c7
dix: pixmap sharing infrastructure (v3)
airlied Mar 10, 2017
a96761f
dix: Move AddScreen() over into dispatch.c and introduce init_screen()
sunweaver Mar 10, 2017
3924a10
Move AddScreen() comment where it actually belongs. Should be done in…
sunweaver Mar 10, 2017
84329a1
Mesa subtree: Add quilt based patch system for bundled Mesa.
sunweaver Feb 20, 2017
b65272d
dix: Remove insane BC hacks
sunweaver Mar 10, 2017
b5da769
xserver: remove index from CloseScreen (API/ABI breakage)
airlied Mar 10, 2017
c806b1a
dix: make Create/Free scratch pixmaps take a ScreenPtr
airlied Mar 11, 2017
a414f74
dix: introduce gpu screens. (v5)
airlied Mar 10, 2017
e2b323e
dix: add unattached list for attaching screens to initially. (v1.1)
airlied Mar 11, 2017
3cacd47
randr: fixup+complete scanout pixmap support by adapting the dix.
airlied Mar 10, 2017
c4cead5
randr(/xf86): Add PRIME Synchronization / Double Buffer
AlexGoinsNV Mar 10, 2017
b735346
xf86: Add PRIME flipping functions to Screen
AlexGoinsNV Mar 10, 2017
ae21a94
randr: Add ability to turn PRIME sync off
AlexGoinsNV Mar 10, 2017
2bdba8e
randr: Add RRHasScanoutPixmap helper function
jwrdegoede Mar 10, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ SHELL:=/bin/bash

# clean auto-generated nxversion.def file \
if [ "x$@" == "xclean" ] || [ "x$@" = "xdistclean" ]; then \
./mesa-quilt pop -a; \
rm -Rf nx-X11/extras/Mesa/.pc/; \
rm -f nx-X11/config/cf/nxversion.def; \
rm -f bin/nxagent; \
rm -f bin/nxproxy; \
Expand Down Expand Up @@ -72,6 +74,7 @@ build-full:

cd nxcompshad && autoconf && (${CONFIGURE}) && ${MAKE}

./mesa-quilt push -a
cd nx-X11 && ${MAKE} World USRLIBDIR=$(USRLIBDIR) SHLIBDIR=$(SHLIBDIR)

cd nxproxy && autoconf && (${CONFIGURE}) && ${MAKE}
Expand Down
34 changes: 34 additions & 0 deletions mesa-quilt
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
#!/bin/bash

# Copyright (C) 2017 by Mike Gabriel <[email protected]>
#
# This is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# This is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the
# Free Software Foundation, Inc.,
# 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.

d=. ; while [ ! -d $d/nx-X11/extras -a `readlink -e $d` != / ]; do d=$d/..; done
if [ -d $d/nx-X11/extras ] && [ -z $QUILT_PATCHES ]; then
# if in Debian packaging tree with unset $QUILT_PATCHES
export QUILT_PATCHES="../Mesa.patches"
export QUILT_PATCH_OPTS="--reject-format=unified"
export QUILT_DIFF_ARGS="-p ab --no-timestamps --no-index --color=auto"
export QUILT_REFRESH_ARGS="-p ab --no-timestamps --no-index"
export QUILT_COLORS="diff_hdr=1;32:diff_add=1;34:diff_rem=1;31:diff_hunk=1;33:diff_ctx=35:diff_cctx=33"
if ! [ -d $d/nx-X11/extras/Mesa.patches ]; then mkdir $d/nx-X11/extras/Mesa.patches; fi
cd $d/nx-X11/extras/Mesa/
fi

quilt $@

cd - 1> /dev/null
13 changes: 13 additions & 0 deletions nx-X11/extras/Mesa.patches/4001_CreatePixmap-AllocationHints.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Index: Mesa/include/GL/xmesa_xf86.h
===================================================================
--- Mesa.orig/include/GL/xmesa_xf86.h
+++ Mesa/include/GL/xmesa_xf86.h
@@ -130,7 +130,7 @@ do { \

/* CreatePixmap returns a PixmapPtr; so, it cannot be inside braces */
#define XMesaCreatePixmap(__d,__b,__w,__h,__depth) \
- (*__d->CreatePixmap)(__d, __w, __h, __depth)
+ (*__d->CreatePixmap)(__d, __w, __h, __depth, 0)

#define XMesaFreePixmap(__d,__b) \
(*__d->DestroyPixmap)(__b)
1 change: 1 addition & 0 deletions nx-X11/extras/Mesa.patches/series
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
4001_CreatePixmap-AllocationHints.patch
2 changes: 1 addition & 1 deletion nx-X11/extras/Mesa/include/GL/xmesa_xf86.h
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ do { \

/* CreatePixmap returns a PixmapPtr; so, it cannot be inside braces */
#define XMesaCreatePixmap(__d,__b,__w,__h,__depth) \
(*__d->CreatePixmap)(__d, __w, __h, __depth)
(*__d->CreatePixmap)(__d, __w, __h, __depth, 0)

#define XMesaFreePixmap(__d,__b) \
(*__d->DestroyPixmap)(__b)
Expand Down
4 changes: 2 additions & 2 deletions nx-X11/programs/Xserver/Xext/panoramiX.c
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ GCFuncs XineramaGCFuncs = {


static Bool
XineramaCloseScreen (int i, ScreenPtr pScreen)
XineramaCloseScreen (ScreenPtr pScreen)
{
PanoramiXScreenPtr pScreenPriv =
(PanoramiXScreenPtr) pScreen->devPrivates[PanoramiXScreenIndex].ptr;
Expand All @@ -163,7 +163,7 @@ XineramaCloseScreen (int i, ScreenPtr pScreen)

free ((void *) pScreenPriv);

return (*pScreen->CloseScreen) (i, pScreen);
return (*pScreen->CloseScreen) (pScreen);
}

Bool
Expand Down
5 changes: 3 additions & 2 deletions nx-X11/programs/Xserver/Xext/shm.c
Original file line number Diff line number Diff line change
Expand Up @@ -506,7 +506,8 @@ miShmPutImage(dst, pGC, depth, format, w, h, sx, sy, sw, sh, dx, dy, data)
putGC = GetScratchGC(depth, dst->pScreen);
if (!putGC)
return;
pmap = (*dst->pScreen->CreatePixmap)(dst->pScreen, sw, sh, depth);
pmap = (*dst->pScreen->CreatePixmap)(dst->pScreen, sw, sh, depth,
CREATE_PIXMAP_USAGE_SCRATCH);
if (!pmap)
{
FreeScratchGC(putGC);
Expand Down Expand Up @@ -1052,7 +1053,7 @@ fbShmCreatePixmap (pScreen, width, height, depth, addr)
{
register PixmapPtr pPixmap;

pPixmap = (*pScreen->CreatePixmap)(pScreen, 0, 0, pScreen->rootDepth);
pPixmap = (*pScreen->CreatePixmap)(pScreen, 0, 0, pScreen->rootDepth, 0);
if (!pPixmap)
return NullPixmap;

Expand Down
2 changes: 1 addition & 1 deletion nx-X11/programs/Xserver/Xext/xvdix.h
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ typedef struct {
DestroyWindowProcPtr DestroyWindow;
DestroyPixmapProcPtr DestroyPixmap;
CloseScreenProcPtr CloseScreen;
Bool (* ddCloseScreen)(int, ScreenPtr);
Bool (* ddCloseScreen)(ScreenPtr);
int (* ddQueryAdaptors)(ScreenPtr, XvAdaptorPtr*, int*);
DevUnion devPriv;
} XvScreenRec, *XvScreenPtr;
Expand Down
7 changes: 3 additions & 4 deletions nx-X11/programs/Xserver/Xext/xvmain.c
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ static void WriteSwappedVideoNotifyEvent(xvEvent *, xvEvent *);
static void WriteSwappedPortNotifyEvent(xvEvent *, xvEvent *);
static Bool CreateResourceTypes(void);

static Bool XvCloseScreen(int, ScreenPtr);
static Bool XvCloseScreen(ScreenPtr);
static Bool XvDestroyPixmap(PixmapPtr);
static Bool XvDestroyWindow(WindowPtr);
static void XvResetProc(ExtensionEntry*);
Expand Down Expand Up @@ -307,7 +307,6 @@ XvScreenInit(ScreenPtr pScreen)

static Bool
XvCloseScreen(
int ii,
ScreenPtr pScreen
){

Expand All @@ -319,13 +318,13 @@ XvCloseScreen(
pScreen->DestroyWindow = pxvs->DestroyWindow;
pScreen->CloseScreen = pxvs->CloseScreen;

(* pxvs->ddCloseScreen)(ii, pScreen);
(* pxvs->ddCloseScreen)(pScreen);

free(pxvs);

pScreen->devPrivates[XvScreenIndex].ptr = (void *)NULL;

return (*pScreen->CloseScreen)(ii, pScreen);
return (*pScreen->CloseScreen)(pScreen);

}

Expand Down
4 changes: 2 additions & 2 deletions nx-X11/programs/Xserver/Xext/xvmc.c
Original file line number Diff line number Diff line change
Expand Up @@ -696,15 +696,15 @@ XvMCExtensionInit()
}

static Bool
XvMCCloseScreen (int i, ScreenPtr pScreen)
XvMCCloseScreen (ScreenPtr pScreen)
{
XvMCScreenPtr pScreenPriv = XVMC_GET_PRIVATE(pScreen);

pScreen->CloseScreen = pScreenPriv->CloseScreen;

free(pScreenPriv);

return (*pScreen->CloseScreen)(i, pScreen);
return (*pScreen->CloseScreen)(pScreen);
}


Expand Down
4 changes: 2 additions & 2 deletions nx-X11/programs/Xserver/composite/compalloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -539,8 +539,8 @@ compNewPixmap (WindowPtr pWin, int x, int y, int w, int h)
PixmapPtr pPixmap;

/* usage_hint unsupported by our old server infrastructure. */
pPixmap = (*pScreen->CreatePixmap) (pScreen, w, h, pWin->drawable.depth /*,
CREATE_PIXMAP_USAGE_BACKING_PIXMAP */);
pPixmap = (*pScreen->CreatePixmap) (pScreen, w, h, pWin->drawable.depth,
CREATE_PIXMAP_USAGE_BACKING_PIXMAP);

if (!pPixmap)
return 0;
Expand Down
4 changes: 2 additions & 2 deletions nx-X11/programs/Xserver/composite/compinit.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ int CompSubwindowsPrivIndex = -1;
#endif

static Bool
compCloseScreen (int index, ScreenPtr pScreen)
compCloseScreen (ScreenPtr pScreen)
{
CompScreenPtr cs = GetCompScreen (pScreen);
Bool ret;
Expand Down Expand Up @@ -78,7 +78,7 @@ compCloseScreen (int index, ScreenPtr pScreen)

free (cs);
FAKE_DIX_SET_SCREEN_PRIVATE(pScreen, NULL);
ret = (*pScreen->CloseScreen) (index, pScreen);
ret = (*pScreen->CloseScreen) (pScreen);
return ret;
}

Expand Down
8 changes: 4 additions & 4 deletions nx-X11/programs/Xserver/dbe/midbe.c
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ miDbeAllocBackBufferName(pWin, bufId, swapAction)
if (!(pDbeWindowPrivPriv->pFrontBuffer =
(*pScreen->CreatePixmap)(pScreen, pDbeWindowPriv->width,
pDbeWindowPriv->height,
pWin->drawable.depth)))
pWin->drawable.depth, 0)))
{
return(BadAlloc);
}
Expand All @@ -197,7 +197,7 @@ miDbeAllocBackBufferName(pWin, bufId, swapAction)
if (!(pDbeWindowPrivPriv->pBackBuffer =
(*pScreen->CreatePixmap)(pScreen, pDbeWindowPriv->width,
pDbeWindowPriv->height,
pWin->drawable.depth)))
pWin->drawable.depth, 0)))
{
(*pScreen->DestroyPixmap)(pDbeWindowPrivPriv->pFrontBuffer);
return(BadAlloc);
Expand Down Expand Up @@ -668,10 +668,10 @@ miDbePositionWindow(pWin, x, y)

/* Create DBE buffer pixmaps equal to size of resized window. */
pFrontBuffer = (*pScreen->CreatePixmap)(pScreen, width, height,
pWin->drawable.depth);
pWin->drawable.depth, 0);

pBackBuffer = (*pScreen->CreatePixmap)(pScreen, width, height,
pWin->drawable.depth);
pWin->drawable.depth, 0);

if (!pFrontBuffer || !pBackBuffer)
{
Expand Down
Loading