]> git.baikalelectronics.ru Git - kernel.git/commit
net: sched: fix error path in tcf_proto_create() when modules are not configured
authorJiri Pirko <jiri@mellanox.com>
Fri, 11 May 2018 15:45:32 +0000 (17:45 +0200)
committerDavid S. Miller <davem@davemloft.net>
Fri, 11 May 2018 20:34:38 +0000 (16:34 -0400)
commit48aab7b4ad82849c446362840d68d1a45de4bc59
treedd5a0c560c891823e6341b61bde23338d477c700
parent0716e2b80b4b649521786ed49fbff086e665dd5b
net: sched: fix error path in tcf_proto_create() when modules are not configured

In case modules are not configured, error out when tp->ops is null
and prevent later null pointer dereference.

Fixes: 3dd45a64b649 ("sched: push TC filter protocol creation into a separate function")
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Acked-by: Cong Wang <xiyou.wangcong@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sched/cls_api.c