Message ID | 20170718225927.15944-2-sthemmin@microsoft.com |
---|---|
State | Accepted, archived |
Delegated to: | David Miller |
Headers | show |
Hi Stephen,
[auto build test WARNING on net-next/master]
url: https://github.com/0day-ci/linux/commits/Stephen-Hemminger/net-make-dev_close-void/20170720-090123
config: x86_64-randconfig-a0-07211734 (attached as .config)
compiler: gcc-4.4 (Debian 4.4.7-8) 4.4.7
reproduce:
# save the attached .config to linux build tree
make ARCH=x86_64
All warnings (new ones prefixed by >>):
net/bluetooth/6lowpan.c: In function 'ifdown':
>> net/bluetooth/6lowpan.c:621: warning: unused variable 'err'
vim +/err +621 net/bluetooth/6lowpan.c
18722c24 Jukka Rissanen 2013-12-11 618
7f118253 Jukka Rissanen 2014-06-18 619 static void ifdown(struct net_device *netdev)
7f118253 Jukka Rissanen 2014-06-18 620 {
7f118253 Jukka Rissanen 2014-06-18 @621 int err;
7f118253 Jukka Rissanen 2014-06-18 622
7f118253 Jukka Rissanen 2014-06-18 623 rtnl_lock();
ca74f73e Stephen Hemminger 2017-07-18 624 dev_close(netdev);
7f118253 Jukka Rissanen 2014-06-18 625 rtnl_unlock();
7f118253 Jukka Rissanen 2014-06-18 626 }
7f118253 Jukka Rissanen 2014-06-18 627
:::::: The code at line 621 was first introduced by commit
:::::: 7f118253820fc3ad38659485adb3ebdfe64820e1 Bluetooth: 6LoWPAN: Remove network devices when unloading
:::::: TO: Jukka Rissanen <jukka.rissanen@linux.intel.com>
:::::: CC: Marcel Holtmann <marcel@holtmann.org>
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
Hi Stephen, > [auto build test WARNING on net-next/master] > > url: https://github.com/0day-ci/linux/commits/Stephen-Hemminger/net-make-dev_close-void/20170720-090123 > config: x86_64-randconfig-a0-07211734 (attached as .config) > compiler: gcc-4.4 (Debian 4.4.7-8) 4.4.7 > reproduce: > # save the attached .config to linux build tree > make ARCH=x86_64 > > All warnings (new ones prefixed by >>): > > net/bluetooth/6lowpan.c: In function 'ifdown': >>> net/bluetooth/6lowpan.c:621: warning: unused variable 'err' > > vim +/err +621 net/bluetooth/6lowpan.c > > 18722c24 Jukka Rissanen 2013-12-11 618 > 7f118253 Jukka Rissanen 2014-06-18 619 static void ifdown(struct net_device *netdev) > 7f118253 Jukka Rissanen 2014-06-18 620 { > 7f118253 Jukka Rissanen 2014-06-18 @621 int err; > 7f118253 Jukka Rissanen 2014-06-18 622 > 7f118253 Jukka Rissanen 2014-06-18 623 rtnl_lock(); > ca74f73e Stephen Hemminger 2017-07-18 624 dev_close(netdev); > 7f118253 Jukka Rissanen 2014-06-18 625 rtnl_unlock(); > 7f118253 Jukka Rissanen 2014-06-18 626 } > 7f118253 Jukka Rissanen 2014-06-18 627 > > :::::: The code at line 621 was first introduced by commit > :::::: 7f118253820fc3ad38659485adb3ebdfe64820e1 Bluetooth: 6LoWPAN: Remove network devices when unloading > > :::::: TO: Jukka Rissanen <jukka.rissanen@linux.intel.com> > :::::: CC: Marcel Holtmann <marcel@holtmann.org> are you going to send a fix for this? Regards Marcel
diff --git a/net/bluetooth/6lowpan.c b/net/bluetooth/6lowpan.c index ab3b654b05cc..e542b8959d88 100644 --- a/net/bluetooth/6lowpan.c +++ b/net/bluetooth/6lowpan.c @@ -621,9 +621,7 @@ static void ifdown(struct net_device *netdev) int err; rtnl_lock(); - err = dev_close(netdev); - if (err < 0) - BT_INFO("iface %s cannot be closed (%d)", netdev->name, err); + dev_close(netdev); rtnl_unlock(); }
The function dev_close in current kernel will never return an error. Later changes will make it void. Signed-off-by: Stephen Hemminger <sthemmin@microsoft.com> --- net/bluetooth/6lowpan.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)