[kbuild] [linux-next:master 7132/11526] drivers/bluetooth/btusb.c:3775 btusb_mtk_setup() error: uninitialized symbol 'fw_version'.
by Dan Carpenter
[ Why is linux-mm CC'd on these patches??? - dan ]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: 6553715b6db5ff5d4898895dad1b2926cfe406cf
commit: fc342c4dc408754f50f19dc832152fbb4b73f1e6 [7132/11526] Bluetooth: btusb: Add protocol support for MediaTek MT7921U USB devices
config: parisc-randconfig-m031-20210216 (attached as .config)
compiler: hppa-linux-gcc (GCC) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Reported-by: Dan Carpenter <dan.carpenter(a)oracle.com>
New smatch warnings:
drivers/bluetooth/btusb.c:3775 btusb_mtk_setup() error: uninitialized symbol 'fw_version'.
Old smatch warnings:
drivers/bluetooth/btusb.c:2201 btusb_setup_intel() warn: inconsistent indenting
vim +/fw_version +3775 drivers/bluetooth/btusb.c
a1c49c434e15050 Sean Wang 2019-06-02 3729 static int btusb_mtk_setup(struct hci_dev *hdev)
a1c49c434e15050 Sean Wang 2019-06-02 3730 {
a1c49c434e15050 Sean Wang 2019-06-02 3731 struct btusb_data *data = hci_get_drvdata(hdev);
a1c49c434e15050 Sean Wang 2019-06-02 3732 struct btmtk_hci_wmt_params wmt_params;
a1c49c434e15050 Sean Wang 2019-06-02 3733 ktime_t calltime, delta, rettime;
a1c49c434e15050 Sean Wang 2019-06-02 3734 struct btmtk_tci_sleep tci_sleep;
a1c49c434e15050 Sean Wang 2019-06-02 3735 unsigned long long duration;
a1c49c434e15050 Sean Wang 2019-06-02 3736 struct sk_buff *skb;
a1c49c434e15050 Sean Wang 2019-06-02 3737 const char *fwname;
a1c49c434e15050 Sean Wang 2019-06-02 3738 int err, status;
a1c49c434e15050 Sean Wang 2019-06-02 3739 u32 dev_id;
fc342c4dc408754 Mark Chen 2021-02-02 3740 char fw_bin_name[64];
fc342c4dc408754 Mark Chen 2021-02-02 3741 u32 fw_version;
a1c49c434e15050 Sean Wang 2019-06-02 3742 u8 param;
a1c49c434e15050 Sean Wang 2019-06-02 3743
a1c49c434e15050 Sean Wang 2019-06-02 3744 calltime = ktime_get();
a1c49c434e15050 Sean Wang 2019-06-02 3745
48c13301e6baba5 Mark Chen 2021-02-02 3746 err = btusb_mtk_id_get(data, 0x80000008, &dev_id);
a1c49c434e15050 Sean Wang 2019-06-02 3747 if (err < 0) {
a1c49c434e15050 Sean Wang 2019-06-02 3748 bt_dev_err(hdev, "Failed to get device id (%d)", err);
a1c49c434e15050 Sean Wang 2019-06-02 3749 return err;
a1c49c434e15050 Sean Wang 2019-06-02 3750 }
a1c49c434e15050 Sean Wang 2019-06-02 3751
fc342c4dc408754 Mark Chen 2021-02-02 3752 if (!dev_id) {
fc342c4dc408754 Mark Chen 2021-02-02 3753 err = btusb_mtk_id_get(data, 0x70010200, &dev_id);
fc342c4dc408754 Mark Chen 2021-02-02 3754 if (err < 0) {
fc342c4dc408754 Mark Chen 2021-02-02 3755 bt_dev_err(hdev, "Failed to get device id (%d)", err);
fc342c4dc408754 Mark Chen 2021-02-02 3756 return err;
fc342c4dc408754 Mark Chen 2021-02-02 3757 }
fc342c4dc408754 Mark Chen 2021-02-02 3758 err = btusb_mtk_id_get(data, 0x80021004, &fw_version);
fc342c4dc408754 Mark Chen 2021-02-02 3759 if (err < 0) {
fc342c4dc408754 Mark Chen 2021-02-02 3760 bt_dev_err(hdev, "Failed to get fw version (%d)", err);
fc342c4dc408754 Mark Chen 2021-02-02 3761 return err;
fc342c4dc408754 Mark Chen 2021-02-02 3762 }
fc342c4dc408754 Mark Chen 2021-02-02 3763 }
"fw_version" not initialized on else path.
fc342c4dc408754 Mark Chen 2021-02-02 3764
a1c49c434e15050 Sean Wang 2019-06-02 3765 switch (dev_id) {
9ce67c3235be71e Sean Wang 2019-06-02 3766 case 0x7663:
9ce67c3235be71e Sean Wang 2019-06-02 3767 fwname = FIRMWARE_MT7663;
9ce67c3235be71e Sean Wang 2019-06-02 3768 break;
a1c49c434e15050 Sean Wang 2019-06-02 3769 case 0x7668:
a1c49c434e15050 Sean Wang 2019-06-02 3770 fwname = FIRMWARE_MT7668;
a1c49c434e15050 Sean Wang 2019-06-02 3771 break;
fc342c4dc408754 Mark Chen 2021-02-02 3772 case 0x7961:
fc342c4dc408754 Mark Chen 2021-02-02 3773 snprintf(fw_bin_name, sizeof(fw_bin_name),
fc342c4dc408754 Mark Chen 2021-02-02 3774 "mediatek/BT_RAM_CODE_MT%04x_1_%x_hdr.bin",
fc342c4dc408754 Mark Chen 2021-02-02 @3775 dev_id & 0xffff, (fw_version & 0xff) + 1);
^^^^^^^^^^
fc342c4dc408754 Mark Chen 2021-02-02 3776 err = btusb_mtk_setup_firmware_79xx(hdev, fw_bin_name);
fc342c4dc408754 Mark Chen 2021-02-02 3777
fc342c4dc408754 Mark Chen 2021-02-02 3778 /* Enable Bluetooth protocol */
fc342c4dc408754 Mark Chen 2021-02-02 3779 param = 1;
fc342c4dc408754 Mark Chen 2021-02-02 3780 wmt_params.op = BTMTK_WMT_FUNC_CTRL;
fc342c4dc408754 Mark Chen 2021-02-02 3781 wmt_params.flag = 0;
fc342c4dc408754 Mark Chen 2021-02-02 3782 wmt_params.dlen = sizeof(param);
fc342c4dc408754 Mark Chen 2021-02-02 3783 wmt_params.data = ¶m;
fc342c4dc408754 Mark Chen 2021-02-02 3784 wmt_params.status = NULL;
fc342c4dc408754 Mark Chen 2021-02-02 3785
fc342c4dc408754 Mark Chen 2021-02-02 3786 err = btusb_mtk_hci_wmt_sync(hdev, &wmt_params);
fc342c4dc408754 Mark Chen 2021-02-02 3787 if (err < 0) {
fc342c4dc408754 Mark Chen 2021-02-02 3788 bt_dev_err(hdev, "Failed to send wmt func ctrl (%d)", err);
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
_______________________________________________
kbuild mailing list -- kbuild(a)lists.01.org
To unsubscribe send an email to kbuild-leave(a)lists.01.org
12 months
mmu.c:undefined reference to `patch__hash_page_A0'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 3fb6d0e00efc958d01c2f109c8453033a2d96796
commit: 259149cf7c3c6195e6199e045ca988c31d081cab powerpc/32s: Only build hash code when CONFIG_PPC_BOOK3S_604 is selected
date: 4 weeks ago
config: powerpc64-randconfig-r013-20210227 (attached as .config)
compiler: powerpc-linux-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://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 259149cf7c3c6195e6199e045ca988c31d081cab
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=powerpc64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
powerpc-linux-ld: arch/powerpc/mm/book3s32/mmu.o: in function `MMU_init_hw_patch':
>> mmu.c:(.init.text+0x75e): undefined reference to `patch__hash_page_A0'
>> powerpc-linux-ld: mmu.c:(.init.text+0x76a): undefined reference to `patch__hash_page_A0'
>> powerpc-linux-ld: mmu.c:(.init.text+0x776): undefined reference to `patch__hash_page_A1'
powerpc-linux-ld: mmu.c:(.init.text+0x782): undefined reference to `patch__hash_page_A1'
>> powerpc-linux-ld: mmu.c:(.init.text+0x78e): undefined reference to `patch__hash_page_A2'
powerpc-linux-ld: mmu.c:(.init.text+0x79a): undefined reference to `patch__hash_page_A2'
>> powerpc-linux-ld: mmu.c:(.init.text+0x7aa): undefined reference to `patch__hash_page_B'
powerpc-linux-ld: mmu.c:(.init.text+0x7b6): undefined reference to `patch__hash_page_B'
>> powerpc-linux-ld: mmu.c:(.init.text+0x7c2): undefined reference to `patch__hash_page_C'
powerpc-linux-ld: mmu.c:(.init.text+0x7ce): undefined reference to `patch__hash_page_C'
>> powerpc-linux-ld: mmu.c:(.init.text+0x7da): undefined reference to `patch__flush_hash_A0'
powerpc-linux-ld: mmu.c:(.init.text+0x7e6): undefined reference to `patch__flush_hash_A0'
>> powerpc-linux-ld: mmu.c:(.init.text+0x7f2): undefined reference to `patch__flush_hash_A1'
powerpc-linux-ld: mmu.c:(.init.text+0x7fe): undefined reference to `patch__flush_hash_A1'
>> powerpc-linux-ld: mmu.c:(.init.text+0x80a): undefined reference to `patch__flush_hash_A2'
powerpc-linux-ld: mmu.c:(.init.text+0x816): undefined reference to `patch__flush_hash_A2'
>> powerpc-linux-ld: mmu.c:(.init.text+0x83e): undefined reference to `patch__flush_hash_B'
powerpc-linux-ld: mmu.c:(.init.text+0x84e): undefined reference to `patch__flush_hash_B'
powerpc-linux-ld: arch/powerpc/mm/book3s32/mmu.o: in function `update_mmu_cache':
>> mmu.c:(.text.update_mmu_cache+0xa0): undefined reference to `add_hash_page'
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year
include/linux/compiler_types.h:315:38: error: call to '__compiletime_assert_536' declared with attribute error: BUILD_BUG_ON failed: offsetof(struct can_frame, len) != offsetof(struct canfd_frame, len) || offsetof(struct can_frame, data) != offsetof(struc...
by kernel test robot
Hi Oliver,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 812da4d39463a060738008a46cfc9f775e4bfcf6
commit: c7b74967799b1af52b3045d69d4c26836b2d41de can: replace can_dlc as variable/element for payload length
date: 4 months ago
config: arm-randconfig-r016-20210321 (attached as .config)
compiler: arm-linux-gnueabi-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://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout c7b74967799b1af52b3045d69d4c26836b2d41de
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=arm
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from <command-line>:
net/can/af_can.c: In function 'can_init':
>> include/linux/compiler_types.h:315:38: error: call to '__compiletime_assert_536' declared with attribute error: BUILD_BUG_ON failed: offsetof(struct can_frame, len) != offsetof(struct canfd_frame, len) || offsetof(struct can_frame, data) != offsetof(struct canfd_frame, data)
315 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^
include/linux/compiler_types.h:296:4: note: in definition of macro '__compiletime_assert'
296 | prefix ## suffix(); \
| ^~~~~~
include/linux/compiler_types.h:315:2: note: in expansion of macro '_compiletime_assert'
315 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^~~~~~~~~~~~~~~~~~~
include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert'
39 | #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
| ^~~~~~~~~~~~~~~~~~
include/linux/build_bug.h:50:2: note: in expansion of macro 'BUILD_BUG_ON_MSG'
50 | BUILD_BUG_ON_MSG(condition, "BUILD_BUG_ON failed: " #condition)
| ^~~~~~~~~~~~~~~~
net/can/af_can.c:891:2: note: in expansion of macro 'BUILD_BUG_ON'
891 | BUILD_BUG_ON(offsetof(struct can_frame, len) !=
| ^~~~~~~~~~~~
vim +/__compiletime_assert_536 +315 include/linux/compiler_types.h
eb5c2d4b45e3d2 Will Deacon 2020-07-21 301
eb5c2d4b45e3d2 Will Deacon 2020-07-21 302 #define _compiletime_assert(condition, msg, prefix, suffix) \
eb5c2d4b45e3d2 Will Deacon 2020-07-21 303 __compiletime_assert(condition, msg, prefix, suffix)
eb5c2d4b45e3d2 Will Deacon 2020-07-21 304
eb5c2d4b45e3d2 Will Deacon 2020-07-21 305 /**
eb5c2d4b45e3d2 Will Deacon 2020-07-21 306 * compiletime_assert - break build and emit msg if condition is false
eb5c2d4b45e3d2 Will Deacon 2020-07-21 307 * @condition: a compile-time constant condition to check
eb5c2d4b45e3d2 Will Deacon 2020-07-21 308 * @msg: a message to emit if condition is false
eb5c2d4b45e3d2 Will Deacon 2020-07-21 309 *
eb5c2d4b45e3d2 Will Deacon 2020-07-21 310 * In tradition of POSIX assert, this macro will break the build if the
eb5c2d4b45e3d2 Will Deacon 2020-07-21 311 * supplied condition is *false*, emitting the supplied error message if the
eb5c2d4b45e3d2 Will Deacon 2020-07-21 312 * compiler has support to do so.
eb5c2d4b45e3d2 Will Deacon 2020-07-21 313 */
eb5c2d4b45e3d2 Will Deacon 2020-07-21 314 #define compiletime_assert(condition, msg) \
eb5c2d4b45e3d2 Will Deacon 2020-07-21 @315 _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
eb5c2d4b45e3d2 Will Deacon 2020-07-21 316
:::::: The code at line 315 was first introduced by commit
:::::: eb5c2d4b45e3d2d5d052ea6b8f1463976b1020d5 compiler.h: Move compiletime_assert() macros into compiler_types.h
:::::: TO: Will Deacon <will(a)kernel.org>
:::::: CC: Will Deacon <will(a)kernel.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 1 month
Re: [PATCH] mm: gup: remove FOLL_SPLIT
by kernel test robot
Hi Yang,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on hnaz-linux-mm/master]
url: https://github.com/0day-ci/linux/commits/Yang-Shi/mm-gup-remove-FOLL_SPLI...
base: https://github.com/hnaz/linux-mm master
config: s390-randconfig-r032-20210330 (attached as .config)
compiler: s390-linux-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/c8563a636718f98af86a3965d94e25b8f...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Yang-Shi/mm-gup-remove-FOLL_SPLIT/20210330-034042
git checkout c8563a636718f98af86a3965d94e25b8f2cf2354
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=s390
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
arch/s390/mm/gmap.c: In function 'thp_split_mm':
>> arch/s390/mm/gmap.c:2498:27: error: 'FOLL_SPLIT' undeclared (first use in this function); did you mean 'FOLL_PIN'?
2498 | follow_page(vma, addr, FOLL_SPLIT);
| ^~~~~~~~~~
| FOLL_PIN
arch/s390/mm/gmap.c:2498:27: note: each undeclared identifier is reported only once for each function it appears in
vim +2498 arch/s390/mm/gmap.c
0959e168678d2d Janosch Frank 2018-07-17 2487
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2488 static inline void thp_split_mm(struct mm_struct *mm)
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2489 {
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2490 #ifdef CONFIG_TRANSPARENT_HUGEPAGE
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2491 struct vm_area_struct *vma;
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2492 unsigned long addr;
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2493
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2494 for (vma = mm->mmap; vma != NULL; vma = vma->vm_next) {
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2495 for (addr = vma->vm_start;
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2496 addr < vma->vm_end;
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2497 addr += PAGE_SIZE)
1e133ab296f3ff Martin Schwidefsky 2016-03-08 @2498 follow_page(vma, addr, FOLL_SPLIT);
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2499 vma->vm_flags &= ~VM_HUGEPAGE;
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2500 vma->vm_flags |= VM_NOHUGEPAGE;
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2501 }
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2502 mm->def_flags |= VM_NOHUGEPAGE;
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2503 #endif
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2504 }
1e133ab296f3ff Martin Schwidefsky 2016-03-08 2505
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 1 month