Merge branch 'test' into 'master'

exa: use dixRegisterPrivateKey to create PRIVATE PIXMAP

See merge request xorg/xserver!2067
This commit is contained in:
Ou Shixiong 2026-02-04 12:05:14 +00:00
commit 8480190467
2 changed files with 4 additions and 4 deletions

View file

@ -36,6 +36,7 @@
#include "exa.h"
DevPrivateKeyRec exaScreenPrivateKeyRec;
DevPrivateKeyRec exaPixmapPrivateKeyRec;
#ifdef MITSHM
static ShmFuncs exaShmFuncs = { NULL, NULL };
@ -945,8 +946,7 @@ exaDriverInit(ScreenPtr pScreen, ExaDriverPtr pScreenInfo)
* Hookup offscreen pixmaps
*/
if (pExaScr->info->flags & EXA_OFFSCREEN_PIXMAPS) {
if (!dixRegisterScreenSpecificPrivateKey
(pScreen, &pExaScr->pixmapPrivateKeyRec, PRIVATE_PIXMAP,
if (!dixRegisterPrivateKey(&exaPixmapPrivateKeyRec, PRIVATE_PIXMAP,
sizeof(ExaPixmapPrivRec))) {
LogMessage(X_WARNING,
"EXA(%d): Failed to allocate pixmap private\n",

View file

@ -210,11 +210,11 @@ typedef struct {
PixmapPtr srcPix;
PixmapPtr maskPix;
DevPrivateKeyRec pixmapPrivateKeyRec;
DevPrivateKeyRec gcPrivateKeyRec;
} ExaScreenPrivRec, *ExaScreenPrivPtr;
extern DevPrivateKeyRec exaScreenPrivateKeyRec;
extern DevPrivateKeyRec exaPixmapPrivateKeyRec;
#define exaScreenPrivateKey (&exaScreenPrivateKeyRec)
@ -272,7 +272,7 @@ extern DevPrivateKeyRec exaScreenPrivateKeyRec;
#define EXA_PIXMAP_SCORE_PINNED 1000
#define EXA_PIXMAP_SCORE_INIT 1001
#define ExaGetPixmapPriv(p) ((ExaPixmapPrivPtr)dixGetPrivateAddr(&(p)->devPrivates, &ExaGetScreenPriv((p)->drawable.pScreen)->pixmapPrivateKeyRec))
#define ExaGetPixmapPriv(p) ((ExaPixmapPrivPtr)dixLookupPrivate(&p->devPrivates, &exaPixmapPrivateKeyRec))
#define ExaPixmapPriv(p) ExaPixmapPrivPtr pExaPixmap = ExaGetPixmapPriv(p)
#define EXA_RANGE_PITCH (1 << 0)