Exemple #1
0
int __init xfrm6_init(void)
{
	int ret;

	dst_entries_init(&xfrm6_dst_ops);

	ret = xfrm6_policy_init();
	if (ret) {
		dst_entries_destroy(&xfrm6_dst_ops);
		goto out;
	}
	ret = xfrm6_state_init();
	if (ret)
		goto out_policy;

	ret = xfrm6_protocol_init();
	if (ret)
		goto out_state;

#ifdef CONFIG_SYSCTL
	register_pernet_subsys(&xfrm6_net_ops);
#endif
out:
	return ret;
out_state:
	xfrm6_state_fini();
out_policy:
	xfrm6_policy_fini();
	goto out;
}
Exemple #2
0
void xfrm6_fini(void)
{
#ifdef CONFIG_SYSCTL
	unregister_pernet_subsys(&xfrm6_net_ops);
#endif
	xfrm6_policy_fini();
	xfrm6_state_fini();
	dst_entries_destroy(&xfrm6_dst_ops);
}
void xfrm6_fini(void)
{
#ifdef CONFIG_SYSCTL
	if (sysctl_hdr)
		unregister_net_sysctl_table(sysctl_hdr);
#endif
	//xfrm6_input_fini();
	xfrm6_policy_fini();
	xfrm6_state_fini();
}
Exemple #4
0
void xfrm6_fini(void)
{
#ifdef CONFIG_SYSCTL
	if (sysctl_hdr)
		unregister_net_sysctl_table(sysctl_hdr);
#endif
	xfrm6_policy_fini();
	xfrm6_state_fini();
	dst_entries_destroy(&xfrm6_dst_ops);
}
void __exit xfrm6_fini(void)
{
	//xfrm6_input_fini();
	xfrm6_policy_fini();
	xfrm6_state_fini();
}