Skip to content

Commit 1c5091a

Browse files
jcalvinowensVudentz
authored andcommitted
Bluetooth: Fix build after header cleanup
Some Kconfig dependencies are needed after my recent cleanup, since the core code has its own option. Since btmtksdio does not actually call h4_recv_buf(), move the definitions it uses outside the BT_HCIUART_H4 gate in hci_uart.h to avoid adding a dependency for btmtksdio. The rest I touched (bpa10x, btmtkuart, and btnxpuart) do really call h4_recv_buf(), so the dependency is required, add it for them. Fixes: 0e272fc7e17d ("Bluetooth: remove duplicate h4_recv_buf() in header") Reported-by: kernel test robot <[email protected]> Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/ Signed-off-by: Calvin Owens <[email protected]> Signed-off-by: Luiz Augusto von Dentz <[email protected]>
1 parent b65678c commit 1c5091a

File tree

2 files changed

+10
-4
lines changed

2 files changed

+10
-4
lines changed

drivers/bluetooth/Kconfig

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -312,7 +312,9 @@ config BT_HCIBCM4377
312312

313313
config BT_HCIBPA10X
314314
tristate "HCI BPA10x USB driver"
315+
depends on BT_HCIUART
315316
depends on USB
317+
select BT_HCIUART_H4
316318
help
317319
Bluetooth HCI BPA10x USB driver.
318320
This driver provides support for the Digianswer BPA 100/105 Bluetooth
@@ -437,8 +439,10 @@ config BT_MTKSDIO
437439

438440
config BT_MTKUART
439441
tristate "MediaTek HCI UART driver"
442+
depends on BT_HCIUART
440443
depends on SERIAL_DEV_BUS
441444
depends on USB || !BT_HCIBTUSB_MTK
445+
select BT_HCIUART_H4
442446
select BT_MTK
443447
help
444448
MediaTek Bluetooth HCI UART driver.
@@ -483,7 +487,9 @@ config BT_VIRTIO
483487

484488
config BT_NXPUART
485489
tristate "NXP protocol support"
490+
depends on BT_HCIUART
486491
depends on SERIAL_DEV_BUS
492+
select BT_HCIUART_H4
487493
select CRC32
488494
select CRC8
489495
help

drivers/bluetooth/hci_uart.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -121,10 +121,6 @@ void hci_uart_set_flow_control(struct hci_uart *hu, bool enable);
121121
void hci_uart_set_speeds(struct hci_uart *hu, unsigned int init_speed,
122122
unsigned int oper_speed);
123123

124-
#ifdef CONFIG_BT_HCIUART_H4
125-
int h4_init(void);
126-
int h4_deinit(void);
127-
128124
struct h4_recv_pkt {
129125
u8 type; /* Packet type */
130126
u8 hlen; /* Header length */
@@ -162,6 +158,10 @@ struct h4_recv_pkt {
162158
.lsize = 2, \
163159
.maxlen = HCI_MAX_FRAME_SIZE \
164160

161+
#ifdef CONFIG_BT_HCIUART_H4
162+
int h4_init(void);
163+
int h4_deinit(void);
164+
165165
struct sk_buff *h4_recv_buf(struct hci_dev *hdev, struct sk_buff *skb,
166166
const unsigned char *buffer, int count,
167167
const struct h4_recv_pkt *pkts, int pkts_count);

0 commit comments

Comments
 (0)