You need to sign in or sign up before continuing.
提交 fda61436 编写于 作者: Y Yasuyuki Kozakai 提交者: David S. Miller

[NETFILTER]: nf_conntrack: Removes unused destroy operation of l3proto

Signed-off-by: NYasuyuki Kozakai <yasuyuki.kozakai@toshiba.co.jp>
Signed-off-by: NPatrick McHardy <kaber@trash.net>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 c874d5f7
...@@ -56,9 +56,6 @@ struct nf_conntrack_l3proto ...@@ -56,9 +56,6 @@ struct nf_conntrack_l3proto
*/ */
int (*new)(struct nf_conn *conntrack, const struct sk_buff *skb); int (*new)(struct nf_conn *conntrack, const struct sk_buff *skb);
/* Called when a conntrack entry is destroyed */
void (*destroy)(struct nf_conn *conntrack);
/* /*
* Called before tracking. * Called before tracking.
* *dataoff: offset of protocol header (TCP, UDP,...) in *pskb * *dataoff: offset of protocol header (TCP, UDP,...) in *pskb
......
...@@ -299,7 +299,6 @@ destroy_conntrack(struct nf_conntrack *nfct) ...@@ -299,7 +299,6 @@ destroy_conntrack(struct nf_conntrack *nfct)
{ {
struct nf_conn *ct = (struct nf_conn *)nfct; struct nf_conn *ct = (struct nf_conn *)nfct;
struct nf_conn_help *help = nfct_help(ct); struct nf_conn_help *help = nfct_help(ct);
struct nf_conntrack_l3proto *l3proto;
struct nf_conntrack_l4proto *l4proto; struct nf_conntrack_l4proto *l4proto;
typeof(nf_conntrack_destroyed) destroyed; typeof(nf_conntrack_destroyed) destroyed;
...@@ -317,10 +316,6 @@ destroy_conntrack(struct nf_conntrack *nfct) ...@@ -317,10 +316,6 @@ destroy_conntrack(struct nf_conntrack *nfct)
* destroy_conntrack() MUST NOT be called with a write lock * destroy_conntrack() MUST NOT be called with a write lock
* to nf_conntrack_lock!!! -HW */ * to nf_conntrack_lock!!! -HW */
rcu_read_lock(); rcu_read_lock();
l3proto = __nf_ct_l3proto_find(ct->tuplehash[IP_CT_DIR_REPLY].tuple.src.l3num);
if (l3proto && l3proto->destroy)
l3proto->destroy(ct);
l4proto = __nf_ct_l4proto_find(ct->tuplehash[IP_CT_DIR_REPLY].tuple.src.l3num, l4proto = __nf_ct_l4proto_find(ct->tuplehash[IP_CT_DIR_REPLY].tuple.src.l3num,
ct->tuplehash[IP_CT_DIR_REPLY].tuple.dst.protonum); ct->tuplehash[IP_CT_DIR_REPLY].tuple.dst.protonum);
if (l4proto && l4proto->destroy) if (l4proto && l4proto->destroy)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册