blob: 3f97606751a656539558a8285bcbf6523860a83d [file] [log] [blame]
Guido van Rossum2242f2f2001-04-11 20:58:20 +00001# Generated by h2py from /usr/include/netinet/in.h
2
3# Included from netinet/in_f.h
4def IN_CLASSA(i): return (((long)(i) & 0x80000000) == 0)
5
6IN_CLASSA_NET = 0xff000000
7IN_CLASSA_NSHIFT = 24
8IN_CLASSA_HOST = 0x00ffffff
9IN_CLASSA_MAX = 128
10def IN_CLASSB(i): return (((long)(i) & 0xc0000000) == 0x80000000)
11
12IN_CLASSB_NET = 0xffff0000
13IN_CLASSB_NSHIFT = 16
14IN_CLASSB_HOST = 0x0000ffff
15IN_CLASSB_MAX = 65536
16def IN_CLASSC(i): return (((long)(i) & 0xe0000000) == 0xc0000000)
17
18IN_CLASSC_NET = 0xffffff00
19IN_CLASSC_NSHIFT = 8
20IN_CLASSC_HOST = 0x000000ff
21def IN_CLASSD(i): return (((long)(i) & 0xf0000000) == 0xe0000000)
22
23IN_CLASSD_NET = 0xf0000000
24IN_CLASSD_NSHIFT = 28
25IN_CLASSD_HOST = 0x0fffffff
26def IN_MULTICAST(i): return IN_CLASSD(i)
27
28def IN_EXPERIMENTAL(i): return (((long)(i) & 0xe0000000) == 0xe0000000)
29
30def IN_BADCLASS(i): return (((long)(i) & 0xf0000000) == 0xf0000000)
31
32INADDR_ANY = 0x00000000
33INADDR_LOOPBACK = 0x7f000001
34INADDR_BROADCAST = 0xffffffff
35INADDR_NONE = 0xffffffff
36IN_LOOPBACKNET = 127
37INADDR_UNSPEC_GROUP = 0xe0000000
38INADDR_ALLHOSTS_GROUP = 0xe0000001
39INADDR_ALLRTRS_GROUP = 0xe0000002
40INADDR_MAX_LOCAL_GROUP = 0xe00000ff
41
42# Included from netinet/in6.h
43
44# Included from sys/types.h
45def quad_low(x): return x.val[0]
46
47ADT_EMASKSIZE = 8
48SHRT_MIN = -32768
49SHRT_MAX = 32767
50INT_MIN = (-2147483647-1)
51INT_MAX = 2147483647
52LONG_MIN = (-2147483647-1)
53LONG_MAX = 2147483647
54OFF32_MAX = LONG_MAX
55ISTAT_ASSERTED = 0
56ISTAT_ASSUMED = 1
57ISTAT_NONE = 2
58OFF_MAX = OFF32_MAX
59CLOCK_MAX = LONG_MAX
60P_MYID = (-1)
61P_MYHOSTID = (-1)
62
63# Included from sys/select.h
64FD_SETSIZE = 4096
65NBBY = 8
66NULL = 0
67
68# Included from sys/bitypes.h
69
70# Included from netinet/in6_f.h
71def IN6_IS_ADDR_UNSPECIFIED(a): return IN6_ADDR_EQUAL_L(a, 0, 0, 0, 0)
72
73def IN6_SET_ADDR_UNSPECIFIED(a): return IN6_ADDR_COPY_L(a, 0, 0, 0, 0)
74
75def IN6_IS_ADDR_ANY(a): return IN6_ADDR_EQUAL_L(a, 0, 0, 0, 0)
76
77def IN6_SET_ADDR_ANY(a): return IN6_ADDR_COPY_L(a, 0, 0, 0, 0)
78
79def IN6_IS_ADDR_LOOPBACK(a): return IN6_ADDR_EQUAL_L(a, 0, 0, 0, 0x01000000)
80
81def IN6_SET_ADDR_LOOPBACK(a): return IN6_ADDR_COPY_L(a, 0, 0, 0, 0x01000000)
82
83IN6_MC_FLAG_PERMANENT = 0x0
84IN6_MC_FLAG_TRANSIENT = 0x1
85IN6_MC_SCOPE_NODELOCAL = 0x1
86IN6_MC_SCOPE_LINKLOCAL = 0x2
87IN6_MC_SCOPE_SITELOCAL = 0x5
88IN6_MC_SCOPE_ORGLOCAL = 0x8
89IN6_MC_SCOPE_GLOBAL = 0xE
90def IN6_IS_ADDR_MC_NODELOCAL(a): return \
91
92def IN6_IS_ADDR_MC_LINKLOCAL(a): return \
93
94def IN6_IS_ADDR_MC_SITELOCAL(a): return \
95
96def IN6_IS_ADDR_MC_ORGLOCAL(a): return \
97
98def IN6_IS_ADDR_MC_GLOBAL(a): return \
99
100
101# Included from sys/convsa.h
102__NETLIB_UW211_SVR4 = 1
103__NETLIB_UW211_XPG4 = 2
104__NETLIB_GEMINI_SVR4 = 3
105__NETLIB_GEMINI_XPG4 = 4
106__NETLIB_FP1_SVR4 = 5
107__NETLIB_FP1_XPG4 = 6
108__NETLIB_BASE_VERSION__ = __NETLIB_UW211_SVR4
109__NETLIB_VERSION__ = __NETLIB_FP1_SVR4
110__NETLIB_VERSION__ = __NETLIB_FP1_XPG4
111__NETLIB_VERSION__ = __NETLIB_GEMINI_SVR4
112__NETLIB_VERSION__ = __NETLIB_GEMINI_XPG4
113__NETLIB_VERSION__ = __NETLIB_UW211_SVR4
114__NETLIB_VERSION__ = __NETLIB_UW211_XPG4
115__NETLIB_VERSION__ = __NETLIB_FP1_XPG4
116
117# Included from sys/byteorder.h
118LITTLE_ENDIAN = 1234
119BIG_ENDIAN = 4321
120PDP_ENDIAN = 3412
121
122# Included from sys/byteorder_f.h
123BYTE_ORDER = LITTLE_ENDIAN
124def htonl(hl): return __htonl(hl)
125
126def ntohl(nl): return __ntohl(nl)
127
128def htons(hs): return __htons(hs)
129
130def ntohs(ns): return __ntohs(ns)
131
132def ntohl(x): return (x)
133
134def ntohs(x): return (x)
135
136def htonl(x): return (x)
137
138def htons(x): return (x)
139
140def __NETLIB_VERSION_IS_XPG4(version): return (((version) % 2) == 0)
141
142def __NETLIB_VERSION_HAS_SALEN(version): return ((version) >= __NETLIB_GEMINI_SVR4)
143
144def __NETLIB_VERSION_IS_IKS(version): return ((version) >= __NETLIB_FP1_SVR4)
145
146def SA_FAMILY_GET(sa): return \
147
148INET6_ADDRSTRLEN = 46
149IPV6_UNICAST_HOPS = 3
150IPV6_ADDRFORM = 24
151IPV6_MULTICAST_HOPS = 25
152IPV6_MULTICAST_IF = 26
153IPV6_MULTICAST_LOOP = 27
154IPV6_ADD_MEMBERSHIP = 28
155IPV6_DROP_MEMBERSHIP = 29
156
157# Included from sys/insrem.h
158def LIST_INIT(head): return \
159
160def LIST_INIT(head): return \
161
162def remque(a): return REMQUE(a)
163
164
165# Included from sys/socket.h
166
167# Included from sys/uio.h
168SHUT_RD = 0
169SHUT_WR = 1
170SHUT_RDWR = 2
171
172# Included from sys/netconfig.h
173
174# Included from sys/cdefs.h
175def __P(protos): return protos
176
177def __STRING(x): return #x
178
179def __P(protos): return ()
180
181def __STRING(x): return "x"
182
183NETCONFIG = "/etc/netconfig"
184NETPATH = "NETPATH"
185NC_TPI_CLTS = 1
186NC_TPI_COTS = 2
187NC_TPI_COTS_ORD = 3
188NC_TPI_RAW = 4
189NC_NOFLAG = 00
190NC_VISIBLE = 01
191NC_BROADCAST = 02
192NC_NOPROTOFMLY = "-"
193NC_LOOPBACK = "loopback"
194NC_INET = "inet"
195NC_INET6 = "inet6"
196NC_IMPLINK = "implink"
197NC_PUP = "pup"
198NC_CHAOS = "chaos"
199NC_NS = "ns"
200NC_NBS = "nbs"
201NC_ECMA = "ecma"
202NC_DATAKIT = "datakit"
203NC_CCITT = "ccitt"
204NC_SNA = "sna"
205NC_DECNET = "decnet"
206NC_DLI = "dli"
207NC_LAT = "lat"
208NC_HYLINK = "hylink"
209NC_APPLETALK = "appletalk"
210NC_NIT = "nit"
211NC_IEEE802 = "ieee802"
212NC_OSI = "osi"
213NC_X25 = "x25"
214NC_OSINET = "osinet"
215NC_GOSIP = "gosip"
216NC_NETWARE = "netware"
217NC_NOPROTO = "-"
218NC_TCP = "tcp"
219NC_UDP = "udp"
220NC_ICMP = "icmp"
221NC_IPX = "ipx"
222NC_SPX = "spx"
223NC_TPI_CLTS = 1
224NC_TPI_COTS = 2
225NC_TPI_COTS_ORD = 3
226NC_TPI_RAW = 4
227SOCK_STREAM = 2
228SOCK_DGRAM = 1
229SOCK_RAW = 4
230SOCK_RDM = 5
231SOCK_SEQPACKET = 6
232SO_DEBUG = 0x0001
233SO_ACCEPTCONN = 0x0002
234SO_REUSEADDR = 0x0004
235SO_KEEPALIVE = 0x0008
236SO_DONTROUTE = 0x0010
237SO_BROADCAST = 0x0020
238SO_USELOOPBACK = 0x0040
239SO_LINGER = 0x0080
240SO_OOBINLINE = 0x0100
241SO_ORDREL = 0x0200
242SO_IMASOCKET = 0x0400
243SO_MGMT = 0x0800
244SO_REUSEPORT = 0x1000
245SO_LISTENING = 0x2000
246SO_RDWR = 0x4000
247SO_SEMA = 0x8000
248SO_DONTLINGER = (~SO_LINGER)
249SO_SNDBUF = 0x1001
250SO_RCVBUF = 0x1002
251SO_SNDLOWAT = 0x1003
252SO_RCVLOWAT = 0x1004
253SO_SNDTIMEO = 0x1005
254SO_RCVTIMEO = 0x1006
255SO_ERROR = 0x1007
256SO_TYPE = 0x1008
257SO_PROTOTYPE = 0x1009
258SO_ALLRAW = 0x100a
259SOL_SOCKET = 0xffff
260AF_UNSPEC = 0
261AF_UNIX = 1
262AF_LOCAL = AF_UNIX
263AF_INET = 2
264AF_IMPLINK = 3
265AF_PUP = 4
266AF_CHAOS = 5
267AF_NS = 6
268AF_NBS = 7
269AF_ECMA = 8
270AF_DATAKIT = 9
271AF_CCITT = 10
272AF_SNA = 11
273AF_DECnet = 12
274AF_DLI = 13
275AF_LAT = 14
276AF_HYLINK = 15
277AF_APPLETALK = 16
278AF_NIT = 17
279AF_802 = 18
280AF_OSI = 19
281AF_ISO = AF_OSI
282AF_X25 = 20
283AF_OSINET = 21
284AF_GOSIP = 22
285AF_YNET = 23
286AF_ROUTE = 24
287AF_LINK = 25
288pseudo_AF_XTP = 26
289AF_INET6 = 27
290AF_MAX = 27
291AF_INET_BSWAP = 0x0200
292PF_UNSPEC = AF_UNSPEC
293PF_UNIX = AF_UNIX
294PF_LOCAL = AF_LOCAL
295PF_INET = AF_INET
296PF_IMPLINK = AF_IMPLINK
297PF_PUP = AF_PUP
298PF_CHAOS = AF_CHAOS
299PF_NS = AF_NS
300PF_NBS = AF_NBS
301PF_ECMA = AF_ECMA
302PF_DATAKIT = AF_DATAKIT
303PF_CCITT = AF_CCITT
304PF_SNA = AF_SNA
305PF_DECnet = AF_DECnet
306PF_DLI = AF_DLI
307PF_LAT = AF_LAT
308PF_HYLINK = AF_HYLINK
309PF_APPLETALK = AF_APPLETALK
310PF_NIT = AF_NIT
311PF_802 = AF_802
312PF_OSI = AF_OSI
313PF_ISO = PF_OSI
314PF_X25 = AF_X25
315PF_OSINET = AF_OSINET
316PF_GOSIP = AF_GOSIP
317PF_YNET = AF_YNET
318PF_ROUTE = AF_ROUTE
319PF_LINK = AF_LINK
320pseudo_PF_XTP = pseudo_AF_XTP
321PF_INET6 = AF_INET6
322PF_MAX = AF_MAX
323SOMAXCONN = 5
324SCM_RIGHTS = 1
325MSG_OOB = 0x1
326MSG_PEEK = 0x2
327MSG_DONTROUTE = 0x4
328MSG_CTRUNC = 0x8
329MSG_TRUNC = 0x10
330MSG_EOR = 0x30
331MSG_WAITALL = 0x20
332MSG_MAXIOVLEN = 16
333def OPTLEN(x): return ((((x) + sizeof(long) - 1) / sizeof(long)) * sizeof(long))
334
335GIARG = 0x1
336CONTI = 0x2
337GITAB = 0x4
338SOCKETSYS = 88
339SOCKETSYS = 83
340SO_ACCEPT = 1
341SO_BIND = 2
342SO_CONNECT = 3
343SO_GETPEERNAME = 4
344SO_GETSOCKNAME = 5
345SO_GETSOCKOPT = 6
346SO_LISTEN = 7
347SO_RECV = 8
348SO_RECVFROM = 9
349SO_SEND = 10
350SO_SENDTO = 11
351SO_SETSOCKOPT = 12
352SO_SHUTDOWN = 13
353SO_SOCKET = 14
354SO_SOCKPOLL = 15
355SO_GETIPDOMAIN = 16
356SO_SETIPDOMAIN = 17
357SO_ADJTIME = 18
358
359# Included from sys/stream.h
360
361# Included from sys/cred.h
362
363# Included from sys/ksynch.h
364
365# Included from sys/dl.h
366SIGNBIT = 0x80000000
367
368# Included from sys/ipl.h
369
370# Included from sys/disp_p.h
371
372# Included from sys/trap.h
373DIVERR = 0
374SGLSTP = 1
375NMIFLT = 2
376BPTFLT = 3
377INTOFLT = 4
378BOUNDFLT = 5
379INVOPFLT = 6
380NOEXTFLT = 7
381DBLFLT = 8
382EXTOVRFLT = 9
383INVTSSFLT = 10
384SEGNPFLT = 11
385STKFLT = 12
386GPFLT = 13
387PGFLT = 14
388EXTERRFLT = 16
389ALIGNFLT = 17
390MCEFLT = 18
391USERFLT = 0x100
392TRP_PREEMPT = 0x200
393TRP_UNUSED = 0x201
394PF_ERR_MASK = 0x01
395PF_ERR_PAGE = 0
396PF_ERR_PROT = 1
397PF_ERR_WRITE = 2
398PF_ERR_USER = 4
399EVT_STRSCHED = 0x04
400EVT_GLOBCALLOUT = 0x08
401EVT_LCLCALLOUT = 0x10
402EVT_SOFTINTMASK = (EVT_STRSCHED|EVT_GLOBCALLOUT|EVT_LCLCALLOUT)
403PL0 = 0
404PL1 = 1
405PL2 = 2
406PL3 = 3
407PL4 = 4
408PL5 = 5
409PL6 = 6
410PLHI = 8
411PL7 = PLHI
412PLBASE = PL0
413PLTIMEOUT = PL1
414PLDISK = PL5
415PLSTR = PL6
416PLTTY = PLSTR
417PLMIN = PL0
418PLMIN = PL1
419MAX_INTR_LEVELS = 10
420MAX_INTR_NESTING = 50
421STRSCHED = EVT_STRSCHED
422GLOBALSOFTINT = EVT_GLOBCALLOUT
423LOCALSOFTINT = EVT_LCLCALLOUT
424
425# Included from sys/ksynch_p.h
426def GET_TIME(timep): return \
427
428LK_THRESHOLD = 500000
429
430# Included from sys/list.h
431
432# Included from sys/listasm.h
433def remque_null(e): return \
434
435def LS_ISEMPTY(listp): return \
436
437LK_BASIC = 0x1
438LK_SLEEP = 0x2
439LK_NOSTATS = 0x4
440def CYCLES_SINCE(c): return CYCLES_BETWEEN((c), CYCLES())
441
442LSB_NLKDS = 92
443EVT_RUNRUN = 0x01
444EVT_KPRUNRUN = 0x02
445SP_UNLOCKED = 0
446SP_LOCKED = 1
447KS_LOCKTEST = 0x01
448KS_MPSTATS = 0x02
449KS_DEINITED = 0x04
450KS_NVLTTRACE = 0x08
451RWS_READ = (ord('r'))
452RWS_WRITE = (ord('w'))
453RWS_UNLOCKED = (ord('u'))
454RWS_BUSY = (ord('b'))
455def SLEEP_LOCKOWNED(lkp): return \
456
457def SLEEP_DISOWN(lkp): return \
458
459KS_NOPRMPT = 0x00000001
460__KS_LOCKTEST = KS_LOCKTEST
461__KS_LOCKTEST = 0
462__KS_MPSTATS = KS_MPSTATS
463__KS_MPSTATS = 0
464__KS_NVLTTRACE = KS_NVLTTRACE
465__KS_NVLTTRACE = 0
466KSFLAGS = (__KS_LOCKTEST|__KS_MPSTATS|__KS_NVLTTRACE)
467KSVUNIPROC = 1
468KSVMPDEBUG = 2
469KSVMPNODEBUG = 3
470KSVFLAG = KSVUNIPROC
471KSVFLAG = KSVMPDEBUG
472KSVFLAG = KSVMPNODEBUG
473
474# Included from sys/ksinline.h
475_A_SP_LOCKED = 1
476_A_SP_UNLOCKED = 0
477_A_INVPL = -1
478def _ATOMIC_INT_INCR(atomic_intp): return \
479
480def _ATOMIC_INT_DECR(atomic_intp): return \
481
482def ATOMIC_INT_READ(atomic_intp): return _ATOMIC_INT_READ(atomic_intp)
483
484def ATOMIC_INT_INCR(atomic_intp): return _ATOMIC_INT_INCR(atomic_intp)
485
486def ATOMIC_INT_DECR(atomic_intp): return _ATOMIC_INT_DECR(atomic_intp)
487
488def FSPIN_INIT(lp): return
489
490def FSPIN_LOCK(l): return DISABLE()
491
492def FSPIN_TRYLOCK(l): return (DISABLE(), B_TRUE)
493
494def FSPIN_UNLOCK(l): return ENABLE()
495
496def LOCK_DEINIT(lp): return
497
498def LOCK_DEALLOC(lp): return
499
500def LOCK_OWNED(lp): return (B_TRUE)
501
502def RW_DEINIT(lp): return
503
504def RW_DEALLOC(lp): return
505
506def RW_OWNED(lp): return (B_TRUE)
507
508def IS_LOCKED(lockp): return B_FALSE
509
510def LOCK_PLMIN(lockp): return \
511
512def TRYLOCK_PLMIN(lockp): return LOCK_PLMIN(lockp)
513
514def LOCK_SH_PLMIN(lockp): return LOCK_PLMIN(lockp)
515
516def RW_RDLOCK_PLMIN(lockp): return LOCK_PLMIN(lockp)
517
518def RW_WRLOCK_PLMIN(lockp): return LOCK_PLMIN(lockp)
519
520def LOCK_DEINIT(l): return
521
522def LOCK_PLMIN(lockp): return LOCK((lockp), PLMIN)
523
524def TRYLOCK_PLMIN(lockp): return TRYLOCK((lockp), PLMIN)
525
526def LOCK_SH_PLMIN(lockp): return LOCK_SH((lockp), PLMIN)
527
528def RW_RDLOCK_PLMIN(lockp): return RW_RDLOCK((lockp), PLMIN)
529
530def RW_WRLOCK_PLMIN(lockp): return RW_WRLOCK((lockp), PLMIN)
531
532def FSPIN_IS_LOCKED(fsp): return B_FALSE
533
534def SPIN_IS_LOCKED(lockp): return B_FALSE
535
536def FSPIN_OWNED(l): return (B_TRUE)
537
538CR_MLDREAL = 0x00000001
539CR_RDUMP = 0x00000002
540def crhold(credp): return crholdn((credp), 1)
541
542def crfree(credp): return crfreen((credp), 1)
543
544
545# Included from sys/strmdep.h
546def str_aligned(X): return (((uint)(X) & (sizeof(int) - 1)) == 0)
547
548
549# Included from sys/engine.h
550
551# Included from sys/clock.h
552
553# Included from sys/time.h
554DST_NONE = 0
555DST_USA = 1
556DST_AUST = 2
557DST_WET = 3
558DST_MET = 4
559DST_EET = 5
560DST_CAN = 6
561DST_GB = 7
562DST_RUM = 8
563DST_TUR = 9
564DST_AUSTALT = 10
565ITIMER_REAL = 0
566ITIMER_VIRTUAL = 1
567ITIMER_PROF = 2
568FD_SETSIZE = 4096
569FD_NBBY = 8
570
571# Included from time.h
572NULL = 0
573CLOCKS_PER_SEC = 1000000
574
575# Included from sys/clock_p.h
576CGBITS = 4
577IDBITS = 28
578def toid_unpackcg(idval): return (((idval) >> IDBITS) & 0xf)
579
580def toid_unpackid(idval): return ((idval) & 0xfffffff)
581
582def toid_unpackcg(idval): return 0
583
584def toid_unpackid(idval): return (idval)
585
586NCALLOUT_HASH = 1024
587CALLOUT_MAXVAL = 0x7fffffff
588TO_PERIODIC = 0x80000000
589TO_IMMEDIATE = 0x80000000
590SEC = 1
591MILLISEC = 1000
592MICROSEC = 1000000
593NANOSEC = 1000000000
594SECHR = (60*60)
595SECDAY = (24*SECHR)
596SECYR = (365*SECDAY)
597def TIME_OWNED_R(cgnum): return (B_TRUE)
598
599LOOPSECONDS = 1800
600LOOPMICROSECONDS = (LOOPSECONDS * MICROSEC)
601def TICKS_SINCE(t): return TICKS_BETWEEN(t, TICKS())
602
603MAXRQS = 2
604E_OFFLINE = 0x01
605E_BAD = 0x02
606E_SHUTDOWN = 0x04
607E_DRIVER = 0x08
608E_DEFAULTKEEP = 0x100
609E_DRIVERBOUND = 0x200
610E_EXCLUSIVE = 0x400
611E_CGLEADER = 0x800
612E_NOWAY = (E_OFFLINE|E_BAD|E_SHUTDOWN)
613E_BOUND = 0x01
614E_GLOBAL = 0x00
615E_UNAVAIL = -1
616ENGINE_ONLINE = 1
617def PROCESSOR_UNMAP(e): return ((e) - engine)
618
619BOOTENG = 0
620QMOVED = 0x0001
621QWANTR = 0x0002
622QWANTW = 0x0004
623QFULL = 0x0008
624QREADR = 0x0010
625QUSE = 0x0020
626QNOENB = 0x0040
627QUP = 0x0080
628QBACK = 0x0100
629QINTER = 0x0200
630QPROCSON = 0x0400
631QTOENAB = 0x0800
632QFREEZE = 0x1000
633QBOUND = 0x2000
634QDEFCNT = 0x4000
635QENAB = 0x0001
636QSVCBUSY = 0x0002
637STRM_PUTCNT_TABLES = 31
638def STRM_MYENG_PUTCNT(sdp): return STRM_PUTCNT(l.eng_num, sdp)
639
640QB_FULL = 0x01
641QB_WANTW = 0x02
642QB_BACK = 0x04
643NBAND = 256
644DB_WASDUPED = 0x1
645DB_2PIECE = 0x2
646STRLEAKHASHSZ = 1021
647MSGMARK = 0x01
648MSGNOLOOP = 0x02
649MSGDELIM = 0x04
650MSGNOGET = 0x08
651MSGLOG = 0x10
652M_DATA = 0x00
653M_PROTO = 0x01
654M_BREAK = 0x08
655M_PASSFP = 0x09
656M_SIG = 0x0b
657M_DELAY = 0x0c
658M_CTL = 0x0d
659M_IOCTL = 0x0e
660M_SETOPTS = 0x10
661M_RSE = 0x11
662M_TRAIL = 0x12
663M_IOCACK = 0x81
664M_IOCNAK = 0x82
665M_PCPROTO = 0x83
666M_PCSIG = 0x84
667M_READ = 0x85
668M_FLUSH = 0x86
669M_STOP = 0x87
670M_START = 0x88
671M_HANGUP = 0x89
672M_ERROR = 0x8a
673M_COPYIN = 0x8b
674M_COPYOUT = 0x8c
675M_IOCDATA = 0x8d
676M_PCRSE = 0x8e
677M_STOPI = 0x8f
678M_STARTI = 0x90
679M_PCCTL = 0x91
680M_PCSETOPTS = 0x92
681QNORM = 0x00
682QPCTL = 0x80
683STRCANON = 0x01
684RECOPY = 0x02
685SO_ALL = 0x003f
686SO_READOPT = 0x0001
687SO_WROFF = 0x0002
688SO_MINPSZ = 0x0004
689SO_MAXPSZ = 0x0008
690SO_HIWAT = 0x0010
691SO_LOWAT = 0x0020
692SO_MREADON = 0x0040
693SO_MREADOFF = 0x0080
694SO_NDELON = 0x0100
695SO_NDELOFF = 0x0200
696SO_ISTTY = 0x0400
697SO_ISNTTY = 0x0800
698SO_TOSTOP = 0x1000
699SO_TONSTOP = 0x2000
700SO_BAND = 0x4000
701SO_DELIM = 0x8000
702SO_NODELIM = 0x010000
703SO_STRHOLD = 0x020000
704SO_LOOP = 0x040000
705DRVOPEN = 0x0
706MODOPEN = 0x1
707CLONEOPEN = 0x2
708OPENFAIL = -1
709BPRI_LO = 1
710BPRI_MED = 2
711BPRI_HI = 3
712INFPSZ = -1
713FLUSHALL = 1
714FLUSHDATA = 0
715STRHIGH = 5120
716STRLOW = 1024
717MAXIOCBSZ = 1024
718def straln(a): return (caddr_t)((long)(a) & ~(sizeof(int)-1))
719
720IPM_ID = 200
721ICMPM_ID = 201
722TCPM_ID = 202
723UDPM_ID = 203
724ARPM_ID = 204
725APPM_ID = 205
726RIPM_ID = 206
727PPPM_ID = 207
728AHDLCM_ID = 208
729MHDLCRIPM_ID = 209
730HDLCM_ID = 210
731PPCID_ID = 211
732IGMPM_ID = 212
733IPIPM_ID = 213
734IPPROTO_IP = 0
735IPPROTO_HOPOPTS = 0
736IPPROTO_ICMP = 1
737IPPROTO_IGMP = 2
738IPPROTO_GGP = 3
739IPPROTO_IPIP = 4
740IPPROTO_TCP = 6
741IPPROTO_EGP = 8
742IPPROTO_PUP = 12
743IPPROTO_UDP = 17
744IPPROTO_IDP = 22
745IPPROTO_TP = 29
746IPPROTO_IPV6 = 41
747IPPROTO_ROUTING = 43
748IPPROTO_FRAGMENT = 44
749IPPROTO_ESP = 50
750IPPROTO_AH = 51
751IPPROTO_ICMPV6 = 58
752IPPROTO_NONE = 59
753IPPROTO_DSTOPTS = 60
754IPPROTO_HELLO = 63
755IPPROTO_ND = 77
756IPPROTO_EON = 80
757IPPROTO_RAW = 255
758IPPROTO_MAX = 256
759IPPORT_ECHO = 7
760IPPORT_DISCARD = 9
761IPPORT_SYSTAT = 11
762IPPORT_DAYTIME = 13
763IPPORT_NETSTAT = 15
764IPPORT_FTP = 21
765IPPORT_TELNET = 23
766IPPORT_SMTP = 25
767IPPORT_TIMESERVER = 37
768IPPORT_NAMESERVER = 42
769IPPORT_WHOIS = 43
770IPPORT_MTP = 57
771IPPORT_TFTP = 69
772IPPORT_RJE = 77
773IPPORT_FINGER = 79
774IPPORT_TTYLINK = 87
775IPPORT_SUPDUP = 95
776IPPORT_EXECSERVER = 512
777IPPORT_LOGINSERVER = 513
778IPPORT_CMDSERVER = 514
779IPPORT_EFSSERVER = 520
780IPPORT_BIFFUDP = 512
781IPPORT_WHOSERVER = 513
782IPPORT_ROUTESERVER = 520
783IPPORT_RESERVED = 1024
784IPPORT_USERRESERVED = 65535
785IPPORT_RESERVED_LOW = 512
786IPPORT_RESERVED_HIGH = 1023
787IPPORT_USERRESERVED_LOW = 32768
788IPPORT_USERRESERVED_HIGH = 65535
789INET_ADDRSTRLEN = 16
790IP_OPTIONS = 1
791IP_TOS = 2
792IP_TTL = 3
793IP_HDRINCL = 4
794IP_RECVOPTS = 5
795IP_RECVRETOPTS = 6
796IP_RECVDSTADDR = 7
797IP_RETOPTS = 8
798IP_MULTICAST_IF = 9
799IP_MULTICAST_LOOP = 10
800IP_ADD_MEMBERSHIP = 11
801IP_DROP_MEMBERSHIP = 12
802IP_BROADCAST_IF = 14
803IP_RECVIFINDEX = 15
804IP_MULTICAST_TTL = 16
805MRT_INIT = 17
806MRT_DONE = 18
807MRT_ADD_VIF = 19
808MRT_DEL_VIF = 20
809MRT_ADD_MFC = 21
810MRT_DEL_MFC = 22
811MRT_VERSION = 23
812IP_DEFAULT_MULTICAST_TTL = 1
813IP_DEFAULT_MULTICAST_LOOP = 1
814IP_MAX_MEMBERSHIPS = 20
815INADDR_UNSPEC_GROUP = 0xe0000000
816INADDR_ALLHOSTS_GROUP = 0xe0000001
817INADDR_ALLRTRS_GROUP = 0xe0000002
818INADDR_MAX_LOCAL_GROUP = 0xe00000ff
819
820# Included from netinet/in_mp.h
821
822# Included from netinet/in_mp_ddi.h
823
824# Included from sys/inline.h
825IP_HIER_BASE = (20)
826def ASSERT_LOCK(x): return
827
828def ASSERT_WRLOCK(x): return
829
830def ASSERT_UNLOCK(x): return
831
832def CANPUT(q): return canput((q))
833
834def CANPUTNEXT(q): return canputnext((q))
835
836INET_DEBUG = 1