Re: [PATCH v2 01/21] exit_net cleanup: geneve sock_list check
From: kbuild test robot <hidden>
Date: 2017-11-07 02:38:30
Hi Vasily, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on net/master] [also build test WARNING on v4.14-rc8 next-20171106] [cannot apply to net-next/master] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-ci/linux/commits/Vasily-Averin/exit_net-checks-for-objects-initialized-in-net_init-hook/20171107-094512 config: i386-randconfig-x001-201745 (attached as .config) compiler: gcc-6 (Debian 6.2.0-3) 6.2.0 20160901 reproduce: # save the attached .config to linux build tree make ARCH=i386 All warnings (new ones prefixed by >>): In file included from arch/x86/include/asm/bug.h:82:0, from include/linux/bug.h:5, from include/linux/thread_info.h:12, from arch/x86/include/asm/preempt.h:7, from include/linux/preempt.h:81, from include/linux/spinlock.h:51, from include/linux/seqlock.h:36, from include/linux/time.h:6, from include/linux/stat.h:19, from include/linux/module.h:10, from drivers/net/geneve.c:14: drivers/net/geneve.c: In function 'geneve_exit_net':
quoted
drivers/net/geneve.c:1671:7: warning: too many arguments for format [-Wformat-extra-args]
"&s: sock_list is not empty\n", __func__);
^
include/asm-generic/bug.h:94:43: note: in definition of macro '__WARN_printf'
#define __WARN_printf(arg...) do { printk(arg); __WARN(); } while (0)
^~~quoted
drivers/net/geneve.c:1670:2: note: in expansion of macro 'WARN'
WARN(!list_empty(&gn->sock_list),
^~~~
vim +1671 drivers/net/geneve.c
1643
1644 static void __net_exit geneve_exit_net(struct net *net)
1645 {
1646 struct geneve_net *gn = net_generic(net, geneve_net_id);
1647 struct geneve_dev *geneve, *next;
1648 struct net_device *dev, *aux;
1649 LIST_HEAD(list);
1650
1651 rtnl_lock();
1652
1653 /* gather any geneve devices that were moved into this ns */
1654 for_each_netdev_safe(net, dev, aux)
1655 if (dev->rtnl_link_ops == &geneve_link_ops)
1656 unregister_netdevice_queue(dev, &list);
1657
1658 /* now gather any other geneve devices that were created in this ns */
1659 list_for_each_entry_safe(geneve, next, &gn->geneve_list, next) {
1660 /* If geneve->dev is in the same netns, it was already added
1661 * to the list by the previous loop.
1662 */
1663 if (!net_eq(dev_net(geneve->dev), net))
1664 unregister_netdevice_queue(geneve->dev, &list);
1665 }
1666
1667 /* unregister the devices gathered above */
1668 unregister_netdevice_many(&list);
1669 rtnl_unlock();1670 WARN(!list_empty(&gn->sock_list), 1671 "&s: sock_list is not empty\n", __func__);
1672 } 1673 --- 0-DAY kernel test infrastructure Open Source Technology Center https://lists.01.org/pipermail/kbuild-all Intel Corporation
Attachments
- .config.gz [application/gzip] 33858 bytes