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: <202305182336.0WSIv4B5-lkp@intel.com>
Date:   Fri, 19 May 2023 00:24:53 +0800
From:   kernel test robot <lkp@...el.com>
To:     David Gow <davidgow@...gle.com>,
        Matti Vaittinen <matti.vaittinen@...rohmeurope.com>,
        Matti Vaittinen <mazziesaccount@...il.com>,
        Daniel Latypov <dlatypov@...gle.com>,
        Maxime Ripard <maxime@...no.tech>,
        Benjamin Berg <benjamin@...solutions.net>,
        Brendan Higgins <brendan.higgins@...ux.dev>,
        Stephen Boyd <sboyd@...nel.org>,
        Shuah Khan <skhan@...uxfoundation.org>,
        Rae Moar <rmoar@...gle.com>
Cc:     llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev,
        David Gow <davidgow@...gle.com>,
        Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
        "Rafael J . Wysocki" <rafael@...nel.org>,
        Heikki Krogerus <heikki.krogerus@...ux.intel.com>,
        Jonathan Cameron <jic23@...nel.org>,
        Sadiya Kazi <sadiyakazi@...gle.com>,
        Jonathan Corbet <corbet@....net>, linux-doc@...r.kernel.org,
        kunit-dev@...glegroups.com, linux-kselftest@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2 3/4] kunit: kmalloc_array: Use kunit_add_action()

Hi David,

kernel test robot noticed the following build warnings:

[auto build test WARNING on lwn/docs-next]
[also build test WARNING on linus/master v6.4-rc2 next-20230518]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/David-Gow/kunit-executor_test-Use-kunit_add_action/20230518-171005
base:   git://git.lwn.net/linux.git docs-next
patch link:    https://lore.kernel.org/r/20230518083849.2631178-3-davidgow%40google.com
patch subject: [PATCH v2 3/4] kunit: kmalloc_array: Use kunit_add_action()
config: arm64-buildonly-randconfig-r003-20230517
compiler: clang version 17.0.0 (https://github.com/llvm/llvm-project b0fb98227c90adf2536c9ad644a74d5e92961111)
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 arm64 cross compiling tool for clang build
        # apt-get install binutils-aarch64-linux-gnu
        # https://github.com/intel-lab-lkp/linux/commit/f0c4ca4f24b370c1b4d9d35af1319ef1402e313c
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review David-Gow/kunit-executor_test-Use-kunit_add_action/20230518-171005
        git checkout f0c4ca4f24b370c1b4d9d35af1319ef1402e313c
        # 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=arm64 olddefconfig
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm64 SHELL=/bin/bash lib/kunit/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202305182336.0WSIv4B5-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> lib/kunit/test.c:724:38: warning: cast from 'void (*)(const void *)' to 'kunit_action_t *' (aka 'void (*)(void *)') converts to incompatible function type [-Wcast-function-type-strict]
           if (kunit_add_action_or_reset(test, (kunit_action_t *)kfree, data) != 0)
                                               ^~~~~~~~~~~~~~~~~~~~~~~
   lib/kunit/test.c:736:29: warning: cast from 'void (*)(const void *)' to 'kunit_action_t *' (aka 'void (*)(void *)') converts to incompatible function type [-Wcast-function-type-strict]
           kunit_release_action(test, (kunit_action_t *)kfree, (void *)ptr);
                                      ^~~~~~~~~~~~~~~~~~~~~~~
   2 warnings generated.


vim +724 lib/kunit/test.c

   714	
   715	void *kunit_kmalloc_array(struct kunit *test, size_t n, size_t size, gfp_t gfp)
   716	{
   717		void *data;
   718	
   719		data = kmalloc_array(n, size, gfp);
   720	
   721		if (!data)
   722			return NULL;
   723	
 > 724		if (kunit_add_action_or_reset(test, (kunit_action_t *)kfree, data) != 0)
   725			return NULL;
   726	
   727		return data;
   728	}
   729	EXPORT_SYMBOL_GPL(kunit_kmalloc_array);
   730	

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

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ