Re: [PATCH net] dccp: call inet_add_protocol after register_pernet_subsys in dccp_v4_init

2017-06-20 Thread David Miller
From: Xin Long Date: Tue, 20 Jun 2017 15:42:38 +0800 > Now dccp_ipv4 works as a kernel module. During loading this module, if > one dccp packet is being recieved after inet_add_protocol but before > register_pernet_subsys in which v4_ctl_sk is initialized, a null pointer >

[PATCH net] dccp: call inet_add_protocol after register_pernet_subsys in dccp_v4_init

2017-06-20 Thread Xin Long
Now dccp_ipv4 works as a kernel module. During loading this module, if one dccp packet is being recieved after inet_add_protocol but before register_pernet_subsys in which v4_ctl_sk is initialized, a null pointer dereference may be triggered because of init_net.dccp.v4_ctl_sk is 0x0. Jianlin