]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commit
bpf: Only print ref_obj_id for refcounted reg
authorMartin KaFai Lau <kafai@fb.com>
Mon, 18 Mar 2019 17:37:13 +0000 (10:37 -0700)
committerAlexei Starovoitov <ast@kernel.org>
Thu, 21 Mar 2019 01:24:35 +0000 (18:24 -0700)
commitcba368c1f01c27ed62fca7a853531845d263bb01
treeb1e5d98d11f78bdb37b2746c2b74fae29d1c4f83
parentf01a7dbe98ae4265023fa5d3af0f076f0b18a647
bpf: Only print ref_obj_id for refcounted reg

Naresh reported that test_align fails because of the mismatch at the
verbose printout of the register states.  The reason is due to the newly
added ref_obj_id.

ref_obj_id is only useful for refcounted reg.  Thus, this patch fixes it
by only printing ref_obj_id for refcounted reg.  While at it, it also uses
comma instead of space to separate between "id" and "ref_obj_id".

Fixes: 1b986589680a ("bpf: Fix bpf_tcp_sock and bpf_sk_fullsock issue related to bpf_sk_release")
Reported-by: Naresh Kamboju <naresh.kamboju@linaro.org>
Signed-off-by: Martin KaFai Lau <kafai@fb.com>
Acked-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
kernel/bpf/verifier.c