Message ID | 20240711003759.18644-1-chris.lu@mediatek.com (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | [v3] Bluetooth: btmtk: Fix btmtk.c undefined reference build error | expand |
Context | Check | Description |
---|---|---|
tedd_an/pre-ci_am | success | Success |
tedd_an/CheckPatch | success | CheckPatch PASS |
tedd_an/GitLint | fail | WARNING: I3 - ignore-body-lines: gitlint will be switching from using Python regex 'match' (match beginning) to 'search' (match anywhere) semantics. Please review your ignore-body-lines.regex option accordingly. To remove this warning, set general.regex-style-search=True. More details: https://jorisroovers.github.io/gitlint/configuration/#regex-style-search 17: B1 Line exceeds max length (82>80): "Closes: https://lore.kernel.org/oe-kbuild-all/202407091928.AH0aGZnx-lkp@intel.com/" |
tedd_an/SubjectPrefix | success | Gitlint PASS |
tedd_an/BuildKernel | fail | BuildKernel: FAIL: drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 |
tedd_an/CheckAllWarning | fail | CheckAllWarning: FAIL: drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 |
tedd_an/CheckSparse | fail | CheckSparse: FAIL: net/bluetooth/af_bluetooth.c:223:25: warning: context imbalance in 'bt_accept_enqueue' - different lock contexts for basic block drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... net/bluetooth/hci_event.c: note: in included file (through include/net/bluetooth/hci_core.h): ./include/net/bluetooth/hci.h:2596:47: warning: array of flexible structures ./include/net/bluetooth/hci.h:2682:43: warning: array of flexible structures net/bluetooth/hci_codec.c: note: in included file: ./include/net/bluetooth/hci_core.h:147:35: warning: array of flexible structures net/bluetooth/sco.c: note: in included file: ./include/net/bluetooth/hci_core.h:147:35: warning: array of flexible structures make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 |
tedd_an/CheckSmatch | fail | CheckSparse: FAIL: drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... net/bluetooth/hci_event.c: note: in included file (through include/net/bluetooth/hci_core.h): ./include/net/bluetooth/hci.h:2596:47: warning: array of flexible structures ./include/net/bluetooth/hci.h:2682:43: warning: array of flexible structures net/bluetooth/hci_codec.c: note: in included file: ./include/net/bluetooth/hci_core.h:147:35: warning: array of flexible structures net/bluetooth/sco.c: note: in included file: ./include/net/bluetooth/hci_core.h:147:35: warning: array of flexible structures make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 |
tedd_an/BuildKernel32 | fail | BuildKernel32: FAIL: drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 |
tedd_an/TestRunnerSetup | success | TestRunnerSetup PASS |
tedd_an/TestRunner_l2cap-tester | success | TestRunner PASS |
tedd_an/TestRunner_iso-tester | success | TestRunner PASS |
tedd_an/TestRunner_bnep-tester | success | TestRunner PASS |
tedd_an/TestRunner_mgmt-tester | fail | TestRunner_mgmt-tester: Total: 492, Passed: 489 (99.4%), Failed: 1, Not Run: 2 |
tedd_an/TestRunner_rfcomm-tester | success | TestRunner PASS |
tedd_an/TestRunner_sco-tester | success | TestRunner PASS |
tedd_an/TestRunner_ioctl-tester | success | TestRunner PASS |
tedd_an/TestRunner_mesh-tester | success | TestRunner PASS |
tedd_an/TestRunner_smp-tester | success | TestRunner PASS |
tedd_an/TestRunner_userchan-tester | success | TestRunner PASS |
tedd_an/IncrementalBuild | fail | [v3] Bluetooth: btmtk: Fix btmtk.c undefined reference build error drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 |
This is automated email and please do not reply to this email! Dear submitter, Thank you for submitting the patches to the linux bluetooth mailing list. This is a CI test results with your patch series: PW Link:https://patchwork.kernel.org/project/bluetooth/list/?series=870288 ---Test result--- Test Summary: CheckPatch PASS 0.87 seconds GitLint FAIL 0.55 seconds SubjectPrefix PASS 0.13 seconds BuildKernel FAIL 24.16 seconds CheckAllWarning FAIL 26.03 seconds CheckSparse FAIL 29.93 seconds CheckSmatch FAIL 79.10 seconds BuildKernel32 FAIL 22.93 seconds TestRunnerSetup PASS 529.26 seconds TestRunner_l2cap-tester PASS 22.07 seconds TestRunner_iso-tester PASS 32.73 seconds TestRunner_bnep-tester PASS 4.98 seconds TestRunner_mgmt-tester FAIL 112.57 seconds TestRunner_rfcomm-tester PASS 7.62 seconds TestRunner_sco-tester PASS 15.17 seconds TestRunner_ioctl-tester PASS 8.09 seconds TestRunner_mesh-tester PASS 6.03 seconds TestRunner_smp-tester PASS 7.05 seconds TestRunner_userchan-tester PASS 5.16 seconds IncrementalBuild FAIL 22.71 seconds Details ############################## Test: GitLint - FAIL Desc: Run gitlint Output: [v3] Bluetooth: btmtk: Fix btmtk.c undefined reference build error WARNING: I3 - ignore-body-lines: gitlint will be switching from using Python regex 'match' (match beginning) to 'search' (match anywhere) semantics. Please review your ignore-body-lines.regex option accordingly. To remove this warning, set general.regex-style-search=True. More details: https://jorisroovers.github.io/gitlint/configuration/#regex-style-search 17: B1 Line exceeds max length (82>80): "Closes: https://lore.kernel.org/oe-kbuild-all/202407091928.AH0aGZnx-lkp@intel.com/" ############################## Test: BuildKernel - FAIL Desc: Build Kernel for Bluetooth Output: drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 ############################## Test: CheckAllWarning - FAIL Desc: Run linux kernel with all warning enabled Output: drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 ############################## Test: CheckSparse - FAIL Desc: Run sparse tool with linux kernel Output: net/bluetooth/af_bluetooth.c:223:25: warning: context imbalance in 'bt_accept_enqueue' - different lock contexts for basic block drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... net/bluetooth/hci_event.c: note: in included file (through include/net/bluetooth/hci_core.h): ./include/net/bluetooth/hci.h:2596:47: warning: array of flexible structures ./include/net/bluetooth/hci.h:2682:43: warning: array of flexible structures net/bluetooth/hci_codec.c: note: in included file: ./include/net/bluetooth/hci_core.h:147:35: warning: array of flexible structures net/bluetooth/sco.c: note: in included file: ./include/net/bluetooth/hci_core.h:147:35: warning: array of flexible structures make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 ############################## Test: CheckSmatch - FAIL Desc: Run smatch tool with source Output: drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... net/bluetooth/hci_event.c: note: in included file (through include/net/bluetooth/hci_core.h): ./include/net/bluetooth/hci.h:2596:47: warning: array of flexible structures ./include/net/bluetooth/hci.h:2682:43: warning: array of flexible structures net/bluetooth/hci_codec.c: note: in included file: ./include/net/bluetooth/hci_core.h:147:35: warning: array of flexible structures net/bluetooth/sco.c: note: in included file: ./include/net/bluetooth/hci_core.h:147:35: warning: array of flexible structures make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 ############################## Test: BuildKernel32 - FAIL Desc: Build 32bit Kernel for Bluetooth Output: drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 ############################## Test: TestRunner_mgmt-tester - FAIL Desc: Run mgmt-tester with test-runner Output: Total: 492, Passed: 489 (99.4%), Failed: 1, Not Run: 2 Failed Test Cases LL Privacy - Remove Device 4 (Disable Adv) Timed out 2.614 seconds ############################## Test: IncrementalBuild - FAIL Desc: Incremental build with the patches in the series Output: [v3] Bluetooth: btmtk: Fix btmtk.c undefined reference build error drivers/bluetooth/hci_qca.c: In function ‘qca_serdev_remove’: drivers/bluetooth/hci_qca.c:2501:2: error: label at end of compound statement 2501 | default: | ^~~~~~~ make[4]: *** [scripts/Makefile.build:244: drivers/bluetooth/hci_qca.o] Error 1 make[3]: *** [scripts/Makefile.build:485: drivers/bluetooth] Error 2 make[2]: *** [scripts/Makefile.build:485: drivers] Error 2 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [/github/workspace/src/src/Makefile:1934: .] Error 2 make: *** [Makefile:240: __sub-make] Error 2 --- Regards, Linux Bluetooth
diff --git a/drivers/bluetooth/btmtk.c b/drivers/bluetooth/btmtk.c index b7c348687a77..9789296ad4f6 100644 --- a/drivers/bluetooth/btmtk.c +++ b/drivers/bluetooth/btmtk.c @@ -437,6 +437,7 @@ int btmtk_process_coredump(struct hci_dev *hdev, struct sk_buff *skb) } EXPORT_SYMBOL_GPL(btmtk_process_coredump); +#if IS_ENABLED(CONFIG_BT_HCIBTUSB_MTK) static void btmtk_usb_wmt_recv(struct urb *urb) { struct hci_dev *hdev = urb->context; @@ -1487,6 +1488,7 @@ int btmtk_usb_shutdown(struct hci_dev *hdev) return 0; } EXPORT_SYMBOL_GPL(btmtk_usb_shutdown); +#endif MODULE_AUTHOR("Sean Wang <sean.wang@mediatek.com>"); MODULE_AUTHOR("Mark Chen <mark-yw.chen@mediatek.com>"); diff --git a/drivers/bluetooth/btmtk.h b/drivers/bluetooth/btmtk.h index 453ed5131a37..6bb59f4096b7 100644 --- a/drivers/bluetooth/btmtk.h +++ b/drivers/bluetooth/btmtk.h @@ -202,6 +202,7 @@ int btmtk_process_coredump(struct hci_dev *hdev, struct sk_buff *skb); void btmtk_fw_get_filename(char *buf, size_t size, u32 dev_id, u32 fw_ver, u32 fw_flavor); +#if IS_ENABLED(CONFIG_BT_HCIBTUSB_MTK) int btmtk_usb_subsys_reset(struct hci_dev *hdev, u32 dev_id); int btmtk_usb_recv_acl(struct hci_dev *hdev, struct sk_buff *skb); @@ -216,6 +217,7 @@ int btmtk_usb_suspend(struct hci_dev *hdev); int btmtk_usb_setup(struct hci_dev *hdev); int btmtk_usb_shutdown(struct hci_dev *hdev); +#endif #else static inline int btmtk_set_bdaddr(struct hci_dev *hdev,
MediaTek moved some usb interface related function to btmtk.c which may cause build failed if BT USB Kconfig wasn't enabled. Fix undefined reference by adding config check. btmtk.c:(.text+0x89c): undefined reference to `usb_alloc_urb' btmtk.c:(.text+0x8e3): undefined reference to `usb_free_urb' btmtk.c:(.text+0x956): undefined reference to `usb_free_urb' btmtk.c:(.text+0xa0e): undefined reference to `usb_anchor_urb' btmtk.c:(.text+0xb43): undefined reference to `usb_autopm_get_interface' btmtk.c:(.text+0xb7e): undefined reference to `usb_autopm_put_interface' btmtk.c:(.text+0xf70): undefined reference to `usb_disable_autosuspend' btmtk.c:(.text+0x133a): undefined reference to `usb_control_msg' Fixes: 39a9e1c69e74 ("Bluetooth: btmtk: move btusb_mtk_hci_wmt_sync to btmtk.c") Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202407091928.AH0aGZnx-lkp@intel.com/ Signed-off-by: Chris Lu <chris.lu@mediatek.com> --- Change from v2 to v3: -remove #if in structure in case error causes with certain compilier --- drivers/bluetooth/btmtk.c | 2 ++ drivers/bluetooth/btmtk.h | 2 ++ 2 files changed, 4 insertions(+)