dix: make RESOURCE_ID_MASK private

Not used by any external drivers, so no need to keep it exported.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
This commit is contained in:
Enrico Weigelt, metux IT consult 2025-03-06 17:00:49 +01:00
parent bd29dc5adf
commit ec8b5379b8
4 changed files with 7 additions and 2 deletions

View File

@ -1,6 +1,9 @@
#include <dix-config.h> #include <dix-config.h>
#include <stdlib.h> #include <stdlib.h>
#include "dix/resource_priv.h"
#include "misc.h" #include "misc.h"
#include "hashtable.h" #include "hashtable.h"

View File

@ -23,6 +23,9 @@
/* extract the client mask from an XID */ /* extract the client mask from an XID */
#define CLIENT_BITS(id) ((id) & RESOURCE_CLIENT_MASK) #define CLIENT_BITS(id) ((id) & RESOURCE_CLIENT_MASK)
/* resource field */
#define RESOURCE_ID_MASK ((1 << CLIENTOFFSET) - 1)
/* /*
* @brief retrieve client that owns given window * @brief retrieve client that owns given window
* *

View File

@ -50,6 +50,7 @@
#include <sys/types.h> #include <sys/types.h>
#include <grp.h> #include <grp.h>
#include "dix/resource_priv.h"
#include "os/osdep.h" #include "os/osdep.h"
#include "xf86.h" #include "xf86.h"

View File

@ -103,8 +103,6 @@ extern _X_EXPORT unsigned int ResourceClientBits(void);
/* bits and fields within a resource id */ /* bits and fields within a resource id */
#define RESOURCE_AND_CLIENT_COUNT 29 /* 29 bits for XIDs */ #define RESOURCE_AND_CLIENT_COUNT 29 /* 29 bits for XIDs */
#define CLIENTOFFSET (RESOURCE_AND_CLIENT_COUNT - ResourceClientBits()) #define CLIENTOFFSET (RESOURCE_AND_CLIENT_COUNT - ResourceClientBits())
/* resource field */
#define RESOURCE_ID_MASK ((1 << CLIENTOFFSET) - 1)
#ifdef INVALID #ifdef INVALID
#undef INVALID /* needed on HP/UX */ #undef INVALID /* needed on HP/UX */