Fix the following coccicheck warning:
tools/testing/selftests/bpf/progs/tailcall_bpf2bpf6.c:28:14-17: Unneeded variable: "ret".
Return "1".
Signed-off-by: Mingtong Bao <baomingtong001@xxxxxxxxxx>
---
tools/testing/selftests/bpf/progs/tailcall_bpf2bpf6.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/tools/testing/selftests/bpf/progs/tailcall_bpf2bpf6.c b/tools/testing/selftests/bpf/progs/tailcall_bpf2bpf6.c
index 4a9f63bea66c..7f0146682577 100644
--- a/tools/testing/selftests/bpf/progs/tailcall_bpf2bpf6.c
+++ b/tools/testing/selftests/bpf/progs/tailcall_bpf2bpf6.c
@@ -25,10 +25,9 @@ static __noinline
int subprog_tail(struct __sk_buff *skb)
{
/* Don't propagate the constant to the caller */
- volatile int ret = 1;
bpf_tail_call_static(skb, &jmp_table, 0);
- return ret;
+ return 1;
}
SEC("tc")