summaryrefslogtreecommitdiffstats
path: root/net/sched/em_canid.c
diff options
context:
space:
mode:
authorDuan Jiong <duanj.fnst@cn.fujitsu.com>2014-06-18 16:48:39 +0800
committerDavid S. Miller <davem@davemloft.net>2014-06-21 15:40:22 -0700
commit2b74e2caece67798195228775306aa97dbc51516 (patch)
tree01bd471f1a4583baa1b317d3f290d85b5fa6f714 /net/sched/em_canid.c
parenta3f5ee71cdec56543e0420a788dc7df335944dd5 (diff)
downloadlinux-2b74e2caece67798195228775306aa97dbc51516.tar.gz
linux-2b74e2caece67798195228775306aa97dbc51516.tar.bz2
linux-2b74e2caece67798195228775306aa97dbc51516.zip
net: em_canid: remove useless statements from em_canid_change
tcf_ematch is allocated by kzalloc in function tcf_em_tree_validate(), so cm_old is always NULL. Signed-off-by: Duan Jiong <duanj.fnst@cn.fujitsu.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/em_canid.c')
-rw-r--r--net/sched/em_canid.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/net/sched/em_canid.c b/net/sched/em_canid.c
index bfd34e4c1afc..7c292d474f47 100644
--- a/net/sched/em_canid.c
+++ b/net/sched/em_canid.c
@@ -125,7 +125,6 @@ static int em_canid_change(struct tcf_proto *tp, void *data, int len,
{
struct can_filter *conf = data; /* Array with rules */
struct canid_match *cm;
- struct canid_match *cm_old = (struct canid_match *)m->data;
int i;
if (!len)
@@ -181,12 +180,6 @@ static int em_canid_change(struct tcf_proto *tp, void *data, int len,
m->datalen = sizeof(struct canid_match) + len;
m->data = (unsigned long)cm;
-
- if (cm_old != NULL) {
- pr_err("canid: Configuring an existing ematch!\n");
- kfree(cm_old);
- }
-
return 0;
}