svn commit: r194303 - head/sys/netinet
John Baldwin
jhb at FreeBSD.org
Tue Jun 16 18:58:51 UTC 2009
Author: jhb
Date: Tue Jun 16 18:58:50 2009
New Revision: 194303
URL: http://svn.freebsd.org/changeset/base/194303
Log:
- Change members of tcpcb that cache values of ticks from int to u_int:
t_rcvtime, t_starttime, t_rtttime, t_bw_rtttime, ts_recent_age,
t_badrxtwin.
- Change t_recent in struct timewait from u_long to u_int32_t to match
the type of the field it shadows from tcpcb: ts_recent.
- Change t_starttime in struct timewait from u_long to u_int to match
the t_starttime field in tcpcb.
Requested by: bde (1, 3)
Modified:
head/sys/netinet/tcp_usrreq.c
head/sys/netinet/tcp_var.h
Modified: head/sys/netinet/tcp_usrreq.c
==============================================================================
--- head/sys/netinet/tcp_usrreq.c Tue Jun 16 18:22:34 2009 (r194302)
+++ head/sys/netinet/tcp_usrreq.c Tue Jun 16 18:58:50 2009 (r194303)
@@ -1823,11 +1823,11 @@ db_print_tcpcb(struct tcpcb *tp, const c
tp->snd_recover);
db_print_indent(indent);
- db_printf("t_maxopd: %u t_rcvtime: %d t_startime: %d\n",
+ db_printf("t_maxopd: %u t_rcvtime: %u t_startime: %u\n",
tp->t_maxopd, tp->t_rcvtime, tp->t_starttime);
db_print_indent(indent);
- db_printf("t_rttime: %d t_rtsq: 0x%08x t_bw_rtttime: %d\n",
+ db_printf("t_rttime: %u t_rtsq: 0x%08x t_bw_rtttime: %u\n",
tp->t_rtttime, tp->t_rtseq, tp->t_bw_rtttime);
db_print_indent(indent);
@@ -1854,7 +1854,7 @@ db_print_tcpcb(struct tcpcb *tp, const c
tp->snd_scale, tp->rcv_scale, tp->request_r_scale);
db_print_indent(indent);
- db_printf("ts_recent: %u ts_recent_age: %d\n",
+ db_printf("ts_recent: %u ts_recent_age: %u\n",
tp->ts_recent, tp->ts_recent_age);
db_print_indent(indent);
@@ -1863,7 +1863,7 @@ db_print_tcpcb(struct tcpcb *tp, const c
db_print_indent(indent);
db_printf("snd_ssthresh_prev: %lu snd_recover_prev: 0x%08x "
- "t_badrxtwin: %d\n", tp->snd_ssthresh_prev,
+ "t_badrxtwin: %u\n", tp->snd_ssthresh_prev,
tp->snd_recover_prev, tp->t_badrxtwin);
db_print_indent(indent);
Modified: head/sys/netinet/tcp_var.h
==============================================================================
--- head/sys/netinet/tcp_var.h Tue Jun 16 18:22:34 2009 (r194302)
+++ head/sys/netinet/tcp_var.h Tue Jun 16 18:58:50 2009 (r194303)
@@ -139,12 +139,12 @@ struct tcpcb {
u_int t_maxopd; /* mss plus options */
- int t_rcvtime; /* inactivity time */
- int t_starttime; /* time connection was established */
- int t_rtttime; /* round trip time */
+ u_int t_rcvtime; /* inactivity time */
+ u_int t_starttime; /* time connection was established */
+ u_int t_rtttime; /* RTT measurement start time */
tcp_seq t_rtseq; /* sequence number being timed */
- int t_bw_rtttime; /* used for bandwidth calculation */
+ u_int t_bw_rtttime; /* used for bandwidth calculation */
tcp_seq t_bw_rtseq; /* used for bandwidth calculation */
int t_rxtcur; /* current retransmit value (ticks) */
@@ -167,7 +167,7 @@ struct tcpcb {
u_char rcv_scale; /* window scaling for recv window */
u_char request_r_scale; /* pending window scaling */
u_int32_t ts_recent; /* timestamp echo data */
- int ts_recent_age; /* when last updated */
+ u_int ts_recent_age; /* when last updated */
u_int32_t ts_offset; /* our timestamp offset */
tcp_seq last_ack_sent;
@@ -175,7 +175,7 @@ struct tcpcb {
u_long snd_cwnd_prev; /* cwnd prior to retransmit */
u_long snd_ssthresh_prev; /* ssthresh prior to retransmit */
tcp_seq snd_recover_prev; /* snd_recover prior to retransmit */
- int t_badrxtwin; /* window for retransmit recovery */
+ u_int t_badrxtwin; /* window for retransmit recovery */
u_char snd_limited; /* segments limited transmitted */
/* SACK related state */
int snd_numholes; /* number of holes seen by sender */
@@ -306,9 +306,9 @@ struct tcptw {
u_short last_win; /* cached window value */
u_short tw_so_options; /* copy of so_options */
struct ucred *tw_cred; /* user credentials */
- u_long t_recent;
+ u_int32_t t_recent;
u_int32_t ts_offset; /* our timestamp offset */
- u_long t_starttime;
+ u_int t_starttime;
int tw_time;
TAILQ_ENTRY(tcptw) tw_2msl;
};
More information about the svn-src-head
mailing list