From 405fc580ea748a0ee2c37d46aad9a8a841cfa510 Mon Sep 17 00:00:00 2001 From: Ralph Eastwood Date: Wed, 16 Aug 2023 10:30:37 +0200 Subject: [PATCH] napatech: remove superfluous log messages --- src/source-napatech.c | 15 ++++++++------- src/util-napatech.c | 2 -- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/src/source-napatech.c b/src/source-napatech.c index f646c42030..6654fbc600 100644 --- a/src/source-napatech.c +++ b/src/source-napatech.c @@ -813,13 +813,14 @@ TmEcode NapatechPacketLoop(ThreadVars *tv, void *data, void *slot) #ifdef NAPATECH_ENABLE_BYPASS NtFlowStream_t flow_stream[MAX_ADAPTERS] = { 0 }; - - /* Get a FlowStream handle for each adapter so we can efficiently find the - * correct handle corresponding to the port on which a packet is received. - */ - int adapter = 0; - for (adapter = 0; adapter < NapatechGetNumAdapters(); ++adapter) { - flow_stream[adapter] = InitFlowStream(adapter, ntv->stream_id); + if (NapatechUseHWBypass()) { + /* Get a FlowStream handle for each adapter so we can efficiently find the + * correct handle corresponding to the port on which a packet is received. + */ + int adapter = 0; + for (adapter = 0; adapter < NapatechGetNumAdapters(); ++adapter) { + flow_stream[adapter] = InitFlowStream(adapter, ntv->stream_id); + } } #endif diff --git a/src/util-napatech.c b/src/util-napatech.c index e8c842fabc..affcd49cbb 100644 --- a/src/util-napatech.c +++ b/src/util-napatech.c @@ -1409,8 +1409,6 @@ uint32_t NapatechSetupTraffic(uint32_t first_stream, uint32_t last_stream) #ifdef NAPATECH_ENABLE_BYPASS if (NapatechUseHWBypass()) { SCLogInfo("Napatech Hardware Bypass enabled."); - } else { - SCLogInfo("Napatech Hardware Bypass available but disabled."); } #else if (NapatechUseHWBypass()) { -- 2.47.2