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>] [day] [month] [year] [list]
Message-ID: <202301171150.m8u7HlhK-lkp@intel.com>
Date:   Tue, 17 Jan 2023 12:05:37 +0800
From:   kernel test robot <lkp@...el.com>
To:     Robert Elliott <elliott@....com>
Cc:     llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev,
        linux-kernel@...r.kernel.org,
        Herbert Xu <herbert@...dor.apana.org.au>
Subject: arch/arm/crypto/sha512-neon-glue.c:37:3: warning: cast from 'void
 (*)(u64 *, const u8 *, int)' (aka 'void (*)(unsigned long long *, const
 unsigned char *, int)') to 'sha512_block_fn *' (aka 'void (*)(struct
 sha512_state *, const unsigned char *, int)') co...

Hi Robert,

FYI, the error/warning still remains.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   6e50979a9c87371fdb85d16058f9b5cb40751501
commit: 4a329fecc9aaebb27a53fa7abfa53bbc2ee42f3f crypto: Kconfig - submenus for arm and arm64
date:   5 months ago
config: arm-randconfig-r022-20230116
compiler: clang version 16.0.0 (https://github.com/llvm/llvm-project 4196ca3278f78c6e19246e54ab0ecb364e37d66a)
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
        # install arm cross compiling tool for clang build
        # apt-get install binutils-arm-linux-gnueabi
        # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=4a329fecc9aaebb27a53fa7abfa53bbc2ee42f3f
        git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
        git fetch --no-tags linus master
        git checkout 4a329fecc9aaebb27a53fa7abfa53bbc2ee42f3f
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm olddefconfig
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash arch/arm/crypto/

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

All warnings (new ones prefixed by >>):

>> arch/arm/crypto/sha512-neon-glue.c:37:3: warning: cast from 'void (*)(u64 *, const u8 *, int)' (aka 'void (*)(unsigned long long *, const unsigned char *, int)') to 'sha512_block_fn *' (aka 'void (*)(struct sha512_state *, const unsigned char *, int)') converts to incompatible function type [-Wcast-function-type-strict]
                   (sha512_block_fn *)sha512_block_data_order_neon);
                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   arch/arm/crypto/sha512-neon-glue.c:52:4: warning: cast from 'void (*)(u64 *, const u8 *, int)' (aka 'void (*)(unsigned long long *, const unsigned char *, int)') to 'sha512_block_fn *' (aka 'void (*)(struct sha512_state *, const unsigned char *, int)') converts to incompatible function type [-Wcast-function-type-strict]
                           (sha512_block_fn *)sha512_block_data_order_neon);
                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   arch/arm/crypto/sha512-neon-glue.c:54:3: warning: cast from 'void (*)(u64 *, const u8 *, int)' (aka 'void (*)(unsigned long long *, const unsigned char *, int)') to 'sha512_block_fn *' (aka 'void (*)(struct sha512_state *, const unsigned char *, int)') converts to incompatible function type [-Wcast-function-type-strict]
                   (sha512_block_fn *)sha512_block_data_order_neon);
                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   3 warnings generated.


vim +37 arch/arm/crypto/sha512-neon-glue.c

c80ae7ca372606 Ard Biesheuvel 2015-05-08  22  
c80ae7ca372606 Ard Biesheuvel 2015-05-08  23  asmlinkage void sha512_block_data_order_neon(u64 *state, u8 const *src,
c80ae7ca372606 Ard Biesheuvel 2015-05-08  24  					     int blocks);
c80ae7ca372606 Ard Biesheuvel 2015-05-08  25  
c80ae7ca372606 Ard Biesheuvel 2015-05-08  26  static int sha512_neon_update(struct shash_desc *desc, const u8 *data,
c80ae7ca372606 Ard Biesheuvel 2015-05-08  27  			      unsigned int len)
c80ae7ca372606 Ard Biesheuvel 2015-05-08  28  {
c80ae7ca372606 Ard Biesheuvel 2015-05-08  29  	struct sha512_state *sctx = shash_desc_ctx(desc);
c80ae7ca372606 Ard Biesheuvel 2015-05-08  30  
99680c5e918294 Eric Biggers   2019-03-12  31  	if (!crypto_simd_usable() ||
c80ae7ca372606 Ard Biesheuvel 2015-05-08  32  	    (sctx->count[0] % SHA512_BLOCK_SIZE) + len < SHA512_BLOCK_SIZE)
c80ae7ca372606 Ard Biesheuvel 2015-05-08  33  		return sha512_arm_update(desc, data, len);
c80ae7ca372606 Ard Biesheuvel 2015-05-08  34  
c80ae7ca372606 Ard Biesheuvel 2015-05-08  35  	kernel_neon_begin();
c80ae7ca372606 Ard Biesheuvel 2015-05-08  36  	sha512_base_do_update(desc, data, len,
c80ae7ca372606 Ard Biesheuvel 2015-05-08 @37  		(sha512_block_fn *)sha512_block_data_order_neon);
c80ae7ca372606 Ard Biesheuvel 2015-05-08  38  	kernel_neon_end();
c80ae7ca372606 Ard Biesheuvel 2015-05-08  39  
c80ae7ca372606 Ard Biesheuvel 2015-05-08  40  	return 0;
c80ae7ca372606 Ard Biesheuvel 2015-05-08  41  }
c80ae7ca372606 Ard Biesheuvel 2015-05-08  42  

:::::: The code at line 37 was first introduced by commit
:::::: c80ae7ca372606a3971dcdfa3420275cf17ef6b6 crypto: arm/sha512 - accelerated SHA-512 using ARM generic ASM and NEON

:::::: TO: Ard Biesheuvel <ard.biesheuvel@...aro.org>
:::::: CC: Herbert Xu <herbert@...dor.apana.org.au>

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests

View attachment "config" of type "text/plain" (174603 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ