1*433d6423SLionel Sambuc /* 2*433d6423SLionel Sambuc server/ip/gen/tcp_io.h 3*433d6423SLionel Sambuc */ 4*433d6423SLionel Sambuc 5*433d6423SLionel Sambuc #ifndef __SERVER__IP__GEN__TCP_IO_H__ 6*433d6423SLionel Sambuc #define __SERVER__IP__GEN__TCP_IO_H__ 7*433d6423SLionel Sambuc 8*433d6423SLionel Sambuc typedef struct nwio_tcpconf 9*433d6423SLionel Sambuc { 10*433d6423SLionel Sambuc u32_t nwtc_flags; 11*433d6423SLionel Sambuc ipaddr_t nwtc_locaddr; 12*433d6423SLionel Sambuc ipaddr_t nwtc_remaddr; 13*433d6423SLionel Sambuc tcpport_t nwtc_locport; 14*433d6423SLionel Sambuc tcpport_t nwtc_remport; 15*433d6423SLionel Sambuc } nwio_tcpconf_t; 16*433d6423SLionel Sambuc 17*433d6423SLionel Sambuc #define NWTC_NOFLAGS 0x0000L 18*433d6423SLionel Sambuc #define NWTC_ACC_MASK 0x0003L 19*433d6423SLionel Sambuc # define NWTC_EXCL 0x00000001L 20*433d6423SLionel Sambuc # define NWTC_SHARED 0x00000002L 21*433d6423SLionel Sambuc # define NWTC_COPY 0x00000003L 22*433d6423SLionel Sambuc #define NWTC_LOCPORT_MASK 0x0030L 23*433d6423SLionel Sambuc # define NWTC_LP_UNSET 0x00000010L 24*433d6423SLionel Sambuc # define NWTC_LP_SET 0x00000020L 25*433d6423SLionel Sambuc # define NWTC_LP_SEL 0x00000030L 26*433d6423SLionel Sambuc #define NWTC_REMADDR_MASK 0x0100L 27*433d6423SLionel Sambuc # define NWTC_SET_RA 0x00000100L 28*433d6423SLionel Sambuc # define NWTC_UNSET_RA 0x01000000L 29*433d6423SLionel Sambuc #define NWTC_REMPORT_MASK 0x0200L 30*433d6423SLionel Sambuc # define NWTC_SET_RP 0x00000200L 31*433d6423SLionel Sambuc # define NWTC_UNSET_RP 0x02000000L 32*433d6423SLionel Sambuc 33*433d6423SLionel Sambuc typedef struct nwio_tcpcl 34*433d6423SLionel Sambuc { 35*433d6423SLionel Sambuc long nwtcl_flags; 36*433d6423SLionel Sambuc long nwtcl_ttl; 37*433d6423SLionel Sambuc } nwio_tcpcl_t; 38*433d6423SLionel Sambuc 39*433d6423SLionel Sambuc #define TCF_DEFAULT 0 /* Default parameters */ 40*433d6423SLionel Sambuc #define TCF_ASYNCH 1 /* Asynchronous connect for non-blocking 41*433d6423SLionel Sambuc * socket emulation. 42*433d6423SLionel Sambuc */ 43*433d6423SLionel Sambuc 44*433d6423SLionel Sambuc typedef struct nwio_tcpatt 45*433d6423SLionel Sambuc { 46*433d6423SLionel Sambuc long nwta_flags; 47*433d6423SLionel Sambuc } nwio_tcpatt_t; 48*433d6423SLionel Sambuc 49*433d6423SLionel Sambuc typedef struct nwio_tcpopt 50*433d6423SLionel Sambuc { 51*433d6423SLionel Sambuc u32_t nwto_flags; 52*433d6423SLionel Sambuc } nwio_tcpopt_t; 53*433d6423SLionel Sambuc 54*433d6423SLionel Sambuc #define NWTO_NOFLAG 0x0000L 55*433d6423SLionel Sambuc #define NWTO_SND_URG_MASK 0x0001L 56*433d6423SLionel Sambuc # define NWTO_SND_URG 0x00000001L 57*433d6423SLionel Sambuc # define NWTO_SND_NOTURG 0x00010000L 58*433d6423SLionel Sambuc #define NWTO_RCV_URG_MASK 0x0002L 59*433d6423SLionel Sambuc # define NWTO_RCV_URG 0x00000002L 60*433d6423SLionel Sambuc # define NWTO_RCV_NOTURG 0x00020000L 61*433d6423SLionel Sambuc #define NWTO_BSD_URG_MASK 0x0004L 62*433d6423SLionel Sambuc # define NWTO_BSD_URG 0x00000004L 63*433d6423SLionel Sambuc # define NWTO_NOTBSD_URG 0x00040000L 64*433d6423SLionel Sambuc #define NWTO_DEL_RST_MASK 0x0008L 65*433d6423SLionel Sambuc # define NWTO_DEL_RST 0x00000008L 66*433d6423SLionel Sambuc #define NWTO_BULK_MASK 0x0010L 67*433d6423SLionel Sambuc # define NWTO_BULK 0x00000010L 68*433d6423SLionel Sambuc # define NWTO_NOBULK 0x00100000L 69*433d6423SLionel Sambuc 70*433d6423SLionel Sambuc #define TC_SECRET_SIZE 12 71*433d6423SLionel Sambuc 72*433d6423SLionel Sambuc typedef struct tcp_cookie 73*433d6423SLionel Sambuc { 74*433d6423SLionel Sambuc u32_t tc_ref; 75*433d6423SLionel Sambuc u8_t tc_secret[TC_SECRET_SIZE]; 76*433d6423SLionel Sambuc } tcp_cookie_t; 77*433d6423SLionel Sambuc 78*433d6423SLionel Sambuc #endif /* __SERVER__IP__GEN__TCP_IO_H__ */ 79*433d6423SLionel Sambuc 80*433d6423SLionel Sambuc /* 81*433d6423SLionel Sambuc * $PchId: tcp_io.h,v 1.5 2001/02/19 07:36:55 philip Exp $ 82*433d6423SLionel Sambuc */ 83