File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed
subsys/mgmt/mcumgr/grp/os_mgmt Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -194,8 +194,6 @@ config MCUMGR_GRP_OS_INFO_BUILD_DATE_TIME
194
194
195
195
endif
196
196
197
- if BOOTLOADER_MCUBOOT
198
-
199
197
config MCUMGR_GRP_OS_BOOTLOADER_INFO
200
198
bool "Bootloader information"
201
199
help
@@ -209,8 +207,6 @@ config MCUMGR_GRP_OS_BOOTLOADER_INFO_HOOK
209
207
Supports adding custom responses to the bootloader info command by using registered
210
208
callbacks. Data can be appended to the struct provided in the callback.
211
209
212
- endif # BOOTLOADER_MCUBOOT
213
-
214
210
module = MCUMGR_GRP_OS
215
211
module-str = mcumgr_grp_os
216
212
source "subsys/logging/Kconfig.template.log_config"
Original file line number Diff line number Diff line change @@ -423,6 +423,7 @@ os_mgmt_mcumgr_params(struct smp_streamer *ctxt)
423
423
424
424
#if defined(CONFIG_MCUMGR_GRP_OS_BOOTLOADER_INFO )
425
425
426
+ #if defined(CONFIG_BOOTLOADER_MCUBOOT )
426
427
#if defined(CONFIG_MCUBOOT_BOOTLOADER_MODE_SINGLE_APP )
427
428
#define BOOTLOADER_MODE MCUBOOT_MODE_SINGLE_SLOT
428
429
#elif defined(CONFIG_MCUBOOT_BOOTLOADER_MODE_SWAP_SCRATCH )
@@ -440,6 +441,7 @@ os_mgmt_mcumgr_params(struct smp_streamer *ctxt)
440
441
#else
441
442
#define BOOTLOADER_MODE -1
442
443
#endif
444
+ #endif
443
445
444
446
static int
445
447
os_mgmt_bootloader_info (struct smp_streamer * ctxt )
@@ -485,6 +487,7 @@ os_mgmt_bootloader_info(struct smp_streamer *ctxt)
485
487
#endif
486
488
487
489
/* If no parameter is recognized then just introduce the bootloader. */
490
+ #if defined(CONFIG_BOOTLOADER_MCUBOOT )
488
491
if (decoded == 0 ) {
489
492
ok = zcbor_tstr_put_lit (zse , "bootloader" ) &&
490
493
zcbor_tstr_put_lit (zse , "MCUboot" );
@@ -499,7 +502,9 @@ os_mgmt_bootloader_info(struct smp_streamer *ctxt)
499
502
ok = ok && zcbor_tstr_put_lit (zse , "no-downgrade" ) &&
500
503
zcbor_bool_encode (zse , & (bool ){true});
501
504
#endif
502
- } else {
505
+ } else
506
+ #endif
507
+ {
503
508
return OS_MGMT_ERR_QUERY_YIELDS_NO_ANSWER ;
504
509
}
505
510
You can’t perform that action at this time.
0 commit comments