Revision 6a6b0b9914e73a8a54253dd5f6f5e5dd5e4a756c authored by Mat Martineau on 21 December 2017, 18:29:09 UTC, committed by David S. Miller on 26 December 2017, 22:25:22 UTC
Using a preprocessor directive to check for CONFIG_IPV6 in the middle of a DECLARE_EVENT_CLASS macro's arg list causes sparse to report a series of errors: ./include/trace/events/tcp.h:68:1: error: directive in argument list ./include/trace/events/tcp.h:75:1: error: directive in argument list ./include/trace/events/tcp.h:144:1: error: directive in argument list ./include/trace/events/tcp.h:151:1: error: directive in argument list ./include/trace/events/tcp.h:216:1: error: directive in argument list ./include/trace/events/tcp.h:223:1: error: directive in argument list ./include/trace/events/tcp.h:274:1: error: directive in argument list ./include/trace/events/tcp.h:281:1: error: directive in argument list Once sparse finds an error, it stops printing warnings for the file it is checking. This masks any sparse warnings that would normally be reported for the core TCP code. Instead, handle the preprocessor conditionals in a couple of auxiliary macros. This also has the benefit of reducing duplicate code. Cc: David Ahern <dsahern@gmail.com> Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 3a33a19
File | Mode | Size |
---|---|---|
apparmor | ||
integrity | ||
keys | ||
loadpin | ||
selinux | ||
smack | ||
tomoyo | ||
yama | ||
Kconfig | -rw-r--r-- | 8.9 KB |
Makefile | -rw-r--r-- | 1.0 KB |
commoncap.c | -rw-r--r-- | 38.9 KB |
device_cgroup.c | -rw-r--r-- | 20.4 KB |
inode.c | -rw-r--r-- | 10.5 KB |
lsm_audit.c | -rw-r--r-- | 10.7 KB |
min_addr.c | -rw-r--r-- | 1.3 KB |
security.c | -rw-r--r-- | 43.5 KB |
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...