From: Gal Pressman Date: Sun, 7 Jan 2018 10:08:35 +0000 (+0200) Subject: net: Fix netdev_WARN_ONCE macro X-Git-Tag: v4.15.17~93 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=614361530f03681c16b97aed0b0821ca11a96263;p=thirdparty%2Fkernel%2Fstable.git net: Fix netdev_WARN_ONCE macro [ Upstream commit 72dd831e24cc9487a9cd534fdd675fe97e3c1839 ] netdev_WARN_ONCE is broken (whoops..), this fix will remove the unnecessary "condition" parameter, add the missing comma and change "arg" to "args". Fixes: 375ef2b1f0d0 ("net: Introduce netdev_*_once functions") Signed-off-by: Gal Pressman Reviewed-by: Saeed Mahameed Signed-off-by: David S. Miller Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index ef789e1d679ef..ddb1fc7bd938d 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h @@ -4402,8 +4402,8 @@ do { \ WARN(1, "netdevice: %s%s\n" format, netdev_name(dev), \ netdev_reg_state(dev), ##args) -#define netdev_WARN_ONCE(dev, condition, format, arg...) \ - WARN_ONCE(1, "netdevice: %s%s\n" format, netdev_name(dev) \ +#define netdev_WARN_ONCE(dev, format, args...) \ + WARN_ONCE(1, "netdevice: %s%s\n" format, netdev_name(dev), \ netdev_reg_state(dev), ##args) /* netif printk helpers, similar to netdev_printk */