PageRenderTime 8ms CodeModel.GetById 6ms app.highlight 0ms RepoModel.GetById 1ms app.codeStats 0ms

/contrib/ntp/kernel/sys/clkdefs.h

https://bitbucket.org/freebsd/freebsd-head/
C++ Header | 38 lines | 14 code | 6 blank | 18 comment | 0 complexity | 5f5d87df30eff2f2918c1c2e062a697e MD5 | raw file
 1/*
 2 * Defines for the "clk" timestamping STREAMS module
 3 */
 4
 5#if defined(sun)
 6#include <sys/ioccom.h>
 7#else
 8#include <sys/ioctl.h>
 9#endif
10
11/*
12 * First, we need to define the maximum size of the set of
13 * characters to timestamp. 32 is MORE than enough.
14 */
15
16#define CLK_MAXSTRSIZE 32
17struct clk_tstamp_charset {		/* XXX to use _IOW not _IOWN */
18	char	val[CLK_MAXSTRSIZE];
19};
20
21/*
22 * ioctl(fd, CLK_SETSTR, (char*)c );
23 *
24 * will tell the driver that any char in the null-terminated
25 * string c should be timestamped. It is possible, though
26 * unlikely that this ioctl number could collide with an
27 * existing one on your system. If so, change the 'K'
28 * to some other letter. However, once you've compiled
29 * the kernel with this include file, you should NOT
30 * change this file.
31 */
32
33#if defined(__STDC__)			/* XXX avoid __STDC__=0 on SOLARIS */
34#define CLK_SETSTR _IOW('K', 01, struct clk_tstamp_charset)
35#else
36#define CLK_SETSTR _IOW(K, 01, struct clk_tstamp_charset)
37#endif
38