]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
Bluetooth: coredump: fix building with coredump disabled
authorArnd Bergmann <arnd@arndb.de>
Mon, 3 Jul 2023 11:30:48 +0000 (13:30 +0200)
committerLuiz Augusto von Dentz <luiz.von.dentz@intel.com>
Thu, 20 Jul 2023 18:25:24 +0000 (11:25 -0700)
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>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
include/net/bluetooth/hci_core.h

index 870b6d3c5146ba9831346559e65450ac678d7d06..e01d52cb668c0526ad44706c0d2ebaae72177331 100644 (file)
@@ -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;