All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrii Nakryiko <andrii.nakryiko@gmail.com>
To: Alex Ghiti <alex@ghiti.fr>
Cc: bpf <bpf@vger.kernel.org>, Jisheng Zhang <jszhang@kernel.org>
Subject: Re: BPF calls to modules?
Date: Fri, 18 Jun 2021 10:32:16 -0700	[thread overview]
Message-ID: <CAEf4Bzbt1wvJ=J7Fb6TWUS52j11k3w_b+KpZPCMdsBRUTSsyOw@mail.gmail.com> (raw)
In-Reply-To: <aaedcede-5db5-1015-7dbf-7c45421c1e98@ghiti.fr>

On Fri, Jun 18, 2021 at 2:13 AM Alex Ghiti <alex@ghiti.fr> wrote:
>
> Hi guys,
>
> First, pardon my ignorance regarding BPF, the following might be silly.
>
> We were wondering here
> https://patchwork.kernel.org/project/linux-riscv/patch/20210615004928.2d27d2ac@xhacker/
> if BPF programs that now have the capability to call kernel functions
> (https://lwn.net/Articles/856005/) can also call modules function or
> vice-versa?

Not yet, but it was an explicit design consideration and there was
public interest just recently. So I'd say this is going to happen
sooner rather than later.

>
> The underlying important fact is that in riscv, we are limited to 2GB
> offset to call functions and that restricts where we can place modules
> and BPF regions wrt kernel (see Documentation/riscv/vm-layout.rst for
> the current possibly wrong layout).
>
> So should we make sure that modules and BPF lie in the same 2GB region?

Based on the above and what you are explaining about 2GB limits, I'd
say yes?.. Or alternatively those 2GB restrictions might perhaps be
lifted somehow?

>
> Thanks,
>
> Alex

  parent reply	other threads:[~2021-06-18 17:32 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-18  7:32 BPF calls to modules? Alex Ghiti
2021-06-18 14:41 ` Alexei Starovoitov
2021-06-18 17:32 ` Andrii Nakryiko [this message]
2021-06-21  6:34   ` Alex Ghiti
2021-06-22  0:28     ` Alexei Starovoitov
2021-06-22  7:31       ` Alex Ghiti
2021-06-22 15:02         ` Jisheng Zhang
2021-06-22 17:25         ` Alexei Starovoitov
2021-06-22 18:57           ` Alex Ghiti

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='CAEf4Bzbt1wvJ=J7Fb6TWUS52j11k3w_b+KpZPCMdsBRUTSsyOw@mail.gmail.com' \
    --to=andrii.nakryiko@gmail.com \
    --cc=alex@ghiti.fr \
    --cc=bpf@vger.kernel.org \
    --cc=jszhang@kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.