OSDN Git Service

netfilter: nf_flow_table: add support for sending flows back to the slow path
authorFelix Fietkau <nbd@nbd.name>
Mon, 26 Feb 2018 09:15:23 +0000 (10:15 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Tue, 24 Apr 2018 08:28:59 +0000 (10:28 +0200)
commitda5984e51063a2c8723a36c29f090e03b3ff2a35
tree3b072913f65ae7043a8f349306b469a9b32fcd44
parentba03137f4c0c96d1f1f498632f868a2b743b155a
netfilter: nf_flow_table: add support for sending flows back to the slow path

Since conntrack hasn't seen any packets from the offloaded flow in a
while, and the timeout for offloaded flows is set to an extremely long
value, we need to fix up the state before we can send a flow back to the
slow path.

For TCP, reset td_maxwin in both directions, which makes it resync its
state on the next packets.

Use the regular timeout for TCP and UDP established connections.

This allows the slow path to take over again once the offload state has
been torn down

Signed-off-by: Felix Fietkau <nbd@nbd.name>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
net/netfilter/nf_flow_table_core.c