[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <091287c6-5121-58e5-b1b2-76277d2f1b1a@iogearbox.net>
Date: Fri, 17 Feb 2023 21:49:00 +0100
From: Daniel Borkmann <daniel@...earbox.net>
To: Björn Töpel <bjorn@...nel.org>,
Pu Lehui <pulehui@...weicloud.com>, bpf@...r.kernel.org,
linux-riscv@...ts.infradead.org, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, Palmer Dabbelt <palmer@...osinc.com>
Cc: Alexei Starovoitov <ast@...nel.org>,
Andrii Nakryiko <andrii@...nel.org>,
Martin KaFai Lau <martin.lau@...ux.dev>,
Song Liu <song@...nel.org>, Yonghong Song <yhs@...com>,
John Fastabend <john.fastabend@...il.com>,
KP Singh <kpsingh@...nel.org>,
Stanislav Fomichev <sdf@...gle.com>,
Hao Luo <haoluo@...gle.com>, Jiri Olsa <jolsa@...nel.org>,
Palmer Dabbelt <palmer@...belt.com>,
Conor Dooley <conor.dooley@...rochip.com>,
Guo Ren <guoren@...nel.org>,
Luke Nelson <luke.r.nels@...il.com>,
Xi Wang <xi.wang@...il.com>, Pu Lehui <pulehui@...wei.com>
Subject: Re: [PATCH bpf-next v1 0/4] Support bpf trampoline for RV64
On 2/16/23 10:56 AM, Björn Töpel wrote:
> Pu Lehui <pulehui@...weicloud.com> writes:
>
>> BPF trampoline is the critical infrastructure of the bpf
>> subsystem, acting as a mediator between kernel functions
>> and BPF programs. Numerous important features, such as
>> using ebpf program for zero overhead kernel introspection,
>> rely on this key component. We can't wait to support bpf
>> trampoline on RV64. Since RV64 does not support ftrace
>> direct call yet, the current RV64 bpf trampoline is only
>> used in bpf context.
>>
>> As most of riscv cpu support unaligned memory accesses,
>> we temporarily use patch [1] to facilitate testing. The
>> test results are as follow, and test_verifier with no
>> new failure ceses.
>>
>> - fexit_bpf2bpf:OK
>> - dummy_st_ops:OK
>> - xdp_bpf2bpf:OK
>>
>> [1] https://lore.kernel.org/linux-riscv/20210916130855.4054926-2-chenhuang5@huawei.com/
>>
>> v1:
>> - Remove the logic of bpf_arch_text_poke supported for
>> kernel functions. (Kuohai and Björn)
>> - Extend patch_text for multiple instructions. (Björn)
>> - Fix OOB issue when image too big. (Björn)
>
> This series is ready to go in as is.
Ok.
> @Palmer I'd like to take this series via the bpf-next tree (as usual),
> but note that there are some non-BPF changes as well, related to text
> poking.
>
> @Lehui I'd like to see two follow-up patches:
>
> 1. Enable kfunc for RV64, by adding:
> | bool bpf_jit_supports_kfunc_call(void)
> | {
> | return true;
> | }
>
> 2. Remove the checkpatch warning on patch 4:
> | WARNING: kfree(NULL) is safe and this check is probably not required
> | #313: FILE: arch/riscv/net/bpf_jit_comp64.c:984:
> | + if (branches_off)
> | + kfree(branches_off);
>
>
> For the series:
>
> Tested-by: Björn Töpel <bjorn@...osinc.com>
> Acked-by: Björn Töpel <bjorn@...osinc.com>
Thanks, I fixed up issue 2 and cleaned up the commit msgs while applying.
For issue 1, pls send a follow-up.
Powered by blists - more mailing lists