affinity: remove unused settings

These were never referenced to in the code so they can be removed.

Add bypass to config parser in case the settings are still in old
yamls.
pull/2137/head
Victor Julien 9 years ago
parent bdc2c6e9ce
commit 570b9d06e0

@ -38,18 +38,6 @@ ThreadsAffinityType thread_affinity[MAX_CPU_SET] = {
.prio = PRIO_MEDIUM,
.lcpu = 0,
},
{
.name = "decode-cpu-set",
.mode_flag = BALANCED_AFFINITY,
.prio = PRIO_MEDIUM,
.lcpu = 0,
},
{
.name = "stream-cpu-set",
.mode_flag = BALANCED_AFFINITY,
.prio = PRIO_MEDIUM,
.lcpu = 0,
},
{
.name = "detect-cpu-set",
.mode_flag = EXCLUSIVE_AFFINITY,
@ -62,18 +50,6 @@ ThreadsAffinityType thread_affinity[MAX_CPU_SET] = {
.prio = PRIO_MEDIUM,
.lcpu = 0,
},
{
.name = "reject-cpu-set",
.mode_flag = BALANCED_AFFINITY,
.prio = PRIO_MEDIUM,
.lcpu = 0,
},
{
.name = "output-cpu-set",
.mode_flag = BALANCED_AFFINITY,
.prio = PRIO_MEDIUM,
.lcpu = 0,
},
{
.name = "management-cpu-set",
.mode_flag = BALANCED_AFFINITY,
@ -206,6 +182,13 @@ void AffinitySetupLoadFromConfig()
}
TAILQ_FOREACH(affinity, &root->head, next) {
if (strcmp(affinity->val, "decode-cpu-set") == 0 ||
strcmp(affinity->val, "stream-cpu-set") == 0 ||
strcmp(affinity->val, "reject-cpu-set") == 0 ||
strcmp(affinity->val, "output-cpu-set") == 0) {
continue;
}
ThreadsAffinityType *taf = GetAffinityTypeFromName(affinity->val);
ConfNode *node = NULL;
ConfNode *nprio = NULL;

@ -48,12 +48,8 @@
enum {
RECEIVE_CPU_SET,
DECODE_CPU_SET,
STREAM_CPU_SET,
DETECT_CPU_SET,
VERDICT_CPU_SET,
REJECT_CPU_SET,
OUTPUT_CPU_SET,
MANAGEMENT_CPU_SET,
MAX_CPU_SET
};

@ -1278,11 +1278,6 @@ threading:
cpu: [ 0 ] # include only these cpus in affinity settings
- receive-cpu-set:
cpu: [ 0 ] # include only these cpus in affinity settings
- decode-cpu-set:
cpu: [ 0, 1 ]
mode: "balanced"
- stream-cpu-set:
cpu: [ "0-1" ]
- detect-cpu-set:
cpu: [ "all" ]
mode: "exclusive" # run detect threads in these cpus
@ -1298,14 +1293,6 @@ threading:
cpu: [ 0 ]
prio:
default: "high"
- reject-cpu-set:
cpu: [ 0 ]
prio:
default: "low"
- output-cpu-set:
cpu: [ "all" ]
prio:
default: "medium"
#
# By default Suricata creates one "detect" thread per available CPU/CPU core.
# This setting allows controlling this behaviour. A ratio setting of 2 will

Loading…
Cancel
Save