On Thu, Apr 15, 2021 at 10:38 PM Daniel Borkmann wrote:
>
> On 4/15/21 11:32 AM, Jianlin Lv wrote:
> > For debugging JITs, dumping the JITed image to kernel log is discouraged,
> > "bpftool prog dump jited" is much better way to examine JITed dumps.
> > This pa
Remove information about bpf_jit_enable=2 mode and added description for
how to use the bpf_jit_disasm tool after get rid of =2 mode.
Signed-off-by: Jianlin Lv
---
Documentation/admin-guide/sysctl/net.rst | 1 -
Documentation/networking/filter.rst | 25 ++--
2 files
to explain how to use bpf_jit_disasm tool after this change.
Signed-off-by: Jianlin Lv
---
arch/arm/net/bpf_jit_32.c | 4
arch/arm64/net/bpf_jit_comp.c | 4
arch/mips/net/bpf_jit.c | 4
arch/mips/net/ebpf_jit.c | 4
arch/powerpc/net/bpf_
On Wed, Mar 31, 2021 at 5:28 PM Will Deacon wrote:
>
> On Wed, Mar 31, 2021 at 05:22:18PM +0800, Jianlin Lv wrote:
> > On Tue, Mar 30, 2021 at 5:31 PM Will Deacon wrote:
> > >
> > > On Tue, Mar 30, 2021 at 03:42:35PM +0800, Jianlin Lv wrote:
> > > > A64_
On Tue, Mar 30, 2021 at 5:31 PM Will Deacon wrote:
>
> On Tue, Mar 30, 2021 at 03:42:35PM +0800, Jianlin Lv wrote:
> > A64_MOV is currently mapped to Add Instruction. Architecturally MOV
> > (register) is an alias of ORR (shifted register) and MOV (to or from SP)
> > is an
...
14: mov x25, sp
f9 03 00 91
...
24: mov x19, x0
f3 03 00 aa
...
8c: mov x0, x7
e0 03 07 aa
Signed-off-by: Jianlin Lv
---
arch/arm64/net/bpf_jit.h | 7 +--
arch/arm64/net/bpf_jit_comp.c | 4 ++--
2 files changed, 7 insert
On Sat, Mar 27, 2021 at 11:19 PM Alexei Starovoitov
wrote:
>
> On Sat, Mar 27, 2021 at 1:19 AM Jianlin Lv wrote:
> >
> > > On Fri, Mar 26, 2021 at 5:40 AM Jianlin Lv wrote:
> > > >
> > > > When CONFIG_BPF_JIT_ALWAYS_ON is enabled, the value of
> -Original Message-
> From: Alexei Starovoitov
> Sent: Friday, March 26, 2021 10:25 PM
> To: Jianlin Lv
> Cc: bpf ; David S. Miller ;
> Jakub Kicinski ; Alexei Starovoitov ;
> Daniel Borkmann ; Andrii Nakryiko
> ; Martin KaFai Lau ; Song Liu
> ; Yonghong S
When CONFIG_BPF_JIT_ALWAYS_ON is enabled, the value of bpf_jit_enable in
/proc/sys is limited to SYSCTL_ONE. This is not convenient for debugging.
This patch modifies the value of extra2 (max) to 2 that support developers
to emit traces on kernel log.
Signed-off-by: Jianlin Lv
---
net/core
On Thu, Mar 18, 2021 at 11:58 PM Daniel Borkmann wrote:
>
> On 3/18/21 7:36 AM, Jianlin Lv wrote:
> > Added BPF_LD_ST_SIZE_MASK macro as mask of size modifier that help to
> > reduce the evaluation of expressions in if statements,
> > and remove BPF_SIZE_MASK in netronom
Added BPF_LD_ST_SIZE_MASK macro as mask of size modifier that help to
reduce the evaluation of expressions in if statements,
and remove BPF_SIZE_MASK in netronome driver.
Signed-off-by: Jianlin Lv
---
v2: Move the bpf_LD_ST_SIZE_MASK macro definition to include/linux/bpf.h
---
drivers/net
Two insn_buf[16] variables are declared in the function, which act on
function scope and block scope respectively.
The statement in the inner blocks is redundant, so remove it.
Signed-off-by: Jianlin Lv
---
kernel/bpf/verifier.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/kernel/bpf
Added BPF_SIZE_MASK macro as mask of size modifier that help to reduce
the evaluation of expressions in if statements,
and remove BPF_SIZE_MASK in netronome driver.
Signed-off-by: Jianlin Lv
---
drivers/net/ethernet/netronome/nfp/bpf/main.h | 2 --
include/uapi/linux/bpf.h
When the incorrect interface name is stored in the slaves/active_slave
option of the bonding sysfs, the kernel does not record the log that
interface does not exist.
This patch adds a log for -ENODEV error, which will facilitate users to
figure out such issue.
Signed-off-by: Jianlin Lv
---
v2
After upgrading the kernel, the slave interface name is changed,
Systemd cannot use the original configuration to create bond interface,
thereby losing the connection with the host.
Adding log for ENODEV will make it easier to find out such problem lies.
Signed-off-by: Jianlin Lv
---
drivers
Wformat-overflow warnings. Add helper function to
convert NULL to "unknown".
Signed-off-by: Jianlin Lv
---
v2: Add ternary operator to avoid similar errors in other arch.
v3: Declared reg_name in inner block.
v4: Add helper function: perf_reg_name_str, update changelog.
v5: Correct functio
Wformat-overflow warnings. Add helper function to
convert NULL to "unknown".
Signed-off-by: Jianlin Lv
---
v2: Add ternary operator to avoid similar errors in other arch.
v3: Declared reg_name in inner block.
v4: Add helper function: perf_reg_name_str, update changelog.
---
tools/perf/builti
The kernel compiled with clang does not have this issue.
FIX:
This GCC issue only cause the registration failure of the kretprobe event
which doesn't need debuginfo. So, stop using debuginfo for retprobe.
map will be used to query the probe function address.
Signed-off-by: Jianlin Lv
Wformat-overflow warnings. Add ternary operator,
The statement evaluates to "Unknown" if reg_name==NULL is met.
Signed-off-by: Jianlin Lv
---
v2: Add ternary operator to avoid similar errors in other arch.
v3: Declared reg_name in inner block.
---
tools/perf/builti
> -Original Message-
> From: Arnaldo Carvalho de Melo
> Sent: Saturday, February 13, 2021 5:34 AM
> To: Jianlin Lv
> Cc: pet...@infradead.org; mi...@redhat.com; Mark Rutland
> ; alexander.shish...@linux.intel.com;
> jo...@redhat.com; namhy...@kernel.org; nat...@ke
> -Original Message-
> From: John Garry
> Sent: Wednesday, February 10, 2021 5:38 PM
> To: Jianlin Lv ; w...@kernel.org;
> mathieu.poir...@linaro.org; leo@linaro.org; pet...@infradead.org;
> mi...@redhat.com; a...@kernel.org; Mark Rutland
> ; alexander.shish...@
y option.
The kernel compiled with clang does not have this issue.
FIX:
This GCC issue only cause the registration failure of the kretprobe event
which doesn't need debuginfo. So, stop using debuginfo for retprobe.
map will be used to query the probe function address.
Signed-off-by: Jianlin Lv
Wformat-overflow warnings. Add ternary operator,
The statement evaluates to "Unknown" if reg_name==NULL is met.
Signed-off-by: Jianlin Lv
---
v2: Add ternary operator to avoid similar errors in other arch.
---
tools/perf/builtin-script.c| 4 +++-
tools/perf/util
> -Original Message-
> From: Leo Yan
> Sent: Tuesday, February 9, 2021 8:17 PM
> To: Jianlin Lv
> Cc: john.ga...@huawei.com; w...@kernel.org; mathieu.poir...@linaro.org;
> pet...@infradead.org; mi...@redhat.com; a...@kernel.org; Mark Rutland
> ; alexander.shish...@
Wformat-overflow warnings by replacing the return
value NULL of perf_reg_name with "unknown".
Signed-off-by: Jianlin Lv
---
tools/perf/arch/arm64/include/perf_regs.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/tools/perf/arch/arm64/include/perf_regs.h
b/tools
> -Original Message-
> From: Masami Hiramatsu
> Sent: Monday, February 8, 2021 8:33 PM
> To: Jianlin Lv
> Cc: pet...@infradead.org; mi...@redhat.com; a...@kernel.org; Mark
> Rutland ; alexander.shish...@linux.intel.com;
> jo...@redhat.com; namhy...@kernel.org; nat
otential defect is that if -gno-record-gcc-switches option is enabled,
the command-line options will not be recorded in debuginfo. This workaround
solution will fail.
Assume that this situation may not happen for kernel compilation.
Signed-off-by: Jianlin Lv
---
tools/perf/util/probe-event.c |
if dwarf_offdie() return NULL, the continue statement forces the next
iteration of the loop without update variable off. It will cause an
endless loop in the process of traversing the compilation unit.
So added exception protection for loop CUs.
Signed-off-by: Jianlin Lv
---
v2: removed the
if dwarf_offdie() return NULL, the continue statement forces the next
iteration of the loop without update variable off. It will cause an
endless loop in the process of traversing the compilation unit.
So added exception protection for loop CUs.
Signed-off-by: Jianlin Lv
---
tools/perf/util
> -Original Message-
> From: Masami Hiramatsu
> Sent: Friday, January 29, 2021 9:45 PM
> To: Jianlin Lv
> Cc: Steven Rostedt ; Oleg Nesterov
> ; Ingo Molnar ; linux-
> ker...@vger.kernel.org
> Subject: Re: [PATCH] tracing/kprobe: Fix to support kretprobe even
^
v2 changes:
- Added !strchr(symbol, ':') to check whether symbol is really bad
or from a module.
Signed-off-by: Jianlin Lv
---
v2: added !strchr(symbol, ':') to check really bad symbol or from module.
v4: added changelog and code comments.
---
kernel/trace/trace_kprobe.c
> -Original Message-
> From: Masami Hiramatsu
> Sent: Wednesday, January 27, 2021 9:28 PM
> To: Jianlin Lv
> Cc: Oleg Nesterov ; Steven Rostedt
> ; mi...@redhat.com; linux-kernel@vger.kernel.org
> Subject: Re: [PATCH v3] tracing: precise log info for kretprobe ad
> -Original Message-
> From: Masami Hiramatsu
> Sent: Wednesday, January 27, 2021 10:02 AM
> To: Oleg Nesterov
> Cc: Steven Rostedt ; Jianlin Lv ;
> mi...@redhat.com; linux-kernel@vger.kernel.org
> Subject: Re: [PATCH v3] tracing: precise log info for kretprobe ad
> -Original Message-
> From: Masami Hiramatsu
> Sent: Tuesday, January 26, 2021 12:16 PM
> To: Steven Rostedt
> Cc: Oleg Nesterov ; Jianlin Lv ;
> mi...@redhat.com; mhira...@kernel.org; linux-kernel@vger.kernel.org
> Subject: Re: [PATCH v3] tracing: precise log in
ch is as follows:
$ echo 'r:myprobe ERROR_SYMBOL_XXX ret=%x0' >> kprobe_events
bash: echo: write error: Invalid argument
$ cat error_log
[415.89]trace_kprobe: error: Retprobe address must be an function entry
Command: r:myprobe ERROR_SYMBOL_XXX ret=%x0
Message-
> From: Masami Hiramatsu
> Sent: Sunday, January 24, 2021 4:53 PM
> To: Jianlin Lv
> Cc: Steven Rostedt ; mi...@redhat.com; linux-
> ker...@vger.kernel.org; o...@redhat.com
> Subject: Re: [PATCH v2] tracing: precise log info for kretprobe addr err
>
> Hi Jianli
> -Original Message-
> From: Masami Hiramatsu
> Sent: Thursday, January 21, 2021 10:29 AM
> To: Steven Rostedt
> Cc: Jianlin Lv ; mi...@redhat.com; linux-
> ker...@vger.kernel.org; Masami Hiramatsu ;
> o...@redhat.com
> Subject: Re: [PATCH v2] tracing: precis
ch is as follows:
$ echo 'r:myprobe ERROR_SYMBOL_XXX ret=%x0' >> kprobe_events
bash: echo: write error: Invalid argument
$ cat error_log
[415.89]trace_kprobe: error: Retprobe address must be an function entry
Command: r:myprobe ERROR_SYMBOL_XXX ret=%x0
ch is as follows:
$ echo 'r:myprobe ERROR_SYMBOL_XXX ret=%x0' >> kprobe_events
bash: echo: write error: Invalid argument
$ cat error_log
[415.89]trace_kprobe: error: Retprobe address must be an function entry
Command: r:myprobe ERROR_SYMBOL_XXX ret=%x0
S_FRAME_SIZE is the size of the pt_regs structure, no longer the size of
the kernel stack frame, the name is misleading. In keeping with arm32,
rename S_FRAME_SIZE to PT_REGS_SIZE.
Signed-off-by: Jianlin Lv
---
arch/arm64/kernel/asm-offsets.c | 2 +-
arch/arm64/kernel/entry
It is not necessary to use src/dst as an intermediate variable for
assignment operation; Delete src/dst intermediate variables to avoid
unnecessary variable declarations.
Signed-off-by: Jianlin Lv
---
drivers/net/vxlan.c | 16
1 file changed, 4 insertions(+), 12 deletions
: Jianlin Lv
---
drivers/net/vxlan.c | 40 +++-
1 file changed, 15 insertions(+), 25 deletions(-)
diff --git a/drivers/net/vxlan.c b/drivers/net/vxlan.c
index b9fefe27e3e8..679260e1d9f1 100644
--- a/drivers/net/vxlan.c
+++ b/drivers/net/vxlan.c
@@ -2597,7 +2597,6
bpf_devel_QA.rst:152 The subject prefix information is not accurate, it
should be 'PATCH bpf-next v2'
Also update LLVM version info and add information about
‘-DLLVM_TARGETS_TO_BUILD’ to prompt the developer to build the desired
target.
Signed-off-by: Jianlin Lv
---
Documen
XDP program already attached.
ip will throw an error in case a XDP program is already attached to the
networking interface, to prevent it from being overridden by accident.
In order to replace the currently running XDP program with a new one,
the -force option must be used.
Signed-off-by: Jianlin Lv
4 pages of anonymous mapping,then do all
the mmap() with MAP_FIXED.
Another issue is that when unmap the second page fails, the length
parameter to delete tmp1 mappings should be 4*page_size.
Signed-off-by: Jianlin Lv
---
v2:
- Update commit messages
- Create 4 pages of anonymous mapping that
unmap the second page fails, the length
parameter to delete tmp1 mappings should be 3*page_size.
Signed-off-by: Jianlin Lv
---
tools/testing/selftests/bpf/prog_tests/mmap.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/tools/testing/selftests/bpf/prog_tests/mmap.c
b
e.
Signed-off-by: Jianlin Lv
---
v2:
- replease CHECK_FAIL by CHECK
- fix test_tcpnotify_user failed issue
---
.../selftests/bpf/prog_tests/send_signal.c | 18 --
.../bpf/prog_tests/stacktrace_build_id_nmi.c | 4 +++-
.../selftests/bpf/test_tcpnotify_user.c| 13 ++
e.
Signed-off-by: Jianlin Lv
---
.../selftests/bpf/prog_tests/send_signal.c| 37 ++-
.../bpf/prog_tests/stacktrace_build_id_nmi.c | 3 +-
.../selftests/bpf/test_tcpnotify_user.c | 15 ++--
3 files changed, 41 insertions(+), 14 deletions(-)
diff --git a/tools/testing
> -Original Message-
> From: bpf-ow...@vger.kernel.org On Behalf
> Of Daniel Borkmann
> Sent: Wednesday, July 22, 2020 4:18 AM
> To: Jianlin Lv ; b...@vger.kernel.org
> Cc: da...@davemloft.net; k...@kernel.org; a...@kernel.org; y...@fb.com;
> Song Zhu ; linux-k
initial
and non-initial network namespace.
Signed-off-by: Jianlin Lv
---
net/core/net_namespace.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/core/net_namespace.c b/net/core/net_namespace.c
index dcd61aca343e..5937bd0df56d 100644
--- a/net/core/net_namespace.c
+++ b
50 matches
Mail list logo