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]
Message-ID: <202006032021.lLeRTjhD%lkp@intel.com>
Date:   Wed, 3 Jun 2020 21:03:44 +0800
From:   kernel test robot <lkp@...el.com>
To:     Vinay Kumar Yadav <vinay.yadav@...lsio.com>,
        netdev@...r.kernel.org, davem@...emloft.net, kuba@...nel.org
Cc:     kbuild-all@...ts.01.org, edumazet@...gle.com, borisp@...lanox.com,
        secdev@...lsio.com, Vinay Kumar Yadav <vinay.yadav@...lsio.com>
Subject: Re: [PATCH net-next] crypto/chtls: Fix compile error when
 CONFIG_IPV6 is disabled

Hi Vinay,

I love your patch! Yet something to improve:

[auto build test ERROR on net-next/master]

url:    https://github.com/0day-ci/linux/commits/Vinay-Kumar-Yadav/crypto-chtls-Fix-compile-error-when-CONFIG_IPV6-is-disabled/20200603-184315
base:   https://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git 065fcfd49763ec71ae345bb5c5a74f961031e70e
config: arc-allyesconfig (attached as .config)
compiler: arc-elf-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
        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
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arc 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>

All errors (new ones prefixed by >>, old ones prefixed by <<):

drivers/crypto/chelsio/chtls/chtls_cm.c: In function 'chtls_find_netdev':
>> drivers/crypto/chelsio/chtls/chtls_cm.c:105:3: error: a label can only be part of a statement and a declaration is not a statement
105 |   struct net_device *temp;
|   ^~~~~~
>> drivers/crypto/chelsio/chtls/chtls_cm.c:106:3: error: expected expression before 'int'
106 |   int addr_type;
|   ^~~
>> drivers/crypto/chelsio/chtls/chtls_cm.c:108:3: error: 'addr_type' undeclared (first use in this function); did you mean 'iter_type'?
108 |   addr_type = ipv6_addr_type(&sk->sk_v6_rcv_saddr);
|   ^~~~~~~~~
|   iter_type
drivers/crypto/chelsio/chtls/chtls_cm.c:108:3: note: each undeclared identifier is reported only once for each function it appears in
In file included from drivers/crypto/chelsio/chtls/chtls.h:31,
from drivers/crypto/chelsio/chtls/chtls_cm.c:32:
At top level:
drivers/crypto/chelsio/chcr_algo.h:392:17: warning: 'sgl_lengths' defined but not used [-Wunused-const-variable=]
392 | static const u8 sgl_lengths[20] = {
|                 ^~~~~~~~~~~

vim +105 drivers/crypto/chelsio/chtls/chtls_cm.c

    91	
    92	static struct net_device *chtls_find_netdev(struct chtls_dev *cdev,
    93						    struct sock *sk)
    94	{
    95		struct net_device *ndev = cdev->ports[0];
    96	
    97		switch (sk->sk_family) {
    98		case PF_INET:
    99			if (likely(!inet_sk(sk)->inet_rcv_saddr))
   100				return ndev;
   101			ndev = ip_dev_find(&init_net, inet_sk(sk)->inet_rcv_saddr);
   102			break;
   103	#if IS_ENABLED(CONFIG_IPV6)
   104		case PF_INET6:
 > 105			struct net_device *temp;
 > 106			int addr_type;
   107	
 > 108			addr_type = ipv6_addr_type(&sk->sk_v6_rcv_saddr);
   109			if (likely(addr_type == IPV6_ADDR_ANY))
   110				return ndev;
   111	
   112			for_each_netdev_rcu(&init_net, temp) {
   113				if (ipv6_chk_addr(&init_net, (struct in6_addr *)
   114						  &sk->sk_v6_rcv_saddr, temp, 1)) {
   115					ndev = temp;
   116					break;
   117				}
   118			}
   119		break;
   120	#endif
   121		default:
   122			return NULL;
   123		}
   124	
   125		if (!ndev)
   126			return NULL;
   127	
   128		if (is_vlan_dev(ndev))
   129			return vlan_dev_real_dev(ndev);
   130		return ndev;
   131	}
   132	

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ