From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kirill Tkhai Subject: [PATCH RFC 17/25] net: Move audit_net_ops to pernet_sys list Date: Fri, 17 Nov 2017 21:29:58 +0300 Message-ID: <151094339851.20009.16100717381823905233.stgit@localhost.localdomain> References: <151094119999.20009.6955267140148739392.stgit@localhost.localdomain> Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit To: davem@davemloft.net, vyasevic@redhat.com, kstewart@linuxfoundation.org, pombredanne@nexb.com, vyasevich@gmail.com, mark.rutland@arm.com, gregkh@linuxfoundation.org, adobriyan@gmail.com, fw@strlen.de, nicolas.dichtel@6wind.com, xiyou.wangcong@gmail.com, roman.kapl@sysgo.com, paul@paul-moore.com, dsahern@gmail.com, daniel@iogearbox.net, lucien.xin@gmail.com, mschiffer@universe-factory.net, rshearma@brocade.com, linux-kernel@vger.kernel.org, netdev@vger.kernel.org, ktkhai@virtuozzo.com, ebiederm@xmission.com, avagin@virtuozzo.com, gorcunov@virtuozzo.com, eric.dumazet@gmail.com, stephen@networkplumber.org, ktkhai@virtuozzo.com Return-path: Received: from mail-eopbgr40091.outbound.protection.outlook.com ([40.107.4.91]:51648 "EHLO EUR03-DB5-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1760819AbdKQSaG (ORCPT ); Fri, 17 Nov 2017 13:30:06 -0500 In-Reply-To: <151094119999.20009.6955267140148739392.stgit@localhost.localdomain> Sender: netdev-owner@vger.kernel.org List-ID: This patch starts to convert pernet_subsys, registered from postcore initcalls. These pernet_operations are in ./kernel directory, and there are only one more postcore in ./lib. So, audit_net_ops have to go the first. audit_net_init() creates netlink socket, while audit_net_exit() destroys it. The rest of the pernet_list are not interested in the socket, so we move audit_net_ops to pernet_sys list. Signed-off-by: Kirill Tkhai --- kernel/audit.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/audit.c b/kernel/audit.c index 227db99b0f19..bb4626d7e712 100644 --- a/kernel/audit.c +++ b/kernel/audit.c @@ -1549,7 +1549,7 @@ static int __init audit_init(void) pr_info("initializing netlink subsys (%s)\n", audit_default ? "enabled" : "disabled"); - register_pernet_subsys(&audit_net_ops); + register_pernet_sys(&audit_net_ops); audit_initialized = AUDIT_INITIALIZED;