Skip to content

Commit fc0603f

Browse files
committed
Revert "boot/zephyr: Add CONFIG_SINGLE_APPLICATION_SLOT_RAM_LOAD"
This reverts commit 249a71d. Signed-off-by: Jamie McCrae <[email protected]>
1 parent 4d0985c commit fc0603f

File tree

3 files changed

+18
-34
lines changed

3 files changed

+18
-34
lines changed

boot/zephyr/CMakeLists.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ zephyr_library_sources(
123123
)
124124
endif()
125125

126-
if(CONFIG_SINGLE_APPLICATION_SLOT OR CONFIG_SINGLE_APPLICATION_SLOT_RAM_LOAD)
126+
if(CONFIG_SINGLE_APPLICATION_SLOT)
127127
zephyr_library_sources(
128128
${BOOT_DIR}/zephyr/single_loader.c
129129
)
@@ -143,7 +143,7 @@ zephyr_library_sources(
143143
)
144144
endif()
145145

146-
if(CONFIG_BOOT_RAM_LOAD OR CONFIG_SINGLE_APPLICATION_SLOT_RAM_LOAD)
146+
if(CONFIG_BOOT_RAM_LOAD)
147147
zephyr_library_sources(
148148
${BOOT_DIR}/bootutil/src/ram_load.c
149149
)
@@ -398,7 +398,7 @@ if(CONFIG_BOOT_SWAP_USING_MOVE)
398398
endif()
399399
endif()
400400

401-
if(NOT CONFIG_SINGLE_APPLICATION_SLOT AND NOT CONFIG_SINGLE_APPLICATION_SLOT_RAM_LOAD)
401+
if(NOT CONFIG_SINGLE_APPLICATION_SLOT)
402402
dt_nodelabel(slot1_flash NODELABEL "slot1_partition")
403403
dt_prop(slot1_size PATH "${slot1_flash}" PROPERTY "reg" INDEX 1)
404404
dt_get_parent(slot1_flash)
@@ -426,7 +426,7 @@ if(CONFIG_BOOT_MAX_IMG_SECTORS_AUTO)
426426
math(EXPR slot_min_sectors "${slot0_size} / ${erase_size_slot0}")
427427
endif()
428428

429-
if(NOT CONFIG_SINGLE_APPLICATION_SLOT AND NOT CONFIG_SINGLE_APPLICATION_SLOT_RAM_LOAD)
429+
if(NOT CONFIG_SINGLE_APPLICATION_SLOT)
430430
if(NOT DEFINED slot1_size)
431431
message(WARNING "Unable to determine size of slot1 partition, cannot calculate minimum sector usage")
432432
elseif(NOT DEFINED erase_size_slot1)

boot/zephyr/Kconfig

Lines changed: 14 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -326,6 +326,19 @@ config BOOT_FIRMWARE_LOADER
326326

327327
endchoice
328328

329+
# Workaround for not being able to have commas in macro arguments
330+
DT_CHOSEN_Z_SRAM := zephyr,sram
331+
332+
if BOOT_RAM_LOAD
333+
config BOOT_IMAGE_EXECUTABLE_RAM_START
334+
hex "Boot image executable ram start"
335+
default $(dt_chosen_reg_addr_hex,$(DT_CHOSEN_Z_SRAM))
336+
337+
config BOOT_IMAGE_EXECUTABLE_RAM_SIZE
338+
int "Boot image executable base size"
339+
default $(dt_chosen_reg_size_int,$(DT_CHOSEN_Z_SRAM),0)
340+
endif
341+
329342
config BOOT_DIRECT_XIP_REVERT
330343
bool "Enable the revert mechanism in direct-xip mode"
331344
depends on BOOT_DIRECT_XIP
@@ -362,27 +375,6 @@ config BOOT_SWAP_SAVE_ENCTLV
362375

363376
endif # !SINGLE_APPLICATION_SLOT
364377

365-
config SINGLE_APPLICATION_SLOT_RAM_LOAD
366-
bool "RAM load for single application slot"
367-
help
368-
If y, the image is loaded to RAM and executed from there. For this reason,
369-
the image has to be linked to be executed from RAM. The address that the
370-
image is copied to is specified using the load-addr argument to the
371-
imgtool.py script which writes it to the image header.
372-
373-
# Workaround for not being able to have commas in macro arguments
374-
DT_CHOSEN_Z_SRAM := zephyr,sram
375-
376-
if BOOT_RAM_LOAD || SINGLE_APPLICATION_SLOT_RAM_LOAD
377-
config BOOT_IMAGE_EXECUTABLE_RAM_START
378-
hex "Boot image executable ram start"
379-
default $(dt_chosen_reg_addr_hex,$(DT_CHOSEN_Z_SRAM))
380-
381-
config BOOT_IMAGE_EXECUTABLE_RAM_SIZE
382-
int "Boot image executable base size"
383-
default $(dt_chosen_reg_size_int,$(DT_CHOSEN_Z_SRAM),0)
384-
endif
385-
386378
config BOOT_ENCRYPTION_SUPPORT
387379
bool
388380
help
@@ -691,7 +683,7 @@ config BOOT_INTR_VEC_RELOC
691683
config UPDATEABLE_IMAGE_NUMBER
692684
int "Number of updateable images"
693685
default 1
694-
range 1 1 if SINGLE_APPLICATION_SLOT || SINGLE_APPLICATION_SLOT_RAM_LOAD
686+
range 1 1 if SINGLE_APPLICATION_SLOT
695687
help
696688
Enables support of multi image update.
697689

boot/zephyr/include/mcuboot_config/mcuboot_config.h

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -118,14 +118,6 @@
118118

119119
#endif /* CONFIG_SINGLE_APPLICATION_SLOT */
120120

121-
#ifdef CONFIG_SINGLE_APPLICATION_SLOT_RAM_LOAD
122-
#define MCUBOOT_RAM_LOAD 1
123-
#define MCUBOOT_IMAGE_NUMBER 1
124-
#define MCUBOOT_SINGLE_APPLICATION_SLOT_RAM_LOAD 1
125-
#define IMAGE_EXECUTABLE_RAM_START CONFIG_BOOT_IMAGE_EXECUTABLE_RAM_START
126-
#define IMAGE_EXECUTABLE_RAM_SIZE CONFIG_BOOT_IMAGE_EXECUTABLE_RAM_SIZE
127-
#endif
128-
129121
#ifdef CONFIG_LOG
130122
#define MCUBOOT_HAVE_LOGGING 1
131123
#endif

0 commit comments

Comments
 (0)