Skip to content

Commit

Permalink
tests: secure_storage: psa: enable malloc arena for Mbed TLS
Browse files Browse the repository at this point in the history
The PSA Crypto implementation provided by Mbed TLS generally requires
some amount of heap to function, so enable the arena unconditionally
to make the test compatible with MINIMAL_LIBC configurations where the
arena is disabled by default.

Signed-off-by: Ilya Tagunov <[email protected]>
  • Loading branch information
tagunil authored and carlescufi committed Nov 29, 2024
1 parent b7ffb3d commit 065bd32
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ CONFIG_MAIN_STACK_SIZE=2048
CONFIG_MBEDTLS=y
CONFIG_TEST_RANDOM_GENERATOR=y
CONFIG_TIMER_RANDOM_GENERATOR=y
# PSA Crypto needs some heap, but MINIMAL_LIBC has none by default.
CONFIG_COMMON_LIBC_MALLOC_ARENA_SIZE=2048
CONFIG_MBEDTLS_PSA_CRYPTO_C=y

CONFIG_SECURE_STORAGE=y
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
CONFIG_MBEDTLS=y
CONFIG_TEST_RANDOM_GENERATOR=y
CONFIG_TIMER_RANDOM_GENERATOR=y
# PSA Crypto needs some heap, but MINIMAL_LIBC has none by default.
CONFIG_COMMON_LIBC_MALLOC_ARENA_SIZE=2048
CONFIG_MBEDTLS_PSA_CRYPTO_C=y

# SETTINGS_MAX_VAL_LEN (256) - flags (1) - CONFIG_SECURE_STORAGE_ITS_TRANSFORM_OUTPUT_OVERHEAD (28)
Expand Down

0 comments on commit 065bd32

Please sign in to comment.