/*
* offset: 0x6c
*/
uint32_t tcpb_rnxt; /* Seq we expect to recv next */
uint32_t tcpb_rwnd; /* Current receive window */
/*
* /usr/include/sys/mutex.h
* 无论64-bit还是32-bit kernel mode,kmutex_t都占8字节空间,这里需要对
* 齐在数据类型自然连界上,0x6c8 -> 0x74不在kmutex_t自然边界上,继
* 续后移4个字节
*
* offset: 0x78
*/
kmutex_t tcpb_reflock; /* Protects tcp_refcnt */
/*
* offset: 0x80
*/
ushort_t tcpb_refcnt; /* Number of pending upstream msg */
union
{
struct
{
uchar_t v4_ttl; /* Dup of tcp_ipha.iph_type_of_service */
uchar_t v4_tos; /* Dup of tcp_ipha.iph_ttl */
} v4_hdr_info;
struct
{
/*
* 对齐在uint_t的自然边界上
* offset: 0x84
*/
uint_t v6_vcf; /* Dup of tcp_ip6h.ip6h_vcf */
/*
* offset: 0x88
*/
uchar_t v6_hops; /* Dup of tcp_ip6h.ip6h_hops */
} v6_hdr_info;
} tcpb_hdr_info;
#define tcpb_ttl tcpb_hdr_info.v4_hdr_info.v4_ttl
#define tcpb_tos tcpb_hdr_info.v4_hdr_info.v4_tos
#define tcpb_ip6_vcf tcpb_hdr_info.v6_hdr_info.v6_vcf
#define tcpb_ip6_hops tcpb_hdr_info.v6_hdr_info.v6_hops
/*
* offset: 0x8c,先是远端地址,后是本地地址
* /usr/include/netinet/in.h
* in6_addr_t长16字节,在内核空间里这个结构对齐在uint32_t的自然边界上
*/
in6_addr_t tcpb_remote_v6; /* true remote address - needed for */
/* source routing. */
in6_addr_t tcpb_bound_source_v6; /* IP address in bind_req */
/*
* offset: 0xac
*/
in6_addr_t tcpb_ip_src_v6; /* same as tcp_iph.iph_src. */
#ifdef _KERNEL
/*
* Note: V4_PART_OF_V6 is meant to be used only for _KERNEL defined stuff
*/
#define tcpb_remote V4_PART_OF_V6(tcpb_remote_v6)
#define tcpb_bound_source V4_PART_OF_V6(tcpb_bound_source_v6)
#define tcpb_ip_src V4_PART_OF_V6(tcpb_ip_src_v6)
#endif /* _KERNEL */
/*
* These fields contain the same information as tcp_tcph->th_*port.
* However, the lookup functions can not use the header fields
* since during IP option manipulation the tcp_tcph pointer
* changes.
*/
/*
* offset: 0xbc,先是远端端口,后是本地端口
*/
union
{
struct
{
in_port_t tCPU_fport; /* Remote port */
in_port_t tcpu_lport; /* Local port */
} tcpu_ports1;
uint32_t tcpu_ports2; /* Rem port, local port */
/*
* Used for TCP_MATCH performance
*/
} tcpb_tcpu;
#define tcpb_fport tcpb_tcpu.tcpu_ports1.tcpu_fport
#define tcpb_lport tcpb_tcpu.tcpu_ports1.tcpu_lport
#define tcpb_ports tcpb_tcpu.tcpu_ports2
/*
* IP sends back 2 mblks with the unbind ACK for handling
* IPSEC policy for detached connections. Following two fields
* are initialized then.
*/
mblk_t *tcpb_ipsec_out;
mblk_t *tcpb_ipsec_req_in;
/*
* offset: 0xd0
*/
tcp_t *tcpb_tcp;
/*
* offset: 0xd8
*/
/*
* IP format that packets transmitted from this struct should use.
* Value can be IPV4_VERSION or IPV6_VERSION. Determines whether
* IP TCP header template above stores an IPv4 or IPv6 header.
*/
ushort_t tcpb_ipversion;
uint_t tcpb_bound_if; /* IPV6_BOUND_IF */
uid_t tcpb_ownerid; /* uid of process that did open */
#define tcp_bind_hash tcp_base->tcpb_bind_hash
#define tcp_ptpbhn tcp_base->tcpb_ptpbhn
#define tcp_conn_hash tcp_base->tcpb_conn_hash
#define tcp_ptpchn tcp_base->tcpb_ptpchn
#define tcp_time_wait_next tcp_base->tcpb_time_wait_next
#define tcp_time_wait_prev tcp_base->tcpb_time_wait_prev
#define tcp_time_wait_expire tcp_base->tcpb_time_wait_expire
#define tcp_last_rcv_lbolt tcp_base->tcpb_last_rcv_lbolt
#define tcp_state tcp_base->tcpb_state
#define tcp_rcv_ws tcp_base->tcpb_rcv_ws
#define tcp_snd_ws tcp_base->tcpb_snd_ws
#define tcp_ts_recent tcp_base->tcpb_ts_recent
#define tcp_rto tcp_base->tcpb_rto
#define tcp_snd_ts_ok tcp_base->tcpb_snd_ts_ok
推荐阅读
- Solaris上的域名系统配置
- SUN Solaris 7重新安装手记
- SOLARIS+QMAIL+VPOPMAIL+IGENUS+QMAILAMDIN
- Solaris中的磁盘设备
- Solaris 的引导与初始化
- Solaris8 公用桌面环境管理--配置会话管理器
- 安装 Solaris 8 之后的几个常用步骤
- Sun Solaris 用户手册 -- 四.Unix 命令
- Solaris常见问题解答
- SUN SOLARIS 2.6 系统常用管理命令
