Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F111868198
D29483.id86491.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
961 B
Referenced Files
None
Subscribers
None
D29483.id86491.diff
View Options
Index: sys/netinet/tcp_hostcache.c
===================================================================
--- sys/netinet/tcp_hostcache.c
+++ sys/netinet/tcp_hostcache.c
@@ -650,14 +650,18 @@
}
/* Use a buffer for 16 lines */
- sbuf_new_for_sysctl(&sb, NULL, 16 * linesize, req);
+ sbuf_new_for_sysctl(&sb, NULL, TCP_HOSTCACHE_BUCKETLIMIT * linesize, req);
sbuf_printf(&sb,
"\nIP address MTU SSTRESH RTT RTTVAR "
" CWND SENDPIPE RECVPIPE HITS UPD EXP\n");
+ len = 1;
#define msec(u) (((u) + 500) / 1000)
for (i = 0; i < V_tcp_hostcache.hashsize; i++) {
+ if (len > 0)
+ sbuf_drain(&sb);
+ len = 0;
THC_LOCK(&V_tcp_hostcache.hashbase[i].hch_mtx);
TAILQ_FOREACH(hc_entry, &V_tcp_hostcache.hashbase[i].hch_bucket,
rmx_q) {
@@ -683,6 +687,7 @@
hc_entry->rmx_hits,
hc_entry->rmx_updates,
hc_entry->rmx_expire);
+ len++;
}
THC_UNLOCK(&V_tcp_hostcache.hashbase[i].hch_mtx);
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Mar 10, 1:49 PM (7 h, 41 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
17084972
Default Alt Text
D29483.id86491.diff (961 B)
Attached To
Mode
D29483: tcp: drain tcp_hostcache_list in between per-bucket locks
Attached
Detach File
Event Timeline
Log In to Comment