Bluetooth: L2CAP: Move Kconfig option to its own it own file

The Bluetooth menu has way too many option so this move the L2CAP
specific option to its own menu.

Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
This commit is contained in:
Luiz Augusto von Dentz 2019-05-21 15:55:26 +03:00 committed by Johan Hedberg
commit 270e8342f5
2 changed files with 69 additions and 53 deletions

View file

@ -172,47 +172,8 @@ config BT_ACL_RX_COUNT
range 1 64
help
Number of buffers available for incoming ACL data.
config BT_L2CAP_RX_MTU
int "Maximum supported L2CAP MTU for incoming data"
default 200 if BT_BREDR
default 65 if BT_SMP
default 23
range 65 1300 if BT_SMP
range 23 1300
help
Maximum size of each incoming L2CAP PDU.
endif # BT_HCI_ACL_FLOW_CONTROL
config BT_L2CAP_TX_BUF_COUNT
int "Number of L2CAP TX buffers"
default 3
range 2 255
help
Number of buffers available for outgoing L2CAP packets.
config BT_L2CAP_TX_FRAG_COUNT
int "Number of L2CAP TX fragment buffers"
default 2
range 0 255
help
Number of buffers available for fragments of TX buffers. Warning:
setting this to 0 means that the application must ensure that
queued TX buffers never need to be fragmented, i.e. that the
controller's buffer size is large enough. If this is not ensured,
and there are no dedicated fragment buffers, a deadlock may occur.
In most cases the default value of 2 is a safe bet.
config BT_L2CAP_TX_MTU
int "Maximum supported L2CAP MTU for L2CAP TX buffers"
default 253 if BT_BREDR
default 65 if BT_SMP
default 23
range 65 2000 if BT_SMP
range 23 2000
help
Maximum L2CAP MTU for L2CAP TX buffers.
config BT_CONN_TX_MAX
int "Maximum number of pending TX buffers"
default BT_CTLR_TX_BUFFERS if BT_CTLR
@ -322,13 +283,7 @@ config BT_OOB_DATA_FIXED
endif # BT_SMP
config BT_L2CAP_DYNAMIC_CHANNEL
bool "L2CAP Dynamic Channel support"
depends on BT_SMP
help
This option enables support for LE Connection oriented Channels,
allowing the creation of dynamic L2CAP Channels.
source "subsys/bluetooth/host/Kconfig.l2cap"
source "subsys/bluetooth/host/Kconfig.gatt"
config BT_MAX_PAIRED
@ -459,13 +414,6 @@ config BT_DEBUG_KEYS
This option enables debug support for the handling of
Bluetooth security keys.
config BT_DEBUG_L2CAP
bool "Bluetooth L2CAP debug"
depends on BT_CONN
help
This option enables debug support for the Bluetooth
L2ACP layer.
config BT_DEBUG_SMP
bool "Bluetooth Security Manager Protocol (SMP) debug"
depends on BT_HCI_HOST

View file

@ -0,0 +1,68 @@
# Kconfig - Bluetooth ATT/GATT configuration options
#
# Copyright (c) 2019 Intel Corporation
#
# SPDX-License-Identifier: Apache-2.0
#
menu "L2CAP Options"
if BT_HCI_ACL_FLOW_CONTROL
config BT_L2CAP_RX_MTU
int "Maximum supported L2CAP MTU for incoming data"
default 200 if BT_BREDR
default 65 if BT_SMP
default 23
range 65 1300 if BT_SMP
range 23 1300
help
Maximum size of each incoming L2CAP PDU.
endif # BT_HCI_ACL_FLOW_CONTROL
config BT_L2CAP_TX_BUF_COUNT
int "Number of L2CAP TX buffers"
default 3
range 2 255
help
Number of buffers available for outgoing L2CAP packets.
config BT_L2CAP_TX_FRAG_COUNT
int "Number of L2CAP TX fragment buffers"
default 2
range 0 255
help
Number of buffers available for fragments of TX buffers. Warning:
setting this to 0 means that the application must ensure that
queued TX buffers never need to be fragmented, i.e. that the
controller's buffer size is large enough. If this is not ensured,
and there are no dedicated fragment buffers, a deadlock may occur.
In most cases the default value of 2 is a safe bet.
config BT_L2CAP_TX_MTU
int "Maximum supported L2CAP MTU for L2CAP TX buffers"
default 253 if BT_BREDR
default 65 if BT_SMP
default 23
range 65 2000 if BT_SMP
range 23 2000
help
Maximum L2CAP MTU for L2CAP TX buffers.
config BT_L2CAP_DYNAMIC_CHANNEL
bool "L2CAP Dynamic Channel support"
depends on BT_SMP
help
This option enables support for LE Connection oriented Channels,
allowing the creation of dynamic L2CAP Channels.
if BT_DEBUG
config BT_DEBUG_L2CAP
bool "Bluetooth L2CAP debug"
depends on BT_CONN
help
This option enables debug support for the Bluetooth
L2ACP layer.
endif # BT_DEBUG
endmenu