lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 25 Oct 2017 14:41:13 +0800
From:   kbuild test robot <lkp@...el.com>
To:     "Steven J. Hill" <steven.hill@...ium.com>
Cc:     kbuild-all@...org, netdev@...r.kernel.org,
        "Steven J. Hill" <Steven.Hill@...ium.com>,
        David Daney <david.daney@...ium.com>
Subject: Re: [PATCH] ethernet: cavium: octeon: Switch to using netdev_info().

Hi Steven,

[auto build test WARNING on net-next/master]
[also build test WARNING on v4.14-rc6]
[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/Steven-J-Hill/ethernet-cavium-octeon-Switch-to-using-netdev_info/20171024-071910
config: mips-cavium_octeon_defconfig (attached as .config)
compiler: mips64-linux-gnuabi64-gcc (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        make.cross ARCH=mips 

All warnings (new ones prefixed by >>):

   drivers/net/ethernet/cavium/octeon/octeon_mgmt.c: In function 'octeon_mgmt_adjust_link':
>> drivers/net/ethernet/cavium/octeon/octeon_mgmt.c:929:5: warning: suggest explicit braces to avoid ambiguous 'else' [-Wparentheses]
     if (link_changed != 0)
        ^

vim +/else +929 drivers/net/ethernet/cavium/octeon/octeon_mgmt.c

   896	
   897	static void octeon_mgmt_adjust_link(struct net_device *netdev)
   898	{
   899		struct octeon_mgmt *p = netdev_priv(netdev);
   900		struct phy_device *phydev = netdev->phydev;
   901		unsigned long flags;
   902		int link_changed = 0;
   903	
   904		if (!phydev)
   905			return;
   906	
   907		spin_lock_irqsave(&p->lock, flags);
   908	
   909	
   910		if (!phydev->link && p->last_link)
   911			link_changed = -1;
   912	
   913		if (phydev->link &&
   914		    (p->last_duplex != phydev->duplex ||
   915		     p->last_link != phydev->link ||
   916		     p->last_speed != phydev->speed)) {
   917			octeon_mgmt_disable_link(p);
   918			link_changed = 1;
   919			octeon_mgmt_update_link(p);
   920			octeon_mgmt_enable_link(p);
   921		}
   922	
   923		p->last_link = phydev->link;
   924		p->last_speed = phydev->speed;
   925		p->last_duplex = phydev->duplex;
   926	
   927		spin_unlock_irqrestore(&p->lock, flags);
   928	
 > 929		if (link_changed != 0)
   930			if (link_changed > 0)
   931				netdev_info(netdev, "Link is up - %d/%s\n",
   932					phydev->speed, phydev->duplex == DUPLEX_FULL ? "Full" : "Half");
   933			else
   934				netdev_info(netdev, "Link is down\n");
   935	}
   936	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Download attachment ".config.gz" of type "application/gzip" (16794 bytes)

Powered by blists - more mailing lists