Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7bb6615d authored by Nicolas Dichtel's avatar Nicolas Dichtel Committed by Pablo Neira Ayuso
Browse files

netfilter: conntrack: restart gc immediately if GC_MAX_EVICTS is reached



When the maximum evictions number is reached, do not wait 5 seconds before
the next run.

CC: Florian Westphal <fw@strlen.de>
Signed-off-by: default avatarNicolas Dichtel <nicolas.dichtel@6wind.com>
Acked-by: default avatarFlorian Westphal <fw@strlen.de>
Signed-off-by: default avatarPablo Neira Ayuso <pablo@netfilter.org>
parent 1ecc281e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -983,7 +983,7 @@ static void gc_worker(struct work_struct *work)
		return;

	ratio = scanned ? expired_count * 100 / scanned : 0;
	if (ratio >= 90)
	if (ratio >= 90 || expired_count == GC_MAX_EVICTS)
		next_run = 0;

	gc_work->last_bucket = i;