mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 19:51:31 -04:00
netfilter: xtables: deconstify struct xt_action_param for matches
In future, layer-3 matches will be an xt module of their own, and need to set the fragoff and thoff fields. Adding more pointers would needlessy increase memory requirements (esp. so for 64-bit, where pointers are wider). Signed-off-by: Jan Engelhardt <[email protected]>
This commit is contained in:
parent
4b560b447d
commit
62fc805108
59 changed files with 70 additions and 82 deletions
|
|
@ -2138,7 +2138,7 @@ icmp_type_code_match(u_int8_t test_type, u_int8_t min_code, u_int8_t max_code,
|
|||
}
|
||||
|
||||
static bool
|
||||
icmp_match(const struct sk_buff *skb, const struct xt_action_param *par)
|
||||
icmp_match(const struct sk_buff *skb, struct xt_action_param *par)
|
||||
{
|
||||
const struct icmphdr *ic;
|
||||
struct icmphdr _icmph;
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@ static inline bool match_type(struct net *net, const struct net_device *dev,
|
|||
}
|
||||
|
||||
static bool
|
||||
addrtype_mt_v0(const struct sk_buff *skb, const struct xt_action_param *par)
|
||||
addrtype_mt_v0(const struct sk_buff *skb, struct xt_action_param *par)
|
||||
{
|
||||
struct net *net = dev_net(par->in ? par->in : par->out);
|
||||
const struct ipt_addrtype_info *info = par->matchinfo;
|
||||
|
|
@ -48,7 +48,7 @@ addrtype_mt_v0(const struct sk_buff *skb, const struct xt_action_param *par)
|
|||
}
|
||||
|
||||
static bool
|
||||
addrtype_mt_v1(const struct sk_buff *skb, const struct xt_action_param *par)
|
||||
addrtype_mt_v1(const struct sk_buff *skb, struct xt_action_param *par)
|
||||
{
|
||||
struct net *net = dev_net(par->in ? par->in : par->out);
|
||||
const struct ipt_addrtype_info_v1 *info = par->matchinfo;
|
||||
|
|
|
|||
|
|
@ -30,7 +30,7 @@ spi_match(u_int32_t min, u_int32_t max, u_int32_t spi, bool invert)
|
|||
return r;
|
||||
}
|
||||
|
||||
static bool ah_mt(const struct sk_buff *skb, const struct xt_action_param *par)
|
||||
static bool ah_mt(const struct sk_buff *skb, struct xt_action_param *par)
|
||||
{
|
||||
struct ip_auth_hdr _ahdr;
|
||||
const struct ip_auth_hdr *ah;
|
||||
|
|
|
|||
|
|
@ -67,8 +67,7 @@ static inline bool match_tcp(const struct sk_buff *skb,
|
|||
return true;
|
||||
}
|
||||
|
||||
static bool ecn_mt(const struct sk_buff *skb,
|
||||
const struct xt_action_param *par)
|
||||
static bool ecn_mt(const struct sk_buff *skb, struct xt_action_param *par)
|
||||
{
|
||||
const struct ipt_ecn_info *info = par->matchinfo;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue