[ 
https://issues.apache.org/jira/browse/MYNEWT-523?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15783859#comment-15783859
 ] 

Marko Kiiskila commented on MYNEWT-523:
---------------------------------------

Next I'll take a look at what's going on with ECC.

Here's nrf52dk bootloader with RSA, BTW.
I haven't modified all the BSPs for optimal size, but at least this should show 
how to gain some space back.

objsize
   text    data     bss     dec     hex filename
  15216      60    4376   19652    4cc4 
/Users/marko/src2/incubator-mynewt-blinky/bin/targets/boot_nrf52/app/apps/boot/boot.elf

And here's the same without RSA:
objsize
   text    data     bss     dec     hex filename
   7620      56    4376   12052    2f14 
/Users/marko/src/incubator-mynewt-blinky/bin/targets/boot_nrf52/app/apps/boot/boot.elf

This is starting to look better; bootloader should be < 8k.

Again, you'll need to disable the peripherals which are not needed.
targets/boot_nrf52
    app=@apache-mynewt-core/apps/boot
    bsp=@apache-mynewt-core/hw/bsp/nrf52dk
    build_profile=optimized
    syscfg=TIMER_0=0:UART_0=0


I did mention earlier that we need a different HW initialization depending on 
whether bsp_init() gets called from bootloader or not. Having special target 
variables might not be the optimal way to solve this. Good ideas around this 
would be appreciated :)


> boot - boot loader with BOOTUTIL_SIGN_RSA/EC is too large
> ---------------------------------------------------------
>
>                 Key: MYNEWT-523
>                 URL: https://issues.apache.org/jira/browse/MYNEWT-523
>             Project: Mynewt
>          Issue Type: Bug
>          Components: Bootloader
>    Affects Versions: v1_0_0_beta1
>            Reporter: Simon Ratner
>            Assignee: Marko Kiiskila
>
> With image signatures enabled, boot loader weighs in at ~27kB, which is too 
> big for both the nrf51 and nrf52. Even disabling most of mbedtls and only 
> keeping minimum required features comes to 25kB(EC) / 20kB(RSA).
> Without signature support, boot loader is ~12kB.
> Maybe consider secp256r1 with tinycrypt as an option for smaller footprint?



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to