diff options
author | Matthieu Herrb <matthieu@cvs.openbsd.org> | 2013-06-07 17:28:57 +0000 |
---|---|---|
committer | Matthieu Herrb <matthieu@cvs.openbsd.org> | 2013-06-07 17:28:57 +0000 |
commit | c0190187060808fe0ad2a09b31f4244757572ff9 (patch) | |
tree | b028697436476ae3ff34218b0b233a233d8a7818 /xserver/Xext/syncsrv.h | |
parent | 33eda071f5846d332b428de759c5b1649e9cf1ba (diff) |
Update to X server 1.14.1. Tested by many during t2k13. Thanks.
Diffstat (limited to 'xserver/Xext/syncsrv.h')
-rw-r--r-- | xserver/Xext/syncsrv.h | 56 |
1 files changed, 25 insertions, 31 deletions
diff --git a/xserver/Xext/syncsrv.h b/xserver/Xext/syncsrv.h index b0464b304..c68229f46 100644 --- a/xserver/Xext/syncsrv.h +++ b/xserver/Xext/syncsrv.h @@ -51,6 +51,7 @@ PERFORMANCE OF THIS SOFTWARE. #ifndef _SYNCSRV_H_ #define _SYNCSRV_H_ +#include "list.h" #include "misync.h" #include "misyncstr.h" @@ -65,19 +66,25 @@ typedef enum { XSyncCounterUnrestricted } SyncCounterType; +typedef void (*SyncSystemCounterQueryValue)(pointer counter, + CARD64 *value_return + ); +typedef void (*SyncSystemCounterBracketValues)(pointer counter, + CARD64 *pbracket_less, + CARD64 *pbracket_greater + ); + typedef struct _SysCounterInfo { - const char *name; + SyncCounter *pCounter; + char *name; CARD64 resolution; CARD64 bracket_greater; CARD64 bracket_less; SyncCounterType counterType; /* how can this counter change */ - void (*QueryValue) (pointer /*pCounter */ , - CARD64 * /*freshvalue */ - ); - void (*BracketValues) (pointer /*pCounter */ , - CARD64 * /*lessthan */ , - CARD64 * /*greaterthan */ - ); + SyncSystemCounterQueryValue QueryValue; + SyncSystemCounterBracketValues BracketValues; + void *private; + struct xorg_list entry; } SysCounterInfo; typedef struct _SyncAlarmClientList { @@ -113,33 +120,20 @@ typedef union { SyncAwait await; } SyncAwaitUnion; -extern pointer SyncCreateSystemCounter(const char * /* name */ , - CARD64 /* inital_value */ , - CARD64 /* resolution */ , - SyncCounterType - /* change characterization */ , - void (* /*QueryValue */ )( - pointer - /* pCounter */ - , - CARD64 * /* pValue_return */ ), /* XXX prototype */ - void (* /*BracketValues */ )( - pointer - /* pCounter */ - , - CARD64 * - /* pbracket_less */ - , - CARD64 * - /* pbracket_greater */ - ) +extern SyncCounter* SyncCreateSystemCounter(const char *name, + CARD64 initial_value, + CARD64 resolution, + SyncCounterType counterType, + SyncSystemCounterQueryValue QueryValue, + SyncSystemCounterBracketValues BracketValues ); -extern void SyncChangeCounter(SyncCounter * /* pCounter */ , - CARD64 /* new_value */ +extern void SyncChangeCounter(SyncCounter *pCounter, + CARD64 new_value ); extern void SyncDestroySystemCounter(pointer pCounter); -extern void SyncExtensionInit(void); +extern SyncCounter *SyncInitDeviceIdleTime(DeviceIntPtr dev); +extern void SyncRemoveDeviceIdleTime(SyncCounter *counter); #endif /* _SYNCSRV_H_ */ |