|
@@ -87,7 +87,7 @@ tee_tg4(struct sk_buff *skb, const struct xt_action_param *par)
|
|
|
const struct xt_tee_tginfo *info = par->targinfo;
|
|
|
struct iphdr *iph;
|
|
|
|
|
|
- if (percpu_read(tee_active))
|
|
|
+ if (__this_cpu_read(tee_active))
|
|
|
return XT_CONTINUE;
|
|
|
/*
|
|
|
* Copy the skb, and route the copy. Will later return %XT_CONTINUE for
|
|
@@ -124,9 +124,9 @@ tee_tg4(struct sk_buff *skb, const struct xt_action_param *par)
|
|
|
ip_send_check(iph);
|
|
|
|
|
|
if (tee_tg_route4(skb, info)) {
|
|
|
- percpu_write(tee_active, true);
|
|
|
+ __this_cpu_write(tee_active, true);
|
|
|
ip_local_out(skb);
|
|
|
- percpu_write(tee_active, false);
|
|
|
+ __this_cpu_write(tee_active, false);
|
|
|
} else {
|
|
|
kfree_skb(skb);
|
|
|
}
|
|
@@ -168,7 +168,7 @@ tee_tg6(struct sk_buff *skb, const struct xt_action_param *par)
|
|
|
{
|
|
|
const struct xt_tee_tginfo *info = par->targinfo;
|
|
|
|
|
|
- if (percpu_read(tee_active))
|
|
|
+ if (__this_cpu_read(tee_active))
|
|
|
return XT_CONTINUE;
|
|
|
skb = pskb_copy(skb, GFP_ATOMIC);
|
|
|
if (skb == NULL)
|
|
@@ -186,9 +186,9 @@ tee_tg6(struct sk_buff *skb, const struct xt_action_param *par)
|
|
|
--iph->hop_limit;
|
|
|
}
|
|
|
if (tee_tg_route6(skb, info)) {
|
|
|
- percpu_write(tee_active, true);
|
|
|
+ __this_cpu_write(tee_active, true);
|
|
|
ip6_local_out(skb);
|
|
|
- percpu_write(tee_active, false);
|
|
|
+ __this_cpu_write(tee_active, false);
|
|
|
} else {
|
|
|
kfree_skb(skb);
|
|
|
}
|