diff --git a/[refs] b/[refs] index a5f4948f4463..226068a9de27 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 6e2be3ea4fab4d1c02e369719311e8d7ae6cc7c1 +refs/heads/master: 0dec456d1fe73e0539625f0973ee8ef8fb805943 diff --git a/trunk/include/net/sock.h b/trunk/include/net/sock.h index 1806e5b61419..30758035d616 100644 --- a/trunk/include/net/sock.h +++ b/trunk/include/net/sock.h @@ -1354,12 +1354,12 @@ extern int sock_get_timestamp(struct sock *, struct timeval __user *); * Enable debug/info messages */ -#if 0 -#define NETDEBUG(fmt, args...) do { } while (0) -#define LIMIT_NETDEBUG(fmt, args...) do { } while(0) -#else +#ifdef CONFIG_NETDEBUG #define NETDEBUG(fmt, args...) printk(fmt,##args) #define LIMIT_NETDEBUG(fmt, args...) do { if (net_ratelimit()) printk(fmt,##args); } while(0) +#else +#define NETDEBUG(fmt, args...) do { } while (0) +#define LIMIT_NETDEBUG(fmt, args...) do { } while(0) #endif /* diff --git a/trunk/net/Kconfig b/trunk/net/Kconfig index bc603d9aea56..5126f58d9c44 100644 --- a/trunk/net/Kconfig +++ b/trunk/net/Kconfig @@ -27,6 +27,13 @@ if NET menu "Networking options" +config NETDEBUG + bool "Network packet debugging" + help + You can say Y here if you want to get additional messages useful in + debugging bad packets, but can overwhelm logs under denial of service + attacks. + source "net/packet/Kconfig" source "net/unix/Kconfig" source "net/xfrm/Kconfig"