Commit 0feefd97 authored by Jason Baron's avatar Jason Baron Committed by Greg Kroah-Hartman

dynamic_debug: fix undefined reference to `__netdev_printk'

Dynamic debug recently added support for netdev_printk.  It uses
__netdev_printk() to support this functionality.  However, when CONFIG_NET
is not set, we get the following error:

lib/built-in.o: In function `__dynamic_netdev_dbg':
(.text+0x9fda): undefined reference to `__netdev_printk'

Fix this by making the call to netdev_printk() contingent upon CONFIG_NET.
 We could have fixed this by defining netdev_printk() to a 'no-op' in the
!CONFIG_NET case.  However, this is not consistent with how the networking
layer uses netdev_printk.  For example, CONFIG_NET is not set,
netdev_printk() does not have a 'no-op' definition defined.
Signed-off-by: default avatarJason Baron <jbaron@redhat.com>
Acked-by: default avatarRandy Dunlap <rdunlap@xenotime.net>
Acked-by: default avatarArnd Bergmann <arnd@arndb.de>
Signed-off-by: default avatarAndrew Morton <akpm@google.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 431625da
......@@ -503,6 +503,8 @@ int __dynamic_dev_dbg(struct _ddebug *descriptor,
}
EXPORT_SYMBOL(__dynamic_dev_dbg);
#ifdef CONFIG_NET
int __dynamic_netdev_dbg(struct _ddebug *descriptor,
const struct net_device *dev, const char *fmt, ...)
{
......@@ -524,6 +526,8 @@ int __dynamic_netdev_dbg(struct _ddebug *descriptor,
}
EXPORT_SYMBOL(__dynamic_netdev_dbg);
#endif
static __initdata char ddebug_setup_string[1024];
static __init int ddebug_setup_query(char *str)
{
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment