diff mbox series

Bluetooth: coredump: fix building with coredump disabled

Message ID 20230703113112.380663-1-arnd@kernel.org (mailing list archive)
State Accepted
Commit 6ca03ff0da3eabf78a60b2f2c9bfb31d80047403
Headers show
Series Bluetooth: coredump: fix building with coredump disabled | expand

Checks

Context Check Description
tedd_an/pre-ci_am success Success
tedd_an/CheckPatch warning WARNING: Please use correct Fixes: style 'Fixes: <12 chars of sha1> ("<title line>")' - ie: 'Fixes: ("Bluetooth: btusb: mediatek: add MediaTek devcoredump support")' #86: Fixes: 872f8c253cb9e ("Bluetooth: btusb: mediatek: add MediaTek devcoredump support") WARNING: Please use correct Fixes: style 'Fixes: <12 chars of sha1> ("<title line>")' - ie: 'Fixes: ("Bluetooth: Add support for hci devcoredump")' #87: Fixes: 9695ef876fd12 ("Bluetooth: Add support for hci devcoredump") total: 0 errors, 2 warnings, 9 lines checked NOTE: For some of the reported defects, checkpatch may be able to mechanically convert to the typical style using --fix or --fix-inplace. /github/workspace/src/src/13299982.patch has style problems, please review. NOTE: Ignored message types: UNKNOWN_COMMIT_ID NOTE: If any of the errors are false positives, please report them to the maintainer, see CHECKPATCH in MAINTAINERS. Use of uninitialized value $cid in concatenation (.) or string at /github/workspace/src/src/scripts/checkpatch.pl line 3226. Use of uninitialized value $cid in concatenation (.) or string at /github/workspace/src/src/scripts/checkpatch.pl line 3226.
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 10: B1 Line exceeds max length (84>80): "drivers/bluetooth/btmtk.c:386:30: error: 'struct hci_dev' has no member named 'dump'"
tedd_an/SubjectPrefix success Gitlint PASS
tedd_an/BuildKernel success BuildKernel PASS
tedd_an/CheckAllWarning success CheckAllWarning PASS
tedd_an/CheckSparse success CheckSparse PASS
tedd_an/CheckSmatch success CheckSparse PASS
tedd_an/BuildKernel32 success BuildKernel32 PASS
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 success TestRunner PASS
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 success Incremental Build PASS

Commit Message

Arnd Bergmann July 3, 2023, 11:30 a.m. UTC
From: Arnd Bergmann <arnd@arndb.de>

The btmtk driver uses an IS_ENABLED() check to conditionally compile
the coredump support, but this fails to build because the hdev->dump
member is in an #ifdef:

drivers/bluetooth/btmtk.c: In function 'btmtk_process_coredump':
drivers/bluetooth/btmtk.c:386:30: error: 'struct hci_dev' has no member named 'dump'
  386 |   schedule_delayed_work(&hdev->dump.dump_timeout,
      |                              ^~

The struct member doesn't really make a huge difference in the total size,
so just remove the #ifdef around it to avoid adding similar checks
around each user.

Fixes: 872f8c253cb9e ("Bluetooth: btusb: mediatek: add MediaTek devcoredump support")
Fixes: 9695ef876fd12 ("Bluetooth: Add support for hci devcoredump")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 include/net/bluetooth/hci_core.h | 2 --
 1 file changed, 2 deletions(-)

Comments

bluez.test.bot@gmail.com July 3, 2023, 11:57 a.m. UTC | #1
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=761988

---Test result---

Test Summary:
CheckPatch                    FAIL      0.83 seconds
GitLint                       FAIL      0.52 seconds
SubjectPrefix                 PASS      0.07 seconds
BuildKernel                   PASS      32.44 seconds
CheckAllWarning               PASS      35.05 seconds
CheckSparse                   PASS      40.55 seconds
CheckSmatch                   PASS      111.19 seconds
BuildKernel32                 PASS      31.62 seconds
TestRunnerSetup               PASS      447.80 seconds
TestRunner_l2cap-tester       PASS      12.89 seconds
TestRunner_iso-tester         PASS      23.81 seconds
TestRunner_bnep-tester        PASS      5.52 seconds
TestRunner_mgmt-tester        PASS      132.56 seconds
TestRunner_rfcomm-tester      PASS      9.02 seconds
TestRunner_sco-tester         PASS      10.35 seconds
TestRunner_ioctl-tester       PASS      12.04 seconds
TestRunner_mesh-tester        PASS      7.02 seconds
TestRunner_smp-tester         PASS      8.11 seconds
TestRunner_userchan-tester    PASS      5.79 seconds
IncrementalBuild              PASS      30.03 seconds

Details
##############################
Test: CheckPatch - FAIL
Desc: Run checkpatch.pl script
Output:
Bluetooth: coredump: fix building with coredump disabled
WARNING: Please use correct Fixes: style 'Fixes: <12 chars of sha1> ("<title line>")' - ie: 'Fixes:  ("Bluetooth: btusb: mediatek: add MediaTek devcoredump support")'
#86: 
Fixes: 872f8c253cb9e ("Bluetooth: btusb: mediatek: add MediaTek devcoredump support")

WARNING: Please use correct Fixes: style 'Fixes: <12 chars of sha1> ("<title line>")' - ie: 'Fixes:  ("Bluetooth: Add support for hci devcoredump")'
#87: 
Fixes: 9695ef876fd12 ("Bluetooth: Add support for hci devcoredump")

total: 0 errors, 2 warnings, 9 lines checked

NOTE: For some of the reported defects, checkpatch may be able to
      mechanically convert to the typical style using --fix or --fix-inplace.

/github/workspace/src/src/13299982.patch has style problems, please review.

NOTE: Ignored message types: UNKNOWN_COMMIT_ID

NOTE: If any of the errors are false positives, please report
      them to the maintainer, see CHECKPATCH in MAINTAINERS.


Use of uninitialized value $cid in concatenation (.) or string at /github/workspace/src/src/scripts/checkpatch.pl line 3226.
Use of uninitialized value $cid in concatenation (.) or string at /github/workspace/src/src/scripts/checkpatch.pl line 3226.
##############################
Test: GitLint - FAIL
Desc: Run gitlint
Output:
Bluetooth: coredump: fix building with coredump disabled

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
10: B1 Line exceeds max length (84>80): "drivers/bluetooth/btmtk.c:386:30: error: 'struct hci_dev' has no member named 'dump'"


---
Regards,
Linux Bluetooth
patchwork-bot+bluetooth@kernel.org July 5, 2023, 11 p.m. UTC | #2
Hello:

This patch was applied to bluetooth/bluetooth-next.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:

On Mon,  3 Jul 2023 13:30:48 +0200 you wrote:
> From: Arnd Bergmann <arnd@arndb.de>
> 
> The btmtk driver uses an IS_ENABLED() check to conditionally compile
> the coredump support, but this fails to build because the hdev->dump
> member is in an #ifdef:
> 
> drivers/bluetooth/btmtk.c: In function 'btmtk_process_coredump':
> drivers/bluetooth/btmtk.c:386:30: error: 'struct hci_dev' has no member named 'dump'
>   386 |   schedule_delayed_work(&hdev->dump.dump_timeout,
>       |                              ^~
> 
> [...]

Here is the summary with links:
  - Bluetooth: coredump: fix building with coredump disabled
    https://git.kernel.org/bluetooth/bluetooth-next/c/6ca03ff0da3e

You are awesome, thank you!
diff mbox series

Patch

diff --git a/include/net/bluetooth/hci_core.h b/include/net/bluetooth/hci_core.h
index c0ca3f869c923..491ab83ccafc9 100644
--- a/include/net/bluetooth/hci_core.h
+++ b/include/net/bluetooth/hci_core.h
@@ -593,9 +593,7 @@  struct hci_dev {
 	const char		*fw_info;
 	struct dentry		*debugfs;
 
-#ifdef CONFIG_DEV_COREDUMP
 	struct hci_devcoredump	dump;
-#endif
 
 	struct device		dev;