Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Bluetooth: Always compile SCO and L2CAP in Bluetooth Core

The handling of SCO audio links and the L2CAP protocol are essential to
any system with Bluetooth thus are always compiled in from now on.

Signed-off-by: Ulisses Furquim <ulisses@profusion.mobi>
Acked-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>

authored by

Ulisses Furquim and committed by
Gustavo F. Padovan
f1e91e16 f2d64f6a

+15 -57
-22
include/net/bluetooth/bluetooth.h
··· 250 250 251 251 extern struct dentry *bt_debugfs; 252 252 253 - #ifdef CONFIG_BT_L2CAP 254 253 int l2cap_init(void); 255 254 void l2cap_exit(void); 256 - #else 257 - static inline int l2cap_init(void) 258 - { 259 - return 0; 260 - } 261 255 262 - static inline void l2cap_exit(void) 263 - { 264 - } 265 - #endif 266 - 267 - #ifdef CONFIG_BT_SCO 268 256 int sco_init(void); 269 257 void sco_exit(void); 270 - #else 271 - static inline int sco_init(void) 272 - { 273 - return 0; 274 - } 275 - 276 - static inline void sco_exit(void) 277 - { 278 - } 279 - #endif 280 258 281 259 #endif /* __BLUETOOTH_H */
+9 -28
net/bluetooth/Kconfig
··· 6 6 tristate "Bluetooth subsystem support" 7 7 depends on NET && !S390 8 8 depends on RFKILL || !RFKILL 9 + select CRC16 9 10 select CRYPTO 11 + select CRYPTO_BLKCIPHER 12 + select CRYPTO_AES 13 + select CRYPTO_ECB 10 14 help 11 15 Bluetooth is low-cost, low-power, short-range wireless technology. 12 16 It was designed as a replacement for cables and other short-range ··· 19 15 Bluetooth can be found at <http://www.bluetooth.com/>. 20 16 21 17 Linux Bluetooth subsystem consist of several layers: 22 - Bluetooth Core (HCI device and connection manager, scheduler) 18 + Bluetooth Core 19 + HCI device and connection manager, scheduler 20 + SCO audio links 21 + L2CAP (Logical Link Control and Adaptation Protocol) 22 + SMP (Security Manager Protocol) on LE (Low Energy) links 23 23 HCI Device drivers (Interface to the hardware) 24 - SCO Module (SCO audio links) 25 - L2CAP Module (Logical Link Control and Adaptation Protocol) 26 24 RFCOMM Module (RFCOMM Protocol) 27 25 BNEP Module (Bluetooth Network Encapsulation Protocol) 28 26 CMTP Module (CAPI Message Transport Protocol) ··· 38 32 utilities like hciconfig and bluetoothd. These utilities and updates 39 33 to Bluetooth kernel modules are provided in the BlueZ packages. For 40 34 more information, see <http://www.bluez.org/>. 41 - 42 - if BT != n 43 - 44 - config BT_L2CAP 45 - bool "L2CAP protocol support" 46 - select CRC16 47 - select CRYPTO 48 - select CRYPTO_BLKCIPHER 49 - select CRYPTO_AES 50 - select CRYPTO_ECB 51 - help 52 - L2CAP (Logical Link Control and Adaptation Protocol) provides 53 - connection oriented and connection-less data transport. L2CAP 54 - support is required for most Bluetooth applications. 55 - 56 - Also included is support for SMP (Security Manager Protocol) which 57 - is the security layer on top of LE (Low Energy) links. 58 - 59 - config BT_SCO 60 - bool "SCO links support" 61 - help 62 - SCO link provides voice transport over Bluetooth. SCO support is 63 - required for voice applications like Headset and Audio. 64 - 65 - endif 66 35 67 36 source "net/bluetooth/rfcomm/Kconfig" 68 37
+2 -3
net/bluetooth/Makefile
··· 8 8 obj-$(CONFIG_BT_CMTP) += cmtp/ 9 9 obj-$(CONFIG_BT_HIDP) += hidp/ 10 10 11 - bluetooth-y := af_bluetooth.o hci_core.o hci_conn.o hci_event.o mgmt.o hci_sock.o hci_sysfs.o lib.o 12 - bluetooth-$(CONFIG_BT_L2CAP) += l2cap_core.o l2cap_sock.o smp.o 13 - bluetooth-$(CONFIG_BT_SCO) += sco.o 11 + bluetooth-y := af_bluetooth.o hci_core.o hci_conn.o hci_event.o mgmt.o \ 12 + hci_sock.o hci_sysfs.o l2cap_core.o l2cap_sock.o smp.o sco.o lib.o
+1 -1
net/bluetooth/bnep/Kconfig
··· 1 1 config BT_BNEP 2 2 tristate "BNEP protocol support" 3 - depends on BT && BT_L2CAP 3 + depends on BT 4 4 select CRC32 5 5 help 6 6 BNEP (Bluetooth Network Encapsulation Protocol) is Ethernet
+1 -1
net/bluetooth/cmtp/Kconfig
··· 1 1 config BT_CMTP 2 2 tristate "CMTP protocol support" 3 - depends on BT && BT_L2CAP && ISDN_CAPI 3 + depends on BT && ISDN_CAPI 4 4 help 5 5 CMTP (CAPI Message Transport Protocol) is a transport layer 6 6 for CAPI messages. CMTP is required for the Bluetooth Common
+1 -1
net/bluetooth/hidp/Kconfig
··· 1 1 config BT_HIDP 2 2 tristate "HIDP protocol support" 3 - depends on BT && BT_L2CAP && INPUT && HID_SUPPORT 3 + depends on BT && INPUT && HID_SUPPORT 4 4 select HID 5 5 help 6 6 HIDP (Human Interface Device Protocol) is a transport layer
+1 -1
net/bluetooth/rfcomm/Kconfig
··· 1 1 config BT_RFCOMM 2 2 tristate "RFCOMM protocol support" 3 - depends on BT && BT_L2CAP 3 + depends on BT 4 4 help 5 5 RFCOMM provides connection oriented stream transport. RFCOMM 6 6 support is required for Dialup Networking, OBEX and other Bluetooth