This feature has been deleted in Zephyr upstream. The project won't
build with this line in anymore due to Kconfig errors.
Signed-off-by: Marti Bolivar <marti@foundries.io>
The `--included-header` was "mandatory" when using imgtool with firmware
images generated by the Zephyr build system and it was a source of
issues when it was forgotten. This removes `--included-header` and adds
a new parameter `--pad-header` with inverted semantics, to be used only
when a zeroed header is required to be added to the firmware image.
Signed-off-by: Fabio Utzig <utzig@apache.org>
Add the new `--slot-size` and make `--pad` a bool flag, to allow
checking that firmware fits in the slot without overflowing into the
trailer region even when no padding was requested.
Fixes#241
Signed-off-by: Fabio Utzig <utzig@apache.org>
Handle CONFIG_BOOT_UPGRADE_ONLY in mcuboot_config.h, and switch the
release test Makefile to using an OVERLAY_CONFIG fragment.
This removes the last user of the Makefile BOOTLOADER_CONFIG variable,
so delete it as well.
Signed-off-by: Marti Bolivar <marti@opensourcefoundries.com>
Handle CONFIG_BOOT_VALIDATE_SLOT0 in mcuboot_config.h, and switch to
setting it with an OVERLAY_CONFIG fragment in the test Makefile.
Signed-off-by: Marti Bolivar <marti@opensourcefoundries.com>
Handle the CONFIG_BOOT_SIGNATURE_TYPE_xxx values in Zephyr's
mcuboot_config.h by converting them into the platform-agnostic MCUboot
definitions.
This requires some changes to the way the release test Makefile is
structured, since Kconfig symbols cannot be set from the command line.
Instead, use the OVERLAY_CONFIG feature of the Zephyr build system,
which allows specifying extra fragments to merge into the final
.config. (This is an orthogonal mechanism to setting CONF_FILE; it is
used by Zephyr's CI script sanitycheck to add additional fragments, so
it's appropriate for use by MCUboot's testing scripts as well.)
We additionally need to move to a single prj.conf file due to a
dependency issue. We can no longer determine CONF_FILE from the
signature type, since that is now determined from the final .config or
autoconf.h, which is a build output that depends on CONF_FILE.
To move to a single prj.conf:
- delete prj-p256.conf and adjust prj.conf to serve both signature types
- add a top-level mbedTLS configuration file which dispatches to
the right sub-header depending on the key type
- as a side effect, have the simulator pick the right config file
depending on the case
This fixes and cleans up quite a bit of the signature type handling,
which had become something of a mess over time. For example, it fixes
a bug in ECDSA mode's configuration that wasn't actually selecting
config-asn1.h, and forces the simulator to use the same mbedTLS
configuration file as builds for real hardware.
Finally, we also have to move the mbedTLS vs. TinyCrypt choice into
mcuboot_config.h at the same time as well, since CMakeLists.txt was
making that decision based on the signature type.
Signed-off-by: Marti Bolivar <marti@opensourcefoundries.com>
Instead of manually setting the text section offset and the overlay
file, use the now readily available BOOTLOADER_MCUBOOT Kconfig option to
provide that automatically.
Signed-off-by: Carles Cufi <carles.cufi@nordicsemi.no>
Enhance the test runner so that it can verify the output of the tests by
itself. This needs the console to be logged to a file, but otherwise
works the same as the current test runner.
Also, the build results are placed in a log file, so that it is easier
to see what is happening.
Signed-off-by: David Brown <david.brown@linaro.org>
hello-world is serving as a sample application and should therefore
not define a default board as Zephyr samples do not either.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
The documentation claims that one can place per-board overlay files in
the boards/ directory. But no such support has been implemented.
Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
It's onerous to work through the tests in docs/testplan-zephyr.md by
hand. Add a script which takes the thinking out of it.
Signed-off-by: Marti Bolivar <marti@opensourcefoundries.com>
Instead of a bunch of patches that tend to become conflicting, use the
newly parameterized Makefile to make all of the test plans into make
targets. Update the instructions to match this.
Signed-off-by: David Brown <david.brown@linaro.org>
This is a minimal example application that works on various boards,
without target-specific definitions, device tree overlay files, etc.
It's been tested on frdm_k64f, 96b_carbon, and 96b_nitrogen.
Signed-off-by: Marti Bolivar <marti.bolivar@linaro.org>
Previous commits added the full.bin target. Add a flash_full target to
be able to flash this full image for testing.
Signed-off-by: David Brown <david.brown@linaro.org>
This full.bin target demonstrates how to assemble all of the images into
a single file which can be flashed to the device. As it is, it will
then boot into the first "primary" image. The second image will be
present, but will not ever be run.
Signed-off-by: David Brown <david.brown@linaro.org>
Most of the meat of this is in the Makefile, which is able to build the
bootloader, and two small applications, along with instructions on how
to load these into flash and test that upgrades work.
JIRA: MCUB-62
Signed-off-by: David Brown <david.brown@linaro.org>