Skip to content

Commit

Permalink
threading: remove TM_FLAG_DECODE_TM flag
Browse files Browse the repository at this point in the history
  • Loading branch information
victorjulien committed Jul 14, 2024
1 parent b946759 commit a29114e
Show file tree
Hide file tree
Showing 11 changed files with 1 addition and 19 deletions.
2 changes: 0 additions & 2 deletions src/source-af-xdp.c
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,6 @@ void TmModuleDecodeAFXDPRegister(void)
tmm_modules[TMM_DECODEAFXDP].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODEAFXDP].ThreadDeinit = NULL;
tmm_modules[TMM_DECODEAFXDP].cap_flags = 0;
tmm_modules[TMM_DECODEAFXDP].flags = TM_FLAG_DECODE_TM;
}

/**
Expand Down Expand Up @@ -236,7 +235,6 @@ void TmModuleDecodeAFXDPRegister(void)
tmm_modules[TMM_DECODEAFXDP].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODEAFXDP].ThreadDeinit = DecodeAFXDPThreadDeinit;
tmm_modules[TMM_DECODEAFXDP].cap_flags = 0;
tmm_modules[TMM_DECODEAFXDP].flags = TM_FLAG_DECODE_TM;
}

static inline void AFXDPDumpCounters(AFXDPThreadVars *ptv)
Expand Down
2 changes: 0 additions & 2 deletions src/source-erf-dag.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ TmModuleDecodeErfDagRegister(void)
tmm_modules[TMM_DECODEERFDAG].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODEERFDAG].ThreadDeinit = NULL;
tmm_modules[TMM_DECODEERFDAG].cap_flags = 0;
tmm_modules[TMM_DECODEERFDAG].flags = TM_FLAG_DECODE_TM;
}

TmEcode
Expand Down Expand Up @@ -156,7 +155,6 @@ TmModuleDecodeErfDagRegister(void)
tmm_modules[TMM_DECODEERFDAG].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODEERFDAG].ThreadDeinit = DecodeErfDagThreadDeinit;
tmm_modules[TMM_DECODEERFDAG].cap_flags = 0;
tmm_modules[TMM_DECODEERFDAG].flags = TM_FLAG_DECODE_TM;
}

/**
Expand Down
1 change: 0 additions & 1 deletion src/source-erf-file.c
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@ TmModuleDecodeErfFileRegister(void)
tmm_modules[TMM_DECODEERFFILE].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODEERFFILE].ThreadDeinit = DecodeErfFileThreadDeinit;
tmm_modules[TMM_DECODEERFFILE].cap_flags = 0;
tmm_modules[TMM_DECODEERFFILE].flags = TM_FLAG_DECODE_TM;
}

/**
Expand Down
2 changes: 0 additions & 2 deletions src/source-ipfw.c
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ void TmModuleDecodeIPFWRegister (void)
tmm_modules[TMM_DECODEIPFW].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODEIPFW].ThreadDeinit = NULL;
tmm_modules[TMM_DECODEIPFW].cap_flags = 0;
tmm_modules[TMM_DECODEIPFW].flags = TM_FLAG_DECODE_TM;
}

TmEcode NoIPFWSupportExit(ThreadVars *tv, const void *initdata, void **data)
Expand Down Expand Up @@ -190,7 +189,6 @@ void TmModuleDecodeIPFWRegister (void)
tmm_modules[TMM_DECODEIPFW].Func = DecodeIPFW;
tmm_modules[TMM_DECODEIPFW].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODEIPFW].ThreadDeinit = DecodeIPFWThreadDeinit;
tmm_modules[TMM_DECODEIPFW].flags = TM_FLAG_DECODE_TM;
}

static inline void IPFWMutexInit(IPFWQueueVars *nq)
Expand Down
2 changes: 0 additions & 2 deletions src/source-napatech.c
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ void TmModuleNapatechDecodeRegister(void)
tmm_modules[TMM_DECODENAPATECH].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODENAPATECH].ThreadDeinit = NULL;
tmm_modules[TMM_DECODENAPATECH].cap_flags = 0;
tmm_modules[TMM_DECODENAPATECH].flags = TM_FLAG_DECODE_TM;
}

TmEcode NoNapatechSupportExit(ThreadVars *tv, const void *initdata, void **data)
Expand Down Expand Up @@ -197,7 +196,6 @@ void TmModuleNapatechDecodeRegister(void)
tmm_modules[TMM_DECODENAPATECH].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODENAPATECH].ThreadDeinit = NapatechDecodeThreadDeinit;
tmm_modules[TMM_DECODENAPATECH].cap_flags = 0;
tmm_modules[TMM_DECODENAPATECH].flags = TM_FLAG_DECODE_TM;
}

#ifdef NAPATECH_ENABLE_BYPASS
Expand Down
2 changes: 0 additions & 2 deletions src/source-netmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,6 @@ void TmModuleDecodeNetmapRegister (void)
{
tmm_modules[TMM_DECODENETMAP].name = "DecodeNetmap";
tmm_modules[TMM_DECODENETMAP].ThreadInit = NoNetmapSupportExit;
tmm_modules[TMM_DECODENETMAP].flags = TM_FLAG_DECODE_TM;
}

#else /* We have NETMAP support */
Expand Down Expand Up @@ -985,7 +984,6 @@ void TmModuleDecodeNetmapRegister(void)
tmm_modules[TMM_DECODENETMAP].Func = DecodeNetmap;
tmm_modules[TMM_DECODENETMAP].ThreadDeinit = DecodeNetmapThreadDeinit;
tmm_modules[TMM_DECODENETMAP].cap_flags = 0;
tmm_modules[TMM_DECODENETMAP].flags = TM_FLAG_DECODE_TM;
}

#endif /* HAVE_NETMAP */
Expand Down
1 change: 0 additions & 1 deletion src/source-nflog.c
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,6 @@ void TmModuleDecodeNFLOGRegister (void)
tmm_modules[TMM_DECODENFLOG].Func = DecodeNFLOG;
tmm_modules[TMM_DECODENFLOG].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODENFLOG].ThreadDeinit = DecodeNFLOGThreadDeinit;
tmm_modules[TMM_DECODENFLOG].flags = TM_FLAG_DECODE_TM;
}

/**
Expand Down
2 changes: 0 additions & 2 deletions src/source-nfq.c
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ void TmModuleDecodeNFQRegister (void)
tmm_modules[TMM_DECODENFQ].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODENFQ].ThreadDeinit = NULL;
tmm_modules[TMM_DECODENFQ].cap_flags = 0;
tmm_modules[TMM_DECODENFQ].flags = TM_FLAG_DECODE_TM;
}

static TmEcode NoNFQSupportExit(ThreadVars *tv, const void *initdata, void **data)
Expand Down Expand Up @@ -195,7 +194,6 @@ void TmModuleDecodeNFQRegister (void)
tmm_modules[TMM_DECODENFQ].ThreadInit = DecodeNFQThreadInit;
tmm_modules[TMM_DECODENFQ].Func = DecodeNFQ;
tmm_modules[TMM_DECODENFQ].ThreadDeinit = DecodeNFQThreadDeinit;
tmm_modules[TMM_DECODENFQ].flags = TM_FLAG_DECODE_TM;
}

/** \brief To initialize the NFQ global configuration data
Expand Down
2 changes: 0 additions & 2 deletions src/source-pfring.c
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,6 @@ void TmModuleDecodePfringRegister (void)
tmm_modules[TMM_DECODEPFRING].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODEPFRING].ThreadDeinit = NULL;
tmm_modules[TMM_DECODEPFRING].cap_flags = 0;
tmm_modules[TMM_DECODEPFRING].flags = TM_FLAG_DECODE_TM;
}

/**
Expand Down Expand Up @@ -183,7 +182,6 @@ void TmModuleDecodePfringRegister (void)
tmm_modules[TMM_DECODEPFRING].Func = DecodePfring;
tmm_modules[TMM_DECODEPFRING].ThreadExitPrintStats = NULL;
tmm_modules[TMM_DECODEPFRING].ThreadDeinit = DecodePfringThreadDeinit;
tmm_modules[TMM_DECODEPFRING].flags = TM_FLAG_DECODE_TM;
}

static inline void PfringDumpCounters(PfringThreadVars *ptv)
Expand Down
2 changes: 0 additions & 2 deletions src/source-windivert.c
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ void TmModuleDecodeWinDivertRegister(void)
{
tmm_modules[TMM_DECODEWINDIVERT].name = "DecodeWinDivert";
tmm_modules[TMM_DECODEWINDIVERT].ThreadInit = NoWinDivertSupportExit;
tmm_modules[TMM_DECODEWINDIVERT].flags = TM_FLAG_DECODE_TM;
}

TmEcode NoWinDivertSupportExit(ThreadVars *tv, const void *initdata,
Expand Down Expand Up @@ -392,7 +391,6 @@ void TmModuleDecodeWinDivertRegister(void)
tm_ptr->ThreadInit = DecodeWinDivertThreadInit;
tm_ptr->Func = DecodeWinDivert;
tm_ptr->ThreadDeinit = DecodeWinDivertThreadDeinit;
tm_ptr->flags = TM_FLAG_DECODE_TM;
}

/**
Expand Down
2 changes: 1 addition & 1 deletion src/tm-modules.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@

/* thread flags */
#define TM_FLAG_RECEIVE_TM 0x01
#define TM_FLAG_DECODE_TM 0x02
//
#define TM_FLAG_STREAM_TM 0x04
#define TM_FLAG_DETECT_TM 0x08
#define TM_FLAG_LOGAPI_TM 0x10 /**< TM is run by Log API */
Expand Down

0 comments on commit a29114e

Please sign in to comment.