Skip to content

Commit cd0e262

Browse files
authored
Add GN arg to enable logging of node Id in exchange context (#32670)
* Add gn arg to enable node id logging * Remove unused define
1 parent e1d93fa commit cd0e262

File tree

3 files changed

+5
-10
lines changed

3 files changed

+5
-10
lines changed

src/lib/core/BUILD.gn

+1
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ buildconfig_header("chip_buildconfig") {
4848
"CHIP_AUTOMATION_LOGGING=${chip_automation_logging}",
4949
"CHIP_PW_TOKENIZER_LOGGING=${chip_pw_tokenizer_logging}",
5050
"CHIP_USE_PW_LOGGING=${chip_use_pw_logging}",
51+
"CHIP_EXCHANGE_NODE_ID_LOGGING=${chip_exchange_node_id_logging}",
5152
"CHIP_CONFIG_SHORT_ERROR_STR=${chip_config_short_error_str}",
5253
"CHIP_CONFIG_ENABLE_ARG_PARSER=${chip_config_enable_arg_parser}",
5354
"CHIP_TARGET_STYLE_UNIX=${chip_target_style_unix}",

src/lib/core/CHIPConfig.h

-10
Original file line numberDiff line numberDiff line change
@@ -461,16 +461,6 @@
461461
#define CHIP_CONFIG_ENABLE_CONDITION_LOGGING 0
462462
#endif // CHIP_CONFIG_ENABLE_CONDITION_LOGGING
463463

464-
/**
465-
* @def CHIP_EXCHANGE_NODE_ID_LOGGING
466-
*
467-
* @brief
468-
* If asserted (1), enable logging of node IDs in exchange context.
469-
*/
470-
#ifndef CHIP_EXCHANGE_NODE_ID_LOGGING
471-
#define CHIP_EXCHANGE_NODE_ID_LOGGING 0
472-
#endif // CHIP_EXCHANGE_NODE_ID_LOGGING
473-
474464
/**
475465
* @def CHIP_CONFIG_TEST
476466
*

src/lib/core/core.gni

+4
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,10 @@ declare_args() {
4747
# Configure chip logging to output through pigweed logging.
4848
chip_use_pw_logging = false
4949

50+
# Enable logging of node Id in exchange context log messages.
51+
# Will cause increase in code size and is therefore disabled by default.
52+
chip_exchange_node_id_logging = false
53+
5054
# Configure chip logging to output through external logging implementation.
5155
# External code will need to provide implementation for CHIP log output
5256
# function (LogV), which is defined in "src/platform/logging/LogV.h".

0 commit comments

Comments
 (0)