8322 nl: misleading-indentation
[unleashed/tickless.git] / usr / src / uts / common / netinet / in_pcb.h
blob0814efc5b3b2b5d0dc2124b0a46bcd40f94db535
1 /*
2 * Copyright (c) 1997-1998 by Sun Microsystems, Inc.
3 * All rights reserved.
4 */
6 /*
7 * Copyright (c) 1982, 1986 Regents of the University of California.
8 * All rights reserved. The Berkeley software License Agreement
9 * specifies the terms and conditions for redistribution.
13 * Common structure pcb for internet protocol implementation.
14 * Here are stored pointers to local and foreign host table
15 * entries, local and foreign socket numbers, and pointers
16 * up (to a socket structure) and down (to a protocol-specific)
17 * control block.
20 #ifndef _NETINET_IN_PCB_H
21 #define _NETINET_IN_PCB_H
23 #pragma ident "%Z%%M% %I% %E% SMI"
24 /* in_pcb.h 1.7 88/08/19 SMI; from UCB 7.1 6/5/86 */
26 #ifdef __cplusplus
27 extern "C" {
28 #endif
30 struct inpcb {
31 struct inpcb *inp_next, *inp_prev; /* pointers to other pcb's */
32 struct inpcb *inp_head; /* pointer back to chain of inpcb's */
33 /* for this protocol */
34 struct in_addr inp_faddr; /* foreign host table entry */
35 ushort_t inp_fport; /* foreign port */
36 struct in_addr inp_laddr; /* local host table entry */
37 ushort_t inp_lport; /* local port */
38 struct socket *inp_socket; /* back pointer to socket */
39 caddr_t inp_ppcb; /* pointer to per-protocol pcb */
40 struct route inp_route; /* placeholder for routing entry */
41 struct mbuf *inp_options; /* IP options */
44 #define INPLOOKUP_WILDCARD 1
45 #define INPLOOKUP_SETLOCAL 2
47 #define sotoinpcb(so) ((struct inpcb *)(so)->so_pcb)
49 #ifdef __cplusplus
51 #endif
53 #endif /* _NETINET_IN_PCB_H */