1# Copyright (c) 2016 Intel Corporation.
2# SPDX-License-Identifier: Apache-2.0
3
4menuconfig NET_L2_IEEE802154
5	bool "IEEE 802.15.4 Radio"
6	select NET_L2_PHY_IEEE802154
7	help
8	  Add support for low rate WPAN IEEE 802.15.4 technology.
9
10if NET_L2_IEEE802154
11
12config NET_L2_IEEE802154_MGMT
13	bool
14	select NET_MGMT
15	select NET_MGMT_EVENT
16
17module = NET_L2_IEEE802154
18module-dep = NET_LOG
19module-str = Log level for IEEE 802.15.4
20module-help = Enables IEEE 802.15.4 code to output debug messages.
21source "subsys/net/Kconfig.template.log_config.net"
22
23config NET_DEBUG_L2_IEEE802154_DISPLAY_PACKET
24	bool "IEEE 802.15.4 packet display"
25	depends on NET_LOG
26	help
27	  Enable printing out in/out 802.15.4 packets. This is extremely
28	  verbose, do not enable this unless you know what you are doing.
29
30choice
31	prompt "Which packet do you want to print-out?"
32	default NET_DEBUG_L2_IEEE802154_DISPLAY_PACKET_FULL
33	depends on NET_DEBUG_L2_IEEE802154_DISPLAY_PACKET
34
35config NET_DEBUG_L2_IEEE802154_DISPLAY_PACKET_FULL
36	bool "Print-out both RX and TX packets"
37	help
38	  This will print-out both received and transmitted packets.
39
40config NET_DEBUG_L2_IEEE802154_DISPLAY_PACKET_RX
41	bool "Print-out only RX packets"
42	help
43	  This will print-out received packets only.
44
45config NET_DEBUG_L2_IEEE802154_DISPLAY_PACKET_TX
46	bool "Print-out only TX packets"
47	help
48	  This will print-out transmitted packets only.
49
50endchoice
51
52config NET_L2_IEEE802154_ACK_REPLY
53	bool
54	select DEPRECATED
55
56choice
57	prompt "Device features level support"
58	default NET_L2_IEEE802154_RFD
59	help
60	  Select which features level you want on the device. Depending on it,
61	  the device might expose more or less 802.15.4 protocol features.
62	  Only RFD is supported for now.
63
64config NET_L2_IEEE802154_RFD
65	bool "Support Reduced Functionality Device level"
66	select NET_L2_IEEE802154_MGMT
67	help
68	  This is the level for PAN device, not PAN coordinator. This will make
69	  possible to do active and/or passive scans, as well as associating
70	  and disassociating to/from a PAN. Current support is very fragile,
71	  thus it is not set as the default level.
72endchoice
73
74config NET_L2_IEEE802154_SHELL
75	bool "IEEE 802.15.4 shell module"
76	select SHELL
77	depends on NET_L2_IEEE802154_RFD
78	help
79	  This can be used for testing 15.4 through the console via exposing
80	  a shell module named "ieee15_4".
81
82config NET_L2_IEEE802154_FRAGMENT
83	bool "802.15.4 fragmentation support"
84	default y
85	depends on NET_6LO
86	help
87	  If IPv6 packets size more than 802.15.4 MTU, packet is fragmented
88	  and reassemble incoming packets according to RFC4944/6282.
89
90if NET_L2_IEEE802154_FRAGMENT
91
92config NET_L2_IEEE802154_FRAGMENT_REASS_CACHE_SIZE
93	int "IEEE 802.15.4 Reassembly cache size"
94	default 1
95	help
96	  Simultaneously reassemble 802.15.4 fragments depending on
97	  cache size.
98
99config NET_L2_IEEE802154_REASSEMBLY_TIMEOUT
100	int "IEEE 802.15.4 Reassembly timeout in seconds"
101	default 5
102	range 1 60
103	help
104	  Reassembly timer will start as soon as first packet received
105	  from peer. Reassembly should be finished within a given time.
106	  Otherwise all accumulated fragments are dropped.
107
108endif # NET_L2_IEEE802154_FRAGMENT
109
110config NET_L2_IEEE802154_SECURITY
111	bool "IEEE 802.15.4 security [EXPERIMENTAL]"
112	select EXPERIMENTAL
113	help
114	  Enable 802.15.4 frame security handling, in order to bring data
115	  confidentiality and authenticity. The implementation is incomplete
116	  (only implicit key mode, no key/device specific state, incoming
117	  and outgoing security procedures only partially implemented, etc.).
118	  Therefore the feature is to be considered EXPERIMENTAL work in
119	  progress.
120
121config NET_L2_IEEE802154_SECURITY_CRYPTO_DEV_NAME
122	string "Crypto device name used for <en/de>cryption"
123	default ""
124	depends on NET_L2_IEEE802154_SECURITY
125	help
126	  This option should be used to set the crypto device name that
127	  IEEE 802.15.4 soft MAC will use to run authentication, encryption and
128	  decryption operations on incoming/outgoing frames.
129
130source "subsys/net/l2/ieee802154/Kconfig.radio"
131
132endif
133