Messages in this thread | | | Date | Sun, 8 Jul 2018 13:30:02 -0700 | From | Okash Khawaja <> | Subject | [PATCH bpf-next v3 0/3] bpf: btf: print bpftool map data with btf |
| |
Hi,
This v3 contains incorporates feedback from v2, including a fix for big endian when extracting bitfields. Below is a summary of all changes.
patch 1: - use kernel integer types instead of stdint
patch 2: - change stdint types to kernel equivalents - remove variable ret from btf_dumper_modifier() - remove unnecessary parentheses in btf_dumper_enum() - remove unnecessary parentheses in btf_dumper_array() - change integer types from explicitly sized to int in btf_dumper_int_bits - fix btf_dumper_int_bits() so it works for little and big endian - remove double space in btf_dumper_int() - print non-printable characters as string - remove ret variable from btf_dumper_int() - don't initialise variable with function which needs error check in btf_dumper_struct() - use a temp variable to avoid multi-line statement in btf_dumper_struct() - call jsonw_end_object before returning in error case in btf_dumper_struct() - print something in case of BTF_KIND_FWD in btf_dumper_do_type() - return directly from cases in switch-case and save 9 LOC in btf_dumper_do_type() - remove check for null argument in btf_dumper_type() - remove header file btf_dumper.h and move declarations to main.h
patch 3: - change stdint types to kernel equivalents - keep header includes in alphabetical order - use goto in do_dump_btf() to ensure jsonw_end_object() in cases of error - don't initialise variable with functions that can fail in get_btf() - remove json-breaking printf in get_btf() - refactor so that there isn't too much code in if (!err) case in do_lookup()
Thanks, Okash
| |