From: David S. Miller Date: Tue, 25 Jan 2022 11:25:22 +0000 (+0000) Subject: Merge branch 'netns-speedup-dismantle' X-Git-Tag: v5.18-rc1~136^2~537 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=51d555cfdcc60436850f75daa6e379ba08e7a68c;p=thirdparty%2Fkernel%2Flinux.git Merge branch 'netns-speedup-dismantle' Eric Dumazet says: ==================== netns: speedup netns dismantles netns are dismantled by a single thread, from cleanup_net() On hosts with many TCP sockets, and/or many cpus, this thread is spending too many cpu cycles, and can not keep up with some workloads. - Removing 3*num_possible_cpus() sockets per netns, for icmp and tcp protocols. - Iterating over all TCP sockets to remove stale timewait sockets. This patch series removes ~50% of cleanup_net() cpu costs on hosts with 256 cpus. It also reduces per netns memory footprint. ==================== Signed-off-by: David S. Miller --- 51d555cfdcc60436850f75daa6e379ba08e7a68c