Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4ba351cf authored by Jan Engelhardt's avatar Jan Engelhardt
Browse files

netfilter: xtables: use NFPROTO_ in standard targets

parent 4b1e27e9
Loading
Loading
Loading
Loading
+3 −3
Original line number Original line Diff line number Diff line
@@ -2158,7 +2158,7 @@ static bool icmp_checkentry(const struct xt_mtchk_param *par)
static struct xt_target ipt_standard_target __read_mostly = {
static struct xt_target ipt_standard_target __read_mostly = {
	.name		= IPT_STANDARD_TARGET,
	.name		= IPT_STANDARD_TARGET,
	.targetsize	= sizeof(int),
	.targetsize	= sizeof(int),
	.family		= AF_INET,
	.family		= NFPROTO_IPV4,
#ifdef CONFIG_COMPAT
#ifdef CONFIG_COMPAT
	.compatsize	= sizeof(compat_int_t),
	.compatsize	= sizeof(compat_int_t),
	.compat_from_user = compat_standard_from_user,
	.compat_from_user = compat_standard_from_user,
@@ -2170,7 +2170,7 @@ static struct xt_target ipt_error_target __read_mostly = {
	.name		= IPT_ERROR_TARGET,
	.name		= IPT_ERROR_TARGET,
	.target		= ipt_error,
	.target		= ipt_error,
	.targetsize	= IPT_FUNCTION_MAXNAMELEN,
	.targetsize	= IPT_FUNCTION_MAXNAMELEN,
	.family		= AF_INET,
	.family		= NFPROTO_IPV4,
};
};


static struct nf_sockopt_ops ipt_sockopts = {
static struct nf_sockopt_ops ipt_sockopts = {
@@ -2196,7 +2196,7 @@ static struct xt_match icmp_matchstruct __read_mostly = {
	.matchsize	= sizeof(struct ipt_icmp),
	.matchsize	= sizeof(struct ipt_icmp),
	.checkentry	= icmp_checkentry,
	.checkentry	= icmp_checkentry,
	.proto		= IPPROTO_ICMP,
	.proto		= IPPROTO_ICMP,
	.family		= AF_INET,
	.family		= NFPROTO_IPV4,
};
};


static int __net_init ip_tables_net_init(struct net *net)
static int __net_init ip_tables_net_init(struct net *net)
+3 −3
Original line number Original line Diff line number Diff line
@@ -2191,7 +2191,7 @@ static bool icmp6_checkentry(const struct xt_mtchk_param *par)
static struct xt_target ip6t_standard_target __read_mostly = {
static struct xt_target ip6t_standard_target __read_mostly = {
	.name		= IP6T_STANDARD_TARGET,
	.name		= IP6T_STANDARD_TARGET,
	.targetsize	= sizeof(int),
	.targetsize	= sizeof(int),
	.family		= AF_INET6,
	.family		= NFPROTO_IPV6,
#ifdef CONFIG_COMPAT
#ifdef CONFIG_COMPAT
	.compatsize	= sizeof(compat_int_t),
	.compatsize	= sizeof(compat_int_t),
	.compat_from_user = compat_standard_from_user,
	.compat_from_user = compat_standard_from_user,
@@ -2203,7 +2203,7 @@ static struct xt_target ip6t_error_target __read_mostly = {
	.name		= IP6T_ERROR_TARGET,
	.name		= IP6T_ERROR_TARGET,
	.target		= ip6t_error,
	.target		= ip6t_error,
	.targetsize	= IP6T_FUNCTION_MAXNAMELEN,
	.targetsize	= IP6T_FUNCTION_MAXNAMELEN,
	.family		= AF_INET6,
	.family		= NFPROTO_IPV6,
};
};


static struct nf_sockopt_ops ip6t_sockopts = {
static struct nf_sockopt_ops ip6t_sockopts = {
@@ -2229,7 +2229,7 @@ static struct xt_match icmp6_matchstruct __read_mostly = {
	.matchsize	= sizeof(struct ip6t_icmp),
	.matchsize	= sizeof(struct ip6t_icmp),
	.checkentry	= icmp6_checkentry,
	.checkentry	= icmp6_checkentry,
	.proto		= IPPROTO_ICMPV6,
	.proto		= IPPROTO_ICMPV6,
	.family		= AF_INET6,
	.family		= NFPROTO_IPV6,
};
};


static int __net_init ip6_tables_net_init(struct net *net)
static int __net_init ip6_tables_net_init(struct net *net)