Re: [PATCH v2 2/2] Bluetooth: SMP: Convert BT_ERR/BT_DBG to bt_dev_err/bt_dev_dbg

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Luiz,

I love your patch! Yet something to improve:

[auto build test ERROR on bluetooth-next/master]
[also build test ERROR on v5.12-rc2 next-20210310]
[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]

url:    https://github.com/0day-ci/linux/commits/Luiz-Augusto-von-Dentz/Bluetooth-SMP-Fail-if-remote-and-local-public-keys-are-identical/20210311-061654
base:   https://git.kernel.org/pub/scm/linux/kernel/git/bluetooth/bluetooth-next.git master
config: arc-randconfig-r001-20210309 (attached as .config)
compiler: arceb-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
        # https://github.com/0day-ci/linux/commit/1c91aff112229ea99f1b03e5f547ad6804d9cfb7
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Luiz-Augusto-von-Dentz/Bluetooth-SMP-Fail-if-remote-and-local-public-keys-are-identical/20210311-061654
        git checkout 1c91aff112229ea99f1b03e5f547ad6804d9cfb7
        # 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@xxxxxxxxx>

All errors (new ones prefixed by >>):

   In file included from net/bluetooth/smp.c:31:
   net/bluetooth/smp.c: In function 'run_selftests':
>> net/bluetooth/smp.c:3741:14: error: 'hdev' undeclared (first use in this function); did you mean 'cdev'?
    3741 |   bt_dev_err(hdev, "debug_key test failed");
         |              ^~~~
   include/net/bluetooth/bluetooth.h:175:45: note: in definition of macro 'BT_ERR'
     175 | #define BT_ERR(fmt, ...) bt_err(fmt "\n", ##__VA_ARGS__)
         |                                             ^~~~~~~~~~~
   net/bluetooth/smp.c:3741:3: note: in expansion of macro 'bt_dev_err'
    3741 |   bt_dev_err(hdev, "debug_key test failed");
         |   ^~~~~~~~~~
   net/bluetooth/smp.c:3741:14: note: each undeclared identifier is reported only once for each function it appears in
    3741 |   bt_dev_err(hdev, "debug_key test failed");
         |              ^~~~
   include/net/bluetooth/bluetooth.h:175:45: note: in definition of macro 'BT_ERR'
     175 | #define BT_ERR(fmt, ...) bt_err(fmt "\n", ##__VA_ARGS__)
         |                                             ^~~~~~~~~~~
   net/bluetooth/smp.c:3741:3: note: in expansion of macro 'bt_dev_err'
    3741 |   bt_dev_err(hdev, "debug_key test failed");
         |   ^~~~~~~~~~


vim +3741 net/bluetooth/smp.c

  3729	
  3730	static int __init run_selftests(struct crypto_shash *tfm_cmac,
  3731					struct crypto_kpp *tfm_ecdh)
  3732	{
  3733		ktime_t calltime, delta, rettime;
  3734		unsigned long long duration;
  3735		int err;
  3736	
  3737		calltime = ktime_get();
  3738	
  3739		err = test_debug_key(tfm_ecdh);
  3740		if (err) {
> 3741			bt_dev_err(hdev, "debug_key test failed");
  3742			goto done;
  3743		}
  3744	
  3745		err = test_ah();
  3746		if (err) {
  3747			bt_dev_err(hdev, "smp_ah test failed");
  3748			goto done;
  3749		}
  3750	
  3751		err = test_c1();
  3752		if (err) {
  3753			bt_dev_err(hdev, "smp_c1 test failed");
  3754			goto done;
  3755		}
  3756	
  3757		err = test_s1();
  3758		if (err) {
  3759			bt_dev_err(hdev, "smp_s1 test failed");
  3760			goto done;
  3761		}
  3762	
  3763		err = test_f4(tfm_cmac);
  3764		if (err) {
  3765			bt_dev_err(hdev, "smp_f4 test failed");
  3766			goto done;
  3767		}
  3768	
  3769		err = test_f5(tfm_cmac);
  3770		if (err) {
  3771			bt_dev_err(hdev, "smp_f5 test failed");
  3772			goto done;
  3773		}
  3774	
  3775		err = test_f6(tfm_cmac);
  3776		if (err) {
  3777			bt_dev_err(hdev, "smp_f6 test failed");
  3778			goto done;
  3779		}
  3780	
  3781		err = test_g2(tfm_cmac);
  3782		if (err) {
  3783			bt_dev_err(hdev, "smp_g2 test failed");
  3784			goto done;
  3785		}
  3786	
  3787		err = test_h6(tfm_cmac);
  3788		if (err) {
  3789			bt_dev_err(hdev, "smp_h6 test failed");
  3790			goto done;
  3791		}
  3792	
  3793		rettime = ktime_get();
  3794		delta = ktime_sub(rettime, calltime);
  3795		duration = (unsigned long long) ktime_to_ns(delta) >> 10;
  3796	
  3797		BT_INFO("SMP test passed in %llu usecs", duration);
  3798	
  3799	done:
  3800		if (!err)
  3801			snprintf(test_smp_buffer, sizeof(test_smp_buffer),
  3802				 "PASS (%llu usecs)\n", duration);
  3803		else
  3804			snprintf(test_smp_buffer, sizeof(test_smp_buffer), "FAIL\n");
  3805	
  3806		debugfs_create_file("selftest_smp", 0444, bt_debugfs, NULL,
  3807				    &test_smp_fops);
  3808	
  3809		return err;
  3810	}
  3811	

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

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux