This file is indexed.

/usr/include/xenomai/vrtx/vrtx.h is in libxenomai-dev 2.6.4+dfsg-0.2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  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
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
/*
 * Copyright (C) 2001,2002 IDEALX (http://www.idealx.com/).
 * Written by Julien Pinon <jpinon@idealx.com>.
 * Copyright (C) 2003 Philippe Gerum <rpm@xenomai.org>.
 *
 * Xenomai 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 2 of the License, or
 * (at your option) any later version.
 *
 * Xenomai 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 Xenomai; if not, write to the Free Software Foundation,
 * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 */

#ifndef _XENO_VRTX_VRTX_H
#define _XENO_VRTX_VRTX_H

#include <nucleus/heap.h>

#define VRTX_SKIN_MAGIC    0x56525458
#define VRTX_SKIN_VERSION  6

#define TBSSUSP   0x0001
#define TBSMBOX   0x0002
#define TBSPUTC   0x0008
#define TBSDELAY  0x0020
#define TBSQUEUE  0x0040
#define TBSIDLE   0x0100
#define TBSFLAG   0x0200
#define TBSSEMA   0x0400
#define TBSMUTEX  0x0800
#define TBSADELAY 0x8000

#define RET_OK   0x00
#define ER_TID   0x01
#define ER_TCB   0x02
#define ER_MEM   0x03
#define ER_NMB   0x04
#define ER_MIU   0x05
#define ER_ZMW   0x06
#define ER_BUF   0x07
#define ER_TMO   0x0A
#define ER_NMP   0x0B
#define ER_QID   0x0C
#define ER_QFL   0x0D
#define ER_PID   0x0E
#define ER_IIP   0x12
#define ER_NOCB  0x30
#define ER_ID    0x31
#define ER_PND   0x32
#define ER_DEL   0x33
#define ER_OVF   0x34

#define seconds      tv_sec
#define nanoseconds  tv_nsec

typedef struct _TCB {

	int TCBSTAT;

} TCB;

typedef struct _vrtx_hdesc {
	int hid;
	void *hcb;
	size_t hsize;
	unsigned long area;
} vrtx_hdesc_t;

typedef struct _vrtx_pdesc {
	int pid;
	void *ptcb;
	size_t ptsize;
	unsigned long area;
} vrtx_pdesc_t;

#if defined(__KERNEL__) || defined(__XENO_SIM__)

#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */

void ui_timer(void);

#ifdef __cplusplus
};
#endif /* __cplusplus */

#else /* !(__KERNEL__ || __XENO_SIM__) */

#include <vrtx/syscall.h>

#endif /* __KERNEL__ || __XENO_SIM__ */

/*
 * The following macros return normalized or native VRTX priority
 * values. The core scheduler uses an ascending [0-257] priority scale
 * (include/nucleus/sched.h), whilst the VRTX personality exhibits a
 * decreasing scale [255-0]; normalization is done in the [1-256]
 * range so that priority 0 is kept for non-realtime shadows.
 */
#define vrtx_normalized_prio(prio)  \
  ({ int __p = (prio) ? XNSCHED_RT_MAX_PRIO - (prio) - 1 : 0; __p; })
#define vrtx_denormalized_prio(prio) \
  ({ int __p = (prio) ? 256 - (prio) : 0; __p; })

#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */

void sc_putc(int c);

int sc_tecreate(void (*entry)(void *),
		int tid,
		int prio,
		int mode,
		unsigned long user,
		unsigned long sys,
		char *paddr,
		unsigned long psize,
		int *errp) __deprecated_in_kernel__;

int sc_tcreate(void (*entry)(void*),
	       int tid,
	       int prio,
	       int *errp) __deprecated_in_kernel__;

void sc_tdelete(int tid,
		int opt,
		int *errp);

TCB *sc_tinquiry(int pinfo[],
		 int tid,
		 int *errp);

void sc_tpriority(int tid,
		  int prio,
		  int *errp);

void sc_tresume(int tid,
		int opt,
		int *errp);

void sc_tslice(unsigned short ticks);

void sc_tsuspend(int tid,
		 int opt,
		 int *errp);

void sc_lock(void);

void sc_unlock(void);

int sc_mcreate(unsigned int opt,
	       int *errp);

void sc_maccept(int mid,
		int *errp);

void sc_mdelete(int mid,
		int opt, int *errp);

int sc_minquiry(int mid,
		int *errp);

void sc_mpend(int mid,
	      unsigned long timeout,
	      int *errp);

void sc_mpost(int mid,
	      int *errp);

int sc_qcreate(int qid,
	       int qsize,
	       int *errp);

int sc_qecreate(int qid,
		int qsize,
		int opt,
		int *errp);

void sc_qdelete(int qid,
		int opt,
		int *errp);

void sc_qjam(int qid,
	     char *msg,
	     int *errp);

void sc_qpost(int qid,
	      char *msg,
	      int *errp);

void sc_qbrdcst(int qid,
	       char *msg,
	       int *errp);

char *sc_qaccept(int qid,
		 int *errp);

char *sc_qinquiry(int qid,
		  int *countp,
		  int *errp);

char *sc_qpend(int qid,
	       long timeout,
	       int *errp);

void sc_post(char **mboxp,
	     char *msg,
	     int *errp);

char *sc_accept(char **mboxp,
		int *errp);

char *sc_pend(char **mboxp,
	      long timeout,
	      int *errp);

int sc_fcreate(int *errp);

void sc_fdelete(int fid,
		int opt,
		int *errp);

void sc_fpost(int fid,
	      int mask,
	      int *errp);

int sc_fpend(int fid,
	     long timeout,
	     int mask,
	     int opt,
	     int *errp);

int sc_fclear(int fid,
	      int mask,
	      int *errp);

int sc_finquiry(int fid,
		int *errp);

int sc_screate(unsigned initval,
	       int opt,
	       int *errp);

void sc_sdelete(int semid,
		int opt,
		int *errp);

void sc_spend(int semid,
	      long timeout,
	      int *errp);

void sc_saccept(int semid,
	      int *errp);

void sc_spost(int semid,
	      int *errp);

int sc_sinquiry(int semid,
		int *errp);

int sc_pcreate(int pid,
	       char *paddr,
	       long psize,
	       long bsize,
	       int *errp);

void sc_pdelete(int tid,
		int opt,
		int *errp);

void sc_pextend(int pid,
		char *eaddr,
		long esize,
		int *errp);

void sc_pinquiry(unsigned long info[3],
		 int pid,
		 int *errp);

char *sc_gblock(int pid,
		int *errp);

void sc_rblock(int pid,
	       char *blockp,
	       int *errp);

int sc_hcreate(char *heapaddr,
	       unsigned long heapsize,
	       unsigned log2psize,
	       int *errp);

void sc_hdelete(int hid,
		int opt,
		int *errp);

char *sc_halloc(int hid,
		unsigned long size,
		int *errp);

void sc_hfree(int hid,
	      char *block,
	      int *errp);

void sc_hinquiry(int info[3],
		 int hid,
		 int *errp);

void sc_delay(long timeout);

void sc_adelay (struct timespec time,
		int *errp);

void sc_stime(unsigned long ticks);

unsigned long sc_gtime(void);

void sc_gclock(struct timespec *timep,
	       unsigned long *nsp,
	       int *errp);

void sc_sclock(struct timespec time,
	       unsigned long ns,
	       int *errp);

int sc_gversion(void);

#ifdef __cplusplus
};
#endif /* __cplusplus */

#endif /* !_XENO_VRTX_VRTX_H */