BPF List
 help / color / mirror / Atom feed
From: Hengqi Chen <hengqi.chen@gmail.com>
To: bpf@vger.kernel.org, loongarch@lists.linux.dev
Cc: hengqi.chen@gmail.com
Subject: [PATCH 2/2] LoongArch: BPF: Support mixing bpf2bpf and tailcalls
Date: Sun, 12 Feb 2023 11:52:36 +0800	[thread overview]
Message-ID: <20230212035236.1436532-3-hengqi.chen@gmail.com> (raw)
In-Reply-To: <20230212035236.1436532-1-hengqi.chen@gmail.com>

The current implementation already allow such mixing.
Let's enable it in JIT.

Signed-off-by: Hengqi Chen <hengqi.chen@gmail.com>
---
 arch/loongarch/net/bpf_jit.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/arch/loongarch/net/bpf_jit.c b/arch/loongarch/net/bpf_jit.c
index 2d952110be72..01892dfa637e 100644
--- a/arch/loongarch/net/bpf_jit.c
+++ b/arch/loongarch/net/bpf_jit.c
@@ -1269,3 +1269,9 @@ struct bpf_prog *bpf_int_jit_compile(struct bpf_prog *prog)
 
 	return prog;
 }
+
+/* Indicate the JIT backend supports mixing bpf2bpf and tailcalls. */
+bool bpf_jit_supports_subprog_tailcalls(void)
+{
+	return true;
+}
-- 
2.31.1


      parent reply	other threads:[~2023-02-12  3:53 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-12  3:52 [PATCH 0/2] Allow mixing bpf2bpf calls with tailcalls on LoongArch Hengqi Chen
2023-02-12  3:52 ` [PATCH 1/2] LoongArch: BPF: Treat function address as 64-bit value Hengqi Chen
2023-02-13  3:01   ` Tiezhu Yang
2023-02-13  3:18     ` Tiezhu Yang
2023-02-14 15:36     ` Hengqi Chen
2023-02-12  3:52 ` Hengqi Chen [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230212035236.1436532-3-hengqi.chen@gmail.com \
    --to=hengqi.chen@gmail.com \
    --cc=bpf@vger.kernel.org \
    --cc=loongarch@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox