]> git.baikalelectronics.ru Git - kernel.git/commit
netfilter: Add helper array register/unregister functions
authorGao Feng <fgao@ikuai8.com>
Mon, 18 Jul 2016 03:39:23 +0000 (11:39 +0800)
committerPablo Neira Ayuso <pablo@netfilter.org>
Thu, 21 Jul 2016 00:31:53 +0000 (02:31 +0200)
commitf1bbf7d29f4d728a7ed633f8e02bae5109e223ba
treebb5a8fac8e8e0978ca9e13417f3df80a12c1a0ba
parent50e2990497e1336ba842fe9856a1febfc99edfb4
netfilter: Add helper array register/unregister functions

Add nf_ct_helper_init(), nf_conntrack_helpers_register() and
nf_conntrack_helpers_unregister() functions to avoid repetitive
opencoded initialization in helpers.

This patch keeps an id parameter for nf_ct_helper_init() not to break
helper matching by name that has been inconsistently exposed to
userspace through ports, eg. ftp-2121, and through an incremental id,
eg. tftp-1.

Signed-off-by: Gao Feng <fgao@ikuai8.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
include/net/netfilter/nf_conntrack_helper.h
net/netfilter/nf_conntrack_ftp.c
net/netfilter/nf_conntrack_helper.c
net/netfilter/nf_conntrack_irc.c
net/netfilter/nf_conntrack_sane.c
net/netfilter/nf_conntrack_sip.c
net/netfilter/nf_conntrack_tftp.c