flow: use livedev for ftp-hash

Completes commit 7e725c650d

autofp-scheduler with value ftp-hash ends up using
FlowGetIpPairProtoHash which ignores the ports for ftp-looking
flows so that the ftp and ftp-data flow get processed by the
same thread.

As for the other cases, we want to use every other parameter
to compute the flow hash, inclusing the live device
pull/15740/head
Philippe Antoine 2 months ago committed by Victor Julien
parent f4388d45c6
commit fe728d97d8

@ -130,6 +130,7 @@ uint32_t FlowGetIpPairProtoHash(const Packet *p)
fhk.ports[1] = 0xba98;
fhk.proto = (uint8_t)p->proto;
fhk.livedev = p->livedev_id & g_livedev_mask;
/* g_recurlvl_mask sets the recursion_level to 0 if
* decoder.recursion-level.use-for-tracking is disabled.
*/
@ -168,6 +169,7 @@ uint32_t FlowGetIpPairProtoHash(const Packet *p)
fhk.ports[0] = 0xfedc;
fhk.ports[1] = 0xba98;
fhk.proto = (uint8_t)p->proto;
fhk.livedev = p->livedev_id & g_livedev_mask;
fhk.recur = (uint8_t)p->recursion_level & g_recurlvl_mask;
fhk.vlan_id[0] = p->vlan_id[0] & g_vlan_mask;
fhk.vlan_id[1] = p->vlan_id[1] & g_vlan_mask;

Loading…
Cancel
Save