Message ID | 20230227040221.15442-1-rdunlap@infradead.org (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | [bpf-next] riscv, bpf: fix patch_text implicit declaration | expand |
Context | Check | Description |
---|---|---|
conchuod/cover_letter | success | Single patches do not need cover letters |
conchuod/tree_selection | success | Guessed tree name to be for-next |
conchuod/fixes_present | success | Fixes tag not required for -next series |
conchuod/maintainers_pattern | success | MAINTAINERS pattern errors before the patch: 13 and now 13 |
conchuod/verify_signedoff | success | Signed-off-by tag matches author and committer |
conchuod/kdoc | success | Errors and warnings before: 0 this patch: 0 |
conchuod/build_rv64_clang_allmodconfig | success | Errors and warnings before: 3 this patch: 3 |
conchuod/module_param | success | Was 0 now: 0 |
conchuod/build_rv64_gcc_allmodconfig | success | Errors and warnings before: 19 this patch: 19 |
conchuod/alphanumeric_selects | success | Out of order selects before the patch: 729 and now 729 |
conchuod/build_rv32_defconfig | success | Build OK |
conchuod/dtb_warn_rv64 | success | Errors and warnings before: 2 this patch: 2 |
conchuod/header_inline | success | No static functions without inline keyword in header files |
conchuod/checkpatch | success | total: 0 errors, 0 warnings, 0 checks, 7 lines checked |
conchuod/source_inline | success | Was 0 now: 0 |
conchuod/build_rv64_nommu_k210_defconfig | success | Build OK |
conchuod/verify_fixes | success | Fixes tag looks correct |
conchuod/build_rv64_nommu_virt_defconfig | success | Build OK |
On 2023/2/27 12:02, Randy Dunlap wrote: > bpf_jit_comp64.c uses patch_text(), so add it to a local header file > to prevent the build error: > > ../arch/riscv/net/bpf_jit_comp64.c: In function 'bpf_arch_text_poke': > ../arch/riscv/net/bpf_jit_comp64.c:691:23: error: implicit declaration of function 'patch_text'; did you mean 'path_get'? [-Werror=implicit-function-declaration] > 691 | ret = patch_text(ip, new_insns, ninsns); > | ^~~~~~~~~~ > > Fixes: 596f2e6f9cf4 ("riscv, bpf: Add bpf_arch_text_poke support for RV64") > Signed-off-by: Randy Dunlap <rdunlap@infradead.org> > Reported-by: kernel test robot <lkp@intel.com> > Link: https://lore.kernel.org/r/202302271000.Aj4nMXbZ-lkp@intel.com > Cc: Pu Lehui <pulehui@huawei.com> > Cc: Luke Nelson <luke.r.nels@gmail.com> > Cc: Xi Wang <xi.wang@gmail.com> > Cc: bpf@vger.kernel.org > Cc: Alexei Starovoitov <ast@kernel.org> > Cc: Daniel Borkmann <daniel@iogearbox.net> > Cc: John Fastabend <john.fastabend@gmail.com> > Cc: Andrii Nakryiko <andrii@kernel.org> > Cc: Paul Walmsley <paul.walmsley@sifive.com> > Cc: Palmer Dabbelt <palmer@dabbelt.com> > Cc: Albert Ou <aou@eecs.berkeley.edu> > Cc: "Björn Töpel" <bjorn@kernel.org> > Cc: linux-riscv@lists.infradead.org > --- > What is the proper path to have this merged soon to stop build > errors? > > arch/riscv/net/bpf_jit.h | 1 + > 1 file changed, 1 insertion(+) > > diff -- a/arch/riscv/net/bpf_jit.h b/arch/riscv/net/bpf_jit.h > --- a/arch/riscv/net/bpf_jit.h > +++ b/arch/riscv/net/bpf_jit.h > @@ -12,6 +12,7 @@ > #include <linux/bpf.h> > #include <linux/filter.h> > #include <asm/cacheflush.h> > +#include <asm/patch.h> > Thanks Randy. Since patch_text is only used in riscv64 at present, I think it is appropriate to add it to arch/riscv/net/bpf_jit_comp64.c > static inline bool rvc_enabled(void) > {
diff -- a/arch/riscv/net/bpf_jit.h b/arch/riscv/net/bpf_jit.h --- a/arch/riscv/net/bpf_jit.h +++ b/arch/riscv/net/bpf_jit.h @@ -12,6 +12,7 @@ #include <linux/bpf.h> #include <linux/filter.h> #include <asm/cacheflush.h> +#include <asm/patch.h> static inline bool rvc_enabled(void) {
bpf_jit_comp64.c uses patch_text(), so add it to a local header file to prevent the build error: ../arch/riscv/net/bpf_jit_comp64.c: In function 'bpf_arch_text_poke': ../arch/riscv/net/bpf_jit_comp64.c:691:23: error: implicit declaration of function 'patch_text'; did you mean 'path_get'? [-Werror=implicit-function-declaration] 691 | ret = patch_text(ip, new_insns, ninsns); | ^~~~~~~~~~ Fixes: 596f2e6f9cf4 ("riscv, bpf: Add bpf_arch_text_poke support for RV64") Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Reported-by: kernel test robot <lkp@intel.com> Link: https://lore.kernel.org/r/202302271000.Aj4nMXbZ-lkp@intel.com Cc: Pu Lehui <pulehui@huawei.com> Cc: Luke Nelson <luke.r.nels@gmail.com> Cc: Xi Wang <xi.wang@gmail.com> Cc: bpf@vger.kernel.org Cc: Alexei Starovoitov <ast@kernel.org> Cc: Daniel Borkmann <daniel@iogearbox.net> Cc: John Fastabend <john.fastabend@gmail.com> Cc: Andrii Nakryiko <andrii@kernel.org> Cc: Paul Walmsley <paul.walmsley@sifive.com> Cc: Palmer Dabbelt <palmer@dabbelt.com> Cc: Albert Ou <aou@eecs.berkeley.edu> Cc: "Björn Töpel" <bjorn@kernel.org> Cc: linux-riscv@lists.infradead.org --- What is the proper path to have this merged soon to stop build errors? arch/riscv/net/bpf_jit.h | 1 + 1 file changed, 1 insertion(+)