Skip to content

Commit e2c5377

Browse files
committed
New ECC curve spec size (fixes SMALL_STACK + ECC)
1 parent 6cfa152 commit e2c5377

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/xmalloc.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ struct xmalloc_slot {
7070
/* SP MATH */
7171
#ifdef WOLFBOOT_SIGN_ECC256
7272
#define MP_SCHEME "SP ECC256"
73-
#define MP_CURVE_SPECS_SIZE (76)
73+
#define MP_CURVE_SPECS_SIZE (72)
7474
#ifdef WOLFSSL_SP_ARM_CORTEX_M_ASM
7575
#define MP_POINT_SIZE (196)
7676
#define MP_DIGITS_BUFFER_SIZE_0 (MP_DIGIT_SIZE * 18 * 8)
@@ -85,7 +85,7 @@ struct xmalloc_slot {
8585
#endif /* WOLFBOOT_SIGN_ECC256 */
8686
#ifdef WOLFBOOT_SIGN_ECC384
8787
#define MP_SCHEME "SP ECC384"
88-
#define MP_CURVE_SPECS_SIZE (108)
88+
#define MP_CURVE_SPECS_SIZE (104)
8989
#ifdef WOLFSSL_SP_ARM_CORTEX_M_ASM
9090
#define MP_POINT_SIZE (292)
9191
#define MP_DIGITS_BUFFER_SIZE_0 (MP_DIGIT_SIZE * 18 * 12)
@@ -101,7 +101,7 @@ struct xmalloc_slot {
101101
#endif /* WOLFBOOT_SIGN_ECC384 */
102102
#ifdef WOLFBOOT_SIGN_ECC521
103103
#define MP_SCHEME "SP ECC521"
104-
#define MP_CURVE_SPECS_SIZE (148)
104+
#define MP_CURVE_SPECS_SIZE (144)
105105
#ifdef WOLFSSL_SP_ARM_CORTEX_M_ASM
106106
#define MP_POINT_SIZE (412)
107107
#define MP_DIGITS_BUFFER_SIZE_0 (MP_DIGIT_SIZE * 18 * 17)

0 commit comments

Comments
 (0)