[LTP] [PATCH 2/2] Fix BPF test program loading issues

Martin Doucha mdoucha@suse.cz
Wed Feb 5 16:25:48 CET 2020


On 2/5/20 3:31 PM, Cyril Hrubis wrote:
>> diff --git a/testcases/kernel/syscalls/bpf/bpf_common.h b/testcases/kernel/syscalls/bpf/bpf_common.h
> 
> Why can't we keep the code in the header? I do not condsider this to be
> improving anything at all.

Because executable code doesn't belong in header files unless necessary.
Header files are as much API documentation for developers as they are
code for compilers. And header files full of executable code make
terrible API documentation.

I'll implement the rest of your suggestions and resubmit.

-- 
Martin Doucha   mdoucha@suse.cz
QA Engineer for Software Maintenance
SUSE LINUX, s.r.o.
CORSO IIa
Krizikova 148/34
186 00 Prague 8
Czech Republic


More information about the ltp mailing list