Commit Graph

5 Commits

Author SHA1 Message Date
b93d52fe3d Change the license of strace to LGPL-2.1-or-later
strace is now provided under the terms of the GNU Lesser General
Public License version 2.1 or later, see COPYING for more details.

strace test suite is now provided under the terms of the GNU General
Public License version 2 or later, see tests/COPYING for more details.
2018-12-10 00:00:00 +00:00
Eugene Syromyatnikov
9228e78d4f bpf: add support for checking structures outside union bpf_attr
struct bpf_prog_info and bpf_map_info need essentially the same handling
as union bpf_attr.

* gen_bpf_attr_check.sh: Derive type_name from $struct if it doesn't
start with "BPF_", derive TYPE_NAME from type_name, use them in code
generation.
* m4/gen_bpf_attr_m4.sh: Rewrite parsing/generation code into awk,
add support for structures outside union bpf_attr.

Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
2018-05-28 17:34:50 +00:00
Eugene Syromyatnikov
a3509bac24 bpf: add support for array fields
* gen_bpf_attr_check.sh: Ignore field array size definition.
* m4/gen_bpf_attr_m4.sh (filter_entries): Likewise.

Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
2018-04-08 22:01:12 +00:00
995ae92b50 bpf_attr: add more size checks
* bpf_attr.h: Add expected sizes of structures.
* gen_bpf_attr_check.sh: Check them.
2018-04-04 14:50:07 +00:00
1802fe1ea6 Check that structures defined by bpf_attr.h match system union bpf_attr
* gen_bpf_attr_check.sh: New file.
* Makefile.am (EXTRA_DIST): Add it.
(strace_SOURCES_check): New variable.
(strace_SOURCES): Add $(strace_SOURCES_check).
(BUILT_SOURCES, CLEANFILES): Add bpf_attr_check.c.
(bpf_attr_check.c): New rule.
(sys_func_h_sources): New variable.
(sys_func.h): Use it instead of strace_SOURCES_c.
* .gitignore: Add /bpf_attr_check.c.
2018-04-04 12:24:19 +00:00