summaryrefslogtreecommitdiff
path: root/arch/mips/net
diff options
context:
space:
mode:
authorTiezhu Yang <yangtiezhu@loongson.cn>2021-10-11 09:19:10 +0800
committerDaniel Borkmann <daniel@iogearbox.net>2021-10-11 15:29:38 +0200
commit431bfb9ee3e2ac0294d5ef58cee87683807299c0 (patch)
tree9640c7ef5e9b8a8d16e488ad2df2f40358cc3f50 /arch/mips/net
parent307d149d9435e5514268d6020d430245813d82cc (diff)
bpf, mips: Fix comment on tail call count limiting
In emit_tail_call() of bpf_jit_comp32.c, "blez t2" (t2 <= 0) is not consistent with the comment "t2 < 0", update the comment to keep consistency. Signed-off-by: Tiezhu Yang <yangtiezhu@loongson.cn> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Acked-by: Johan Almbladh <johan.almbladh@anyfinetworks.com> Link: https://lore.kernel.org/bpf/1633915150-13220-3-git-send-email-yangtiezhu@loongson.cn
Diffstat (limited to 'arch/mips/net')
-rw-r--r--arch/mips/net/bpf_jit_comp32.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/mips/net/bpf_jit_comp32.c b/arch/mips/net/bpf_jit_comp32.c
index 9d7041a2e5d7..bd996ede12f8 100644
--- a/arch/mips/net/bpf_jit_comp32.c
+++ b/arch/mips/net/bpf_jit_comp32.c
@@ -1315,7 +1315,7 @@ static int emit_tail_call(struct jit_context *ctx)
/* if (TCC-- <= 0) goto out */
emit(ctx, lw, t2, ctx->stack_size, MIPS_R_SP); /* t2 = *(SP + size) */
emit_load_delay(ctx); /* Load delay slot */
- emit(ctx, blez, t2, get_offset(ctx, 1)); /* PC += off(1) if t2 < 0 */
+ emit(ctx, blez, t2, get_offset(ctx, 1)); /* PC += off(1) if t2 <= 0 */
emit(ctx, addiu, t2, t2, -1); /* t2-- (delay slot) */
emit(ctx, sw, t2, ctx->stack_size, MIPS_R_SP); /* *(SP + size) = t2 */