diff options
author | Zhu Jun <zhujun2@cmss.chinamobile.com> | 2024-10-09 01:21:38 -0700 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2024-10-09 18:22:04 -0700 |
commit | 965fdf95a3272e78c2175231351b3a7d42490a14 (patch) | |
tree | 8d756d3c0a811906c4737ec4dd205a49f7d28704 /samples | |
parent | 5bf1557e3d6a69113649d831276ea2f97585fc33 (diff) |
samples/bpf: Remove unused variables
These variables are never referenced in the code, just remove them.
Signed-off-by: Zhu Jun <zhujun2@cmss.chinamobile.com>
Link: https://lore.kernel.org/r/20241009082138.7971-1-zhujun2@cmss.chinamobile.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'samples')
-rw-r--r-- | samples/bpf/tc_l2_redirect_kern.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/samples/bpf/tc_l2_redirect_kern.c b/samples/bpf/tc_l2_redirect_kern.c index fd2fa0004330..0b48f7ddf521 100644 --- a/samples/bpf/tc_l2_redirect_kern.c +++ b/samples/bpf/tc_l2_redirect_kern.c @@ -58,7 +58,6 @@ static __always_inline bool is_vip_addr(__be16 eth_proto, __be32 daddr) SEC("l2_to_iptun_ingress_forward") int _l2_to_iptun_ingress_forward(struct __sk_buff *skb) { - struct bpf_tunnel_key tkey = {}; void *data = (void *)(long)skb->data; struct eth_hdr *eth = data; void *data_end = (void *)(long)skb->data_end; @@ -205,7 +204,6 @@ int _l2_to_ip6tun_ingress_redirect(struct __sk_buff *skb) SEC("drop_non_tun_vip") int _drop_non_tun_vip(struct __sk_buff *skb) { - struct bpf_tunnel_key tkey = {}; void *data = (void *)(long)skb->data; struct eth_hdr *eth = data; void *data_end = (void *)(long)skb->data_end; |