-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathsync.proto
214 lines (182 loc) · 3.18 KB
/
sync.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
EXTENSION "SYNC" XSync
USE core
REQUESTS
Initialize RESPONDS
ListSystemCounters RESPONDS
CreateCounter
SetCounter
ChangeCounter
QueryCounter RESPONDS
DestroyCounter
Await
CreateAlarm
ChangeAlarm
QueryAlarm RESPONDS
DestroyAlarm
SetPriority
GetPriority RESPONDS
CreateFence
TriggerFence
ResetFence
DestroyFence
QueryFence RESPONDS
AwaitFence /* 19 */
END
EVENTS
CounterNotify
AlarmNotify
END
ERRORS
BadCounter
BadAlarm
END
# XSyncCounter, XSyncAlarm and XSyncFence are just IDs:
TYPE Counter CARD32
TYPE Alarm CARD32
TYPE Fence CARD32
# a XSyncValue is two 32 bit integers meaning on 64 bit one:
TYPE Value INT32_32
CONSTANTS alarm_state
0 Active
1 Inactive
2 Destroyed
END
TYPE AlarmState ENUM8 alarm_state
CONSTANTS test_type
0 PositiveTransition
1 NegativeTransition
2 PositiveComparison
3 NegativeComparison
END
TYPE TestType ENUM32 test_type
CONSTANTS value_type
0 Absolute
1 Relative
END
TYPE ValueType ENUM32 value_type
REQUEST Initialize
4 major-version UINT8
5 minor-version UINT8
END
RESPONSE Initialize
8 major-version UINT8
9 minor-version UINT8
END
LIST SystemCounter variable min-length 14
0 counter Counter
4 resolution Value
12 name_length COUNT16
14 name STRING8
ROUND
END
REQUEST ListSystemCounters ALIASES Empty
RESPONSE ListSystemCounters
8 num-counters COUNT32
32 counter LISTofSystemCounter
END
REQUEST CreateCounter
4 counter Counter
8 initial-value Value
END
REQUEST SetCounter
4 counter Counter
8 value Value
END
REQUEST ChangeCounter
4 counter Counter
8 value Value
END
REQUEST QueryCounter
4 counter Counter
END
RESPONSE QueryCounter
8 value Value
END
REQUEST DestroyCounter
4 counter Counter
END
LIST WaitCondition length 28
0 counter Counter
4 value-type ValueType
8 wait-value Value
16 test-type TestType
20 event-threshold Value
END
REQUEST Await
4 conditions LISTofWaitCondition
END
VALUES AlarmAttributes
1<<0 Counter Counter
1<<1 ValueType ValueType
1<<2 Value Value
1<<3 TestType TestType
1<<4 Delta Value
1<<5 Events BOOL
END
REQUEST CreateAlarm
4 alarm Alarm
8 value-mask STORE16
12 values LISTofAlarmAttributes
END
REQUEST ChangeAlarm
4 alarm Alarm
8 value-mask STORE16
12 values LISTofAlarmAttributes
END
REQUEST QueryAlarm
4 alarm Alarm
END
RESPONSE QueryAlarm
8 counter Counter
12 value-type ValueType
16 wait-value Value
24 test-type TestType
28 delta Value
36 events BOOL
37 state AlarmState
END
REQUEST DestroyAlarm
4 alarm Alarm
END
REQUEST SetPriority
4 client-resource-id CARD32 constants none
8 priority INT32
END
REQUEST GetPriority
4 client-resource-id CARD32 constants none
END
RESPONSE GetPriority
8 priority INT32
END
REQUEST CreateFence
4 drawable DRAWABLE
8 fid Fence
12 initial-triggered BOOL
END
templateREQUEST Fence
4 fid Fence
END
REQUEST TriggerFence ALIASES Fence
REQUEST ResetFence ALIASES Fence
REQUEST DestroyFence ALIASES Fence
REQUEST QueryFence ALIASES Fence
RESPONSE QueryFence
8 triggered BOOL
END
REQUEST AwaitFence ALIASES Empty
EVENT CounterNotify
4 counter Counter
8 wait-value Value
16 counter-value Value
24 time TIMESTAMP
28 count UINT16
30 destroyed BOOL
END
EVENT AlarmNotify
4 alarm Alarm
8 counter-value Value
16 alarm-value Value
24 time TIMESTAMP
28 state AlarmState
END
EOF