1# Copyright Runtime.io 2018. All rights reserved. 2# Copyright Nordic Semiconductor ASA 2020-2022. All rights reserved. 3# SPDX-License-Identifier: Apache-2.0 4 5# The Kconfig file is dedicated to transport subdirectory of MCUmgr 6# subsystem and provides Kconfig options to control aspects of 7# transport, in general, that are not otherwise controlled by 8# options belonging to transport specifically. 9# 10# Options defined in this file should be prefixed: 11# MCUMGR_TRANSPORT_ -- general transport options; 12# MCUMGR_TRANSPORT_WORKQUEUE -- for workqueue configuration; 13# MCUMGR_TRANSPORT_NETBUF -- for Net Buf related configuration. 14 15config MCUMGR_TRANSPORT_WORKQUEUE_STACK_SIZE 16 int "MCUmgr transport workqueue stack size" 17 default 2048 18 help 19 Stack size of the MCUmgr for transport subsystem work queue. 20 21config MCUMGR_TRANSPORT_WORKQUEUE_THREAD_PRIO 22 int "MCUmgr transport workqueue thread priority" 23 default 3 24 help 25 Scheduling priority of the MCUmgr transport subsystem work queue. 26 27config MCUMGR_TRANSPORT_REASSEMBLY 28 bool 29 help 30 Enable structures and functions needed for packet reassembly by SMP backend. 31 32config MCUMGR_TRANSPORT_NETBUF_COUNT 33 int "Number of mcumgr buffers" 34 default 2 if MCUMGR_TRANSPORT_UDP 35 default 4 36 help 37 The number of net_bufs to allocate for mcumgr. These buffers are 38 used for both requests and responses. 39 40config MCUMGR_TRANSPORT_NETBUF_SIZE 41 int "Size of each mcumgr buffer" 42 default 2048 if MCUMGR_TRANSPORT_UDP 43 default 384 44 help 45 The size, in bytes, of each mcumgr buffer. This value must satisfy 46 the following relation: 47 MCUMGR_TRANSPORT_NETBUF_SIZE >= transport-specific-MTU + transport-overhead 48 In case when MCUMGR_TRANSPORT_SHELL is enabled this value should be set to 49 at least MCUMGR_GRP_SHELL_BACKEND_DUMMY_BUF_SIZE + 32. 50 51config MCUMGR_TRANSPORT_NETBUF_MIN_USER_DATA_SIZE 52 int 53 default 24 if MCUMGR_TRANSPORT_UDP && NET_IPV6 54 default 20 if MCUMGR_TRANSPORT_UDP && MCUMGR_TRANSPORT_UDP_IPV4 && NET_SOCKETS_PACKET 55 default 8 if MCUMGR_TRANSPORT_UDP && MCUMGR_TRANSPORT_UDP_IPV4 56 default 8 if MCUMGR_TRANSPORT_BT 57 default 4 58 help 59 Hidden option to determine minimum user data size. 60 61config MCUMGR_TRANSPORT_NETBUF_USER_DATA_SIZE 62 int "Size of mcumgr buffer user data" 63 range MCUMGR_TRANSPORT_NETBUF_MIN_USER_DATA_SIZE 128 64 default MCUMGR_TRANSPORT_NETBUF_MIN_USER_DATA_SIZE 65 help 66 The size, in bytes, of user data to allocate for each mcumgr buffer. 67 68 Different mcumgr transports impose different requirements for this 69 setting. A value of 4 is sufficient for UART and shell, a value of 8 70 is sufficient for Bluetooth. For UDP, the userdata must be large 71 enough to hold IPv4/IPv6 addresses. 72 73module = MCUMGR_TRANSPORT 74module-str = mcumgr_transport 75source "subsys/logging/Kconfig.template.log_config" 76 77rsource "Kconfig.dummy" 78 79rsource "Kconfig.bluetooth" 80 81rsource "Kconfig.lorawan" 82 83rsource "Kconfig.shell" 84 85rsource "Kconfig.uart" 86 87rsource "Kconfig.udp" 88