From: Jiri Pirko Date: Mon, 22 May 2017 14:46:13 +0000 (+0200) Subject: net: sched: cls_matchall: fix null pointer dereference X-Git-Tag: MMI-PSA29.97-13-9~5548^2 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=2d76b2f8b54abd16225cd80afca36ed43f113c41;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git net: sched: cls_matchall: fix null pointer dereference Since the head is guaranteed by the check above to be null, the call_rcu would explode. Remove the previously logically dead code that was made logically very much alive and kicking. Fixes: 985538eee06f ("net/sched: remove redundant null check on head") Signed-off-by: Jiri Pirko Signed-off-by: David S. Miller --- diff --git a/net/sched/cls_matchall.c b/net/sched/cls_matchall.c index dee469fed967..51859b8edd7e 100644 --- a/net/sched/cls_matchall.c +++ b/net/sched/cls_matchall.c @@ -203,7 +203,6 @@ static int mall_change(struct net *net, struct sk_buff *in_skb, *arg = (unsigned long) head; rcu_assign_pointer(tp->root, new); - call_rcu(&head->rcu, mall_destroy_rcu); return 0; err_replace_hw_filter: