tcp_syncache.c (9c79794016d679440487dea61b3b986397c9ecbb) | tcp_syncache.c (f6dfe47a145263dc5eb67fa4789925ab708709bc) |
---|---|
1/*- 2 * Copyright (c) 2001 McAfee, Inc. 3 * Copyright (c) 2006 Andre Oppermann, Internet Business Solutions AG 4 * All rights reserved. 5 * 6 * This software was developed for the FreeBSD Project by Jonathan Lemon 7 * and McAfee Research, the Security Research Division of McAfee, Inc. under 8 * DARPA/SPAWAR contract N66001-01-C-8035 ("CBOSS"), as part of the --- 245 unchanged lines hidden (view full) --- 254 &V_tcp_syncache.cache_limit); 255 256 /* Allocate the hash table. */ 257 V_tcp_syncache.hashbase = malloc(V_tcp_syncache.hashsize * 258 sizeof(struct syncache_head), M_SYNCACHE, M_WAITOK | M_ZERO); 259 260 /* Initialize the hash buckets. */ 261 for (i = 0; i < V_tcp_syncache.hashsize; i++) { | 1/*- 2 * Copyright (c) 2001 McAfee, Inc. 3 * Copyright (c) 2006 Andre Oppermann, Internet Business Solutions AG 4 * All rights reserved. 5 * 6 * This software was developed for the FreeBSD Project by Jonathan Lemon 7 * and McAfee Research, the Security Research Division of McAfee, Inc. under 8 * DARPA/SPAWAR contract N66001-01-C-8035 ("CBOSS"), as part of the --- 245 unchanged lines hidden (view full) --- 254 &V_tcp_syncache.cache_limit); 255 256 /* Allocate the hash table. */ 257 V_tcp_syncache.hashbase = malloc(V_tcp_syncache.hashsize * 258 sizeof(struct syncache_head), M_SYNCACHE, M_WAITOK | M_ZERO); 259 260 /* Initialize the hash buckets. */ 261 for (i = 0; i < V_tcp_syncache.hashsize; i++) { |
262#ifdef VIMAGE 263 V_tcp_syncache.hashbase[i].sch_vnet = curvnet; 264#endif |
|
262 TAILQ_INIT(&V_tcp_syncache.hashbase[i].sch_bucket); 263 mtx_init(&V_tcp_syncache.hashbase[i].sch_mtx, "tcp_sc_head", 264 NULL, MTX_DEF); 265 callout_init_mtx(&V_tcp_syncache.hashbase[i].sch_timer, 266 &V_tcp_syncache.hashbase[i].sch_mtx, 0); 267 V_tcp_syncache.hashbase[i].sch_length = 0; 268 } 269 --- 1499 unchanged lines hidden --- | 265 TAILQ_INIT(&V_tcp_syncache.hashbase[i].sch_bucket); 266 mtx_init(&V_tcp_syncache.hashbase[i].sch_mtx, "tcp_sc_head", 267 NULL, MTX_DEF); 268 callout_init_mtx(&V_tcp_syncache.hashbase[i].sch_timer, 269 &V_tcp_syncache.hashbase[i].sch_mtx, 0); 270 V_tcp_syncache.hashbase[i].sch_length = 0; 271 } 272 --- 1499 unchanged lines hidden --- |