1# Kconfig template file for setting networking log level for
2# various network related components.
3
4# Copyright (c) 2018 Intel Corporation.
5# SPDX-License-Identifier: Apache-2.0
6
7choice "$(module)_LOG_LEVEL_CHOICE"
8	prompt "$(module-str)"
9	default $(module)_LOG_LEVEL_DEFAULT
10	depends on $(module-dep)
11# If we ever get help text macro expansion, then just uncomment
12# the following lines.
13#	help
14#	  $(module-help)
15
16config $(module)_LOG_LEVEL_OFF
17	bool "Off"
18	help
19	  Do not write to log.
20
21config $(module)_LOG_LEVEL_ERR
22	bool "Error"
23	help
24	  Only write to log when NET_ERR or LOG_ERR is used.
25
26config $(module)_LOG_LEVEL_WRN
27	bool "Warning"
28	help
29	  Write to log with NET_WARN or LOG_WRN in addition to previous level.
30
31config $(module)_LOG_LEVEL_INF
32	bool "Info"
33	help
34	  Write to log with NET_INFO or LOG_INF in addition to previous levels.
35
36config $(module)_LOG_LEVEL_DBG
37	bool "Debug"
38	help
39	  Write to log with NET_DBG or LOG_DBG in addition to previous levels.
40
41config $(module)_LOG_LEVEL_DEFAULT
42	bool "Default"
43	help
44	  Use default log level.
45
46endchoice
47
48config $(module)_LOG_LEVEL
49	int
50	default 0 if $(module)_LOG_LEVEL_OFF || !$(module-dep)
51	default 1 if $(module)_LOG_LEVEL_ERR
52	default 2 if $(module)_LOG_LEVEL_WRN
53	default 3 if $(module)_LOG_LEVEL_INF
54	default 4 if $(module)_LOG_LEVEL_DBG
55	default LOG_DEFAULT_LEVEL if $(module)_LOG_LEVEL_DEFAULT
56