Skip to content

Commit c42c852

Browse files
committed
[nrf fromlist] modules: mbedtls: add promptless CONFIG_MBEDTLS_PSA_CRYPTO_STORAGE_C
Add a Kconfig option to match the Mbed TLS define instead of defining it based on CONFIG_SECURE_STORAGE. This gives more flexibility regarding the potential re-definition of the CONFIG_MBEDTLS_PSA_CRYPTO_STORAGE_C Kconfig option. Signed-off-by: Tomi Fontanilles <[email protected]> Upstream PR #: 85735 (cherry picked from commit 2313a8d40c1e2b25865197d246625e9940e2f506) Signed-off-by: Tomi Fontanilles <[email protected]>
1 parent ff381f0 commit c42c852

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

modules/mbedtls/Kconfig.tls-generic

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -613,6 +613,9 @@ config MBEDTLS_PSA_P256M_DRIVER_RAW
613613
Warning: Usage of this Kconfig option is prohibited in Zephyr's codebase.
614614
Users can enable it in case of very memory-constrained devices, but be aware that the p256-m interface is absolutely not guaranted to remain stable over time.
615615

616+
config MBEDTLS_PSA_CRYPTO_STORAGE_C
617+
bool
618+
616619
config MBEDTLS_PSA_STATIC_KEY_SLOTS
617620
bool "Use statically allocated key buffers to store key material"
618621
default y if !MBEDTLS_ENABLE_HEAP

modules/mbedtls/configs/config-tls-generic.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -482,7 +482,7 @@
482482
#define MBEDTLS_PSA_P256M_DRIVER_ENABLED
483483
#endif
484484

485-
#if defined(CONFIG_SECURE_STORAGE)
485+
#if defined(CONFIG_MBEDTLS_PSA_CRYPTO_STORAGE_C)
486486
#define MBEDTLS_PSA_CRYPTO_STORAGE_C
487487
#endif
488488

subsys/secure_storage/Kconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
menuconfig SECURE_STORAGE
55
bool "Secure storage subsystem"
66
depends on !BUILD_WITH_TFM
7+
select MBEDTLS_PSA_CRYPTO_STORAGE_C
78
select EXPERIMENTAL
89
help
910
The secure storage subsystem provides an implementation of the PSA Secure Storage API

0 commit comments

Comments
 (0)