diff --git a/include/ox_aes.h b/include/ox_aes.h index b702e368c..f09cf751d 100644 --- a/include/ox_aes.h +++ b/include/ox_aes.h @@ -76,8 +76,8 @@ * @details Such container should be initialized with #cx_aes_init_key_no_throw. */ struct cx_aes_key_s { - size_t size; ///< key size - uint8_t keys[32]; ///< key value + uint32_t size; ///< key size + uint8_t keys[32]; ///< key value }; /** Convenience type. See #cx_aes_key_s. */ typedef struct cx_aes_key_s cx_aes_key_t; diff --git a/lib_cxng/include/lcx_cipher.h b/lib_cxng/include/lcx_cipher.h index e007031e1..415ed58b2 100644 --- a/lib_cxng/include/lcx_cipher.h +++ b/lib_cxng/include/lcx_cipher.h @@ -42,8 +42,8 @@ typedef enum { /** Generic key structure */ typedef struct { - unsigned int size; - unsigned char keys[32]; + uint32_t size; + uint8_t keys[32]; } cipher_key_t; /** Base cipher information */ diff --git a/lib_standard_app/main.c b/lib_standard_app/main.c index e82647eac..a04b360e2 100644 --- a/lib_standard_app/main.c +++ b/lib_standard_app/main.c @@ -40,7 +40,7 @@ WEAK void __attribute__((noreturn)) app_exit(void) os_sched_exit(-1); } -static void common_app_init(void) +WEAK void common_app_init(void) { UX_INIT(); @@ -55,7 +55,7 @@ static void common_app_init(void) #endif // HAVE_BLE } -static void standalone_app_main(void) +WEAK void standalone_app_main(void) { #ifdef HAVE_SWAP G_called_from_swap = false; @@ -102,7 +102,7 @@ static void standalone_app_main(void) } #ifdef HAVE_SWAP -static void library_app_main(libargs_t *args) +WEAK void library_app_main(libargs_t *args) { BEGIN_TRY { @@ -152,7 +152,7 @@ static void library_app_main(libargs_t *args) } #endif // HAVE_SWAP -__attribute__((section(".boot"))) int main(int arg0) +WEAK __attribute__((section(".boot"))) int main(int arg0) { // exit critical section __asm volatile("cpsie i"); diff --git a/target/nanos2/script.ld b/target/nanos2/script.ld index c775ab1f0..94b0b2e18 100644 --- a/target/nanos2/script.ld +++ b/target/nanos2/script.ld @@ -26,7 +26,7 @@ MEMORY FLASH (rx) : ORIGIN = 0xc0de0000, LENGTH = 400K DATA (r) : ORIGIN = 0xc0de0000, LENGTH = 400K - SRAM (rwx) : ORIGIN = 0xda7a0000, LENGTH = 30K + SRAM (rwx) : ORIGIN = 0xda7a0000, LENGTH = 44K } PAGE_SIZE = 512; diff --git a/target/nanox/script.ld b/target/nanox/script.ld index 44cd6d66f..cfca329f1 100644 --- a/target/nanox/script.ld +++ b/target/nanox/script.ld @@ -26,7 +26,7 @@ MEMORY FLASH (rx) : ORIGIN = 0xc0de0000, LENGTH = 400K DATA (r) : ORIGIN = 0xc0de0000, LENGTH = 400K - SRAM (rwx) : ORIGIN = 0xda7a0000, LENGTH = 30K + SRAM (rwx) : ORIGIN = 0xda7a0000, LENGTH = 28K } PAGE_SIZE = 256;