e43207fa2e
This patch modified test_btf pretty print test to cover
the bitfield with struct member equal to or greater 256.
Without the previous kernel patch fix, the modified test will fail:
$ test_btf -p
......
BTF pretty print array(#1)......unexpected pprint output
expected: 0: {0,0,0,0x3,0x0,0x3,{0|[0,0,0,0,0,0,0,0]},ENUM_ZERO,4,0x1}
read: 0: {0,0,0,0x3,0x0,0x3,{0|[0,0,0,0,0,0,0,0]},ENUM_ZERO,4,0x0}
BTF pretty print array(#2)......unexpected pprint output
expected: 0: {0,0,0,0x3,0x0,0x3,{0|[0,0,0,0,0,0,0,0]},ENUM_ZERO,4,0x1}
read: 0: {0,0,0,0x3,0x0,0x3,{0|[0,0,0,0,0,0,0,0]},ENUM_ZERO,4,0x0}
PASS:6 SKIP:0 FAIL:2
With the kernel fix, the modified test will succeed:
$ test_btf -p
......
BTF pretty print array(#1)......OK
BTF pretty print array(#2)......OK
PASS:8 SKIP:0 FAIL:0
Fixes:
|
||
---|---|---|
.. | ||
gnu | ||
include/uapi/linux | ||
.gitignore | ||
bpf_endian.h | ||
bpf_flow.c | ||
bpf_helpers.h | ||
bpf_rand.h | ||
bpf_rlimit.h | ||
bpf_util.h | ||
cgroup_helpers.c | ||
cgroup_helpers.h | ||
config | ||
connect4_prog.c | ||
connect6_prog.c | ||
dev_cgroup.c | ||
flow_dissector_load.c | ||
get_cgroup_id_kern.c | ||
get_cgroup_id_user.c | ||
Makefile | ||
netcnt_common.h | ||
netcnt_prog.c | ||
sample_map_ret0.c | ||
sample_ret0.c | ||
sendmsg4_prog.c | ||
sendmsg6_prog.c | ||
socket_cookie_prog.c | ||
sockmap_parse_prog.c | ||
sockmap_tcp_msg_prog.c | ||
sockmap_verdict_prog.c | ||
tcp_client.py | ||
tcp_server.py | ||
test_adjust_tail.c | ||
test_align.c | ||
test_btf_haskv.c | ||
test_btf_nokv.c | ||
test_btf.c | ||
test_cgroup_storage.c | ||
test_dev_cgroup.c | ||
test_flow_dissector.c | ||
test_flow_dissector.sh | ||
test_get_stack_rawtp.c | ||
test_iptunnel_common.h | ||
test_kmod.sh | ||
test_l4lb_noinline.c | ||
test_l4lb.c | ||
test_libbpf_open.c | ||
test_libbpf.sh | ||
test_lirc_mode2_kern.c | ||
test_lirc_mode2_user.c | ||
test_lirc_mode2.sh | ||
test_lpm_map.c | ||
test_lru_map.c | ||
test_lwt_seg6local.c | ||
test_lwt_seg6local.sh | ||
test_map_in_map.c | ||
test_maps.c | ||
test_netcnt.c | ||
test_obj_id.c | ||
test_offload.py | ||
test_pkt_access.c | ||
test_pkt_md_access.c | ||
test_progs.c | ||
test_queue_map.c | ||
test_queue_stack_map.h | ||
test_section_names.c | ||
test_select_reuseport_common.h | ||
test_select_reuseport_kern.c | ||
test_select_reuseport.c | ||
test_sk_lookup_kern.c | ||
test_skb_cgroup_id_kern.c | ||
test_skb_cgroup_id_user.c | ||
test_skb_cgroup_id.sh | ||
test_sock_addr.c | ||
test_sock_addr.sh | ||
test_sock.c | ||
test_socket_cookie.c | ||
test_sockhash_kern.c | ||
test_sockmap_kern.c | ||
test_sockmap_kern.h | ||
test_sockmap.c | ||
test_stack_map.c | ||
test_stacktrace_build_id.c | ||
test_stacktrace_map.c | ||
test_tag.c | ||
test_tcp_estats.c | ||
test_tcpbpf_kern.c | ||
test_tcpbpf_user.c | ||
test_tcpbpf.h | ||
test_tcpnotify_kern.c | ||
test_tcpnotify_user.c | ||
test_tcpnotify.h | ||
test_tracepoint.c | ||
test_tunnel_kern.c | ||
test_tunnel.sh | ||
test_verifier_log.c | ||
test_verifier.c | ||
test_xdp_meta.c | ||
test_xdp_meta.sh | ||
test_xdp_noinline.c | ||
test_xdp_redirect.c | ||
test_xdp_redirect.sh | ||
test_xdp_vlan.c | ||
test_xdp_vlan.sh | ||
test_xdp.c | ||
trace_helpers.c | ||
trace_helpers.h | ||
urandom_read.c | ||
with_addr.sh | ||
with_tunnels.sh | ||
xdp_dummy.c |