From: Victor Julien Date: Wed, 27 Apr 2016 19:37:28 +0000 (+0200) Subject: stream: remove unused zero copy setting X-Git-Tag: suricata-4.0.0-beta1~186 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b3e9d397719a972d16b4a4eb2c6fa4a456a4d281;p=thirdparty%2Fsuricata.git stream: remove unused zero copy setting --- diff --git a/src/stream-tcp-reassemble.c b/src/stream-tcp-reassemble.c index c613d8ea51..bd1dfab391 100644 --- a/src/stream-tcp-reassemble.c +++ b/src/stream-tcp-reassemble.c @@ -503,18 +503,6 @@ int StreamTcpReassemblyConfig(char quiet) SCLogConfig("stream.reassembly \"chunk-prealloc\": %u", stream_chunk_prealloc); StreamMsgQueuesInit(stream_chunk_prealloc); - intmax_t zero_copy_size = 128; - if (ConfGetInt("stream.reassembly.zero-copy-size", &zero_copy_size) == 1) { - if (zero_copy_size < 0 || zero_copy_size > 0xffff) { - SCLogError(SC_ERR_INVALID_ARGUMENT, "stream.reassembly.zero-copy-size of " - "%"PRIiMAX" is invalid: valid values are 0 to 65535", zero_copy_size); - return -1; - } - } - stream_config.zero_copy_size = (uint16_t)zero_copy_size; - if (!quiet) - SCLogConfig("stream.reassembly \"zero-copy-size\": %u", stream_config.zero_copy_size); - stream_config.sbcnf.flags = STREAMING_BUFFER_NOFLAGS; stream_config.sbcnf.buf_size = 2048; @@ -599,10 +587,6 @@ void StreamTcpReassembleFreeThreadCtx(TcpReassemblyThreadCtx *ra_ctx) { SCEnter(); AppLayerDestroyCtxThread(ra_ctx->app_tctx); -#ifdef DEBUG - SCLogDebug("reassembly fast path stats: fp1 %"PRIu64" fp2 %"PRIu64" sp %"PRIu64, - ra_ctx->fp1, ra_ctx->fp2, ra_ctx->sp); -#endif SCFree(ra_ctx); SCReturn; } diff --git a/src/stream-tcp-reassemble.h b/src/stream-tcp-reassemble.h index b0026484a5..5cdf88e6eb 100644 --- a/src/stream-tcp-reassemble.h +++ b/src/stream-tcp-reassemble.h @@ -59,11 +59,6 @@ typedef struct TcpReassemblyThreadCtx_ { uint16_t counter_tcp_stream_depth; /** count number of streams with a unrecoverable stream gap (missing pkts) */ uint16_t counter_tcp_reass_gap; -#ifdef DEBUG - uint64_t fp1; - uint64_t fp2; - uint64_t sp; -#endif } TcpReassemblyThreadCtx; #define OS_POLICY_DEFAULT OS_POLICY_BSD diff --git a/src/stream-tcp.h b/src/stream-tcp.h index 087bc7eb7c..fb69ed145e 100644 --- a/src/stream-tcp.h +++ b/src/stream-tcp.h @@ -51,9 +51,6 @@ typedef struct TcpStreamCnf_ { uint32_t ssn_init_flags; /**< new ssn flags will be initialized to this */ uint8_t segment_init_flags; /**< new seg flags will be initialized to this */ - uint16_t zero_copy_size; /**< use zero copy for app layer above segments - * of this size */ - uint32_t prealloc_sessions; /**< ssns to prealloc per stream thread */ int midstream; int async_oneside; @@ -62,7 +59,6 @@ typedef struct TcpStreamCnf_ { uint16_t reassembly_toserver_chunk_size; uint16_t reassembly_toclient_chunk_size; - int check_overlap_different_data; int bypass; uint8_t flags; diff --git a/suricata.yaml.in b/suricata.yaml.in index 7e94640e02..4f2dd63220 100644 --- a/suricata.yaml.in +++ b/suricata.yaml.in @@ -1208,11 +1208,6 @@ flow-timeouts: # - size: 4 # Size of the (data)segment for a pool # prealloc: 256 # Number of segments to prealloc and keep # # in the pool. -# zero-copy-size: 128 # This option sets in bytes the value at -# # which segment data is passed to the app -# # layer API directly. Data sizes equal to -# # and higher than the value set are passed -# # on directly. # stream: memcap: 64mb @@ -1246,7 +1241,6 @@ stream: # prealloc: 1024 # - size: 65535 # prealloc: 128 - #zero-copy-size: 128 # Host table: #