diff options
author | Andrii Nakryiko <[email protected]> | 2019-10-03 21:02:11 -0700 |
---|---|---|
committer | Alexei Starovoitov <[email protected]> | 2019-10-05 18:03:12 -0700 |
commit | a53ba15d81995868651dd28a85d8045aef3d4e20 (patch) | |
tree | 7039bc769c81e37de5dec53fea25e8286e4dfdb9 /tools/perf/scripts/python/check-perf-trace.py | |
parent | 4bbbf164f1a5e970543dcdb7a396fc1cf477725b (diff) |
libbpf: Fix BTF-defined map's __type macro handling of arrays
Due to a quirky C syntax of declaring pointers to array or function
prototype, existing __type() macro doesn't work with map key/value types
that are array or function prototype. One has to create a typedef first
and use it to specify key/value type for a BPF map. By using typeof(),
pointer to type is now handled uniformly for all kinds of types. Convert
one of self-tests as a demonstration.
Signed-off-by: Andrii Nakryiko <[email protected]>
Signed-off-by: Alexei Starovoitov <[email protected]>
Link: https://lore.kernel.org/bpf/[email protected]
Diffstat (limited to 'tools/perf/scripts/python/check-perf-trace.py')
0 files changed, 0 insertions, 0 deletions