Commit Graph

236 Commits (5fc2a5057e408e262f8edfe0480988b746699fc4)

Author SHA1 Message Date
David Garske b8a23b1f81 Allow build-time adjustment of QSPI reference clock and divisor. Eliminate `ZCU102` macro (not needed). Add QSPI init message with ref clock, divisor, bus and IO mode (Poll or DMA). 2024-12-30 15:36:43 +01:00
David Garske f729e419e6 Fixes for QSPI DMA mode. For example reduces QSPI->DDR load of 154MB from 18,228ms to 2,607ms. Changed QSPI to use DMA by default (can force IO mode using `GQSPI_MODE_IO`). 2024-12-30 15:36:43 +01:00
David Garske acb9d832eb Fixes for Xilinx Zynq UltraScale+ MPSoC:
* Fixes to support wolfBoot native make and gcc-arm cross compiler. ZD 18159
* Adjust wolfBoot linker script to not use 0 base, instead use end of DDR - 1MB.
* Fixed QSPI bare-metal driver for multi-sector and read return code.
* Fixed issue with Xilinx XMSS IMAGE_HEADER_SIZE in documentation. It should be 5000 bytes.
* Performance optimizations for QSPI:
  - Allow configuration of SPI clock.
  - Improve GSPI FIFO TX/RX fill.
* Added support for FAST_MEMCPY that supports an aligned 32-bit.
* Added Flattened uImage Tree (FIT) image (FDT format).
* Added Aarch64 support for FDT fixups.
* Added Aarch64 startup to support EL2 with cache/MMU.
* Added documentation about exception levels
* Moved zynqmp registers to header.
* Fix printf uart_writenum "buf" len.
* Updated fdt-parser to support saving off larger data images.
2024-12-30 15:36:43 +01:00
Marco Oliverio 7008f68707 kontron-vx3060-s2: simplify example, add build test, improve docs 2024-12-19 20:12:16 +01:00
Marco Oliverio 834a712350 fsp: move TempRamInitExit and later APIs in stage2
To avoid using Flash memory after TempRamInitExit. This protects against
malicious modification/injection of the flash after Cache-As-RAM is
disabled.
2024-12-19 20:12:16 +01:00
Brett Nicholas 4b8e4b7907 Additional fixes for new keytool features introduced in #521 2024-12-16 19:12:23 +01:00
Brett Nicholas ceffc788dd - support for wolfHSM ML-DSA on simulator and AURIX (DMA only)
- consolidate AURIX scripts into wbaurixtool.sh
- documentation updates
2024-12-16 19:12:23 +01:00
Brett Nicholas 21a4082952
Merge pull request #521 from danielinux/build-keytools-windows
Remove compile-time dependencies from key tools
2024-12-05 16:56:42 -07:00
Daniele Lacamera c3fe5055f6 Fix check on ML_DSA pubkey size at runtime 2024-12-03 15:23:40 +01:00
David Garske 06bbed4280 Peer review feedback. 2024-12-02 19:41:26 +01:00
David Garske 2709af28c2 For Rasp3 don't try and load the .data region (already running from RAM) by setting NO_XIP. 2024-12-02 19:41:26 +01:00
David Garske d007c9af08 Initial support for NXP LS1028A. Booting into OCRAM app. Updates to ARMv8 startup. 2024-12-02 19:41:26 +01:00
Daniele Lacamera adb020470a Change header size for delta test to fit base hash 2024-11-21 15:59:57 +01:00
Brett Nicholas 78e4275f99 Initial wolfHSM support for simulator and AURIX TC3xx 2024-11-13 09:52:49 +01:00
Daniele Lacamera cc447ea879 Support for hybrid authentication (2 ciphers) 2024-10-30 13:17:06 +01:00
Daniele Lacamera 95d58244a9 SAMA5D3: Hal fixes, add DBGU, enable ARM_ASM 2024-10-14 10:14:48 +02:00
jordan b97abd4ace Add ML-DSA support. 2024-10-14 10:13:52 +02:00
Daniele Lacamera 855b968d75 Activate debug in sim_tpm tests 2024-10-11 14:49:43 +02:00
David Garske d803a20217 Switch to using IPC for communicating state. Prevents possible hard fault on network core reset. Cleanup make logic for using custom partition id (WOLFBOOT_PART_ID). On net update allow app core to continue booting if synchronization is enabled. 2024-10-11 10:29:59 +02:00
David Garske 7260ecbcbb Added tests for delta updates. Added logging for delta version errors. Added `SIGN_OPTIONS_EXTRA`. 2024-10-11 10:29:59 +02:00
David Garske f6c12839f3 Enable ECC384 and SHA384. Fix sleep_us. Add Cortex-M hard-fault handler support. 2024-10-11 10:29:59 +02:00
David Garske ab59175427 Fix for nRF5340 `uart_write` issue with memchr args, which caused occasional corrupt characters to be printed. Improve core state description in logging. Enabled network core test app GPIO work on `LED2 P0.29`. 2024-10-11 10:29:59 +02:00
David Garske 29a30a6efc Enable backup for network core, so the last known image will still be in shared ram. Fixed bug with swap offset on network core external memory map and "erase" init. 2024-10-11 10:29:59 +02:00
David Garske 8489736eac Fixed and improved erase of remainder of partition logic and logging. Added support for nRF5340 core synchronization (`NRF_SYNC_CORES`). Added test for `WOLFBOOT_FLASH_MULTI_SECTOR_ERASE`. 2024-10-11 10:29:59 +02:00
David Garske 832ac479c3 Example for using custom UART port/pin. Additional debug output on erase of unused flash sectors. 2024-10-11 10:29:59 +02:00
David Garske eb175cdfec Switch network core to use external flash HAL, but map to shared memory. Allows using update_flash logic including encrypted and delta updates. 2024-10-11 10:29:59 +02:00
David Garske f2b929affd QSPI Power control (active low). 2024-10-11 10:29:59 +02:00
David Garske 2cf70f0dbd Fix for the `set_trailer_at` with external flash to use 32-bit write using cached value (Many QSPI hardware peripherals do not support a single byte write). Fix delta build error with DISABLE_BACKUP. Added tests for updating both cores in build_flash.sh. 2024-10-11 10:29:59 +02:00
David Garske 8a9fbe5674 Improve network core firmware update. 2024-10-11 10:29:59 +02:00
David Garske 6db7de6a75 Support for the Nordic nRF5340 (application and network cores):
* Added nRF5340 driver support for Clock, Internal Flash (NVMC), GPIO, SPU, OTP, UART, SPI, QSPI and IPC.
* Added support for updating the network core (Sign using "--id 2")
* Cleanup the nRF52 port
* Improved external QSPI and internal Flash tests and logging.
* Improved internal printf support for formatter length.
2024-10-11 10:29:59 +02:00
Daniele Lacamera c80937bdea Addressed reviewer's comments 2024-10-02 10:25:36 +02:00
Daniele Lacamera 6080cc215c [SAMA5D3] Add build test, expand Target.md 2024-09-30 14:06:23 +02:00
Daniele Lacamera 294d62d0c6 [SAMA5D3] Support for DDR2 memory on -xplained 2024-09-30 14:06:23 +02:00
Daniele Lacamera 76920599b3 [SAMA5D3] Added test-app, moved to SP_ASM 2024-09-30 14:06:17 +02:00
Daniele Lacamera 888d538760 [SAMA5D3] Nand flash driver 2024-09-30 14:06:17 +02:00
Hideki Miyazaki bf88d15ea6 add raspi3b uart 2024-09-02 14:02:36 +02:00
Daniel Fedai Larsen 7ddbf8386d Set RAM_CODE=1 for all i.MX RT target example configs 2024-08-22 10:40:49 +02:00
David Garske 9e17315d49 Fixes for building wolfBoot with XMSS/LMS. 2024-08-14 18:06:12 +02:00
David Garske be169145e2 Fixes for Zynqmp QSPI sizes on ZCU102. Fix for XMSS/LMS on Windows mingw with fopen binary mode. 2024-08-14 18:06:12 +02:00
David Garske 3687851f75 Xilinx zynqmp documentation cleanups. Fixes for building with Eclipse wildcard .c include pains. 2024-08-14 18:06:12 +02:00
Daniele Lacamera 30a1f67e43
Added 32bit simulator via TARGET=sim FORCE_32BIT=1 (#485)
* Added 32bit simulator via TARGET=sim FORCE_32BIT=1

Tests can now run on 32bit simulator (e.g. to match XMALLOC fixed
sizes with sp_math and WOLFBOOT_SMALL_STACK).

* Added draft for new workflow: test simulator with different memory config

* Fix 64bit, SMALL_STACK xmalloc sizes

* Test defaults to SPMATH

* Fixed test: defaults to spmath. Added RSA tests (failing)

* Fixed RSA allocation sizes for 64bit build

* Added 64bit fastmath test (failing)

* Fixed ecc_point size for 64bit builds (FASTMATH)

* simulator config: use SPMATH by default

* Attempt to fix i386 libc dep in workflow

* Added HUGE_STACK to silence warning in FASTMATH+RSA4096 tests
2024-08-09 06:46:15 -07:00
Daniel Fedai Larsen e0126ff4e8 Add support for building for HAB for i.MX RT targets 2024-07-22 08:14:33 +02:00
David Garske f4935268fa
Merge pull request #460 from danielinux/stm32u5_spi
[QSPI] Fixed registers and pin config on STM32U5
2024-07-19 07:33:01 -07:00
David Garske 3444c47fdb * Added support for RX65N and RX72N with native Makefile and RX ELF GCC compiler.
* Added initialization of the clocks and UART driver.
   - wolfBoot uses on chip high speed oscillator (HOCO) at (120MHz RX65N and 240Mhz for RX72N).
* Added RX RSPI and QSPI driver support with external SPI flash
* Improve documentation and fix spelling errors.
* Added .srec (s-record) format support
* Added RX TSIP support for ECDSA (requires https://github.com/wolfSSL/wolfssl/pull/7685).
* Allow custom implementation of `get_trailer_at`, `set_trailer_at` and `set_partition_magic` using `CUSTOM_PARTITION_TRAILER`
2024-07-17 06:08:31 +02:00
David Garske ace95cc2dc Added instructions for STM32H5 demo to `docs/flash-OTP.md`. 2024-07-09 10:27:52 -07:00
David Garske 7b5012b374 Cleanups from testing. 2024-07-05 09:44:59 -07:00
Daniel Pouzzner 441200f469 fix: support DEBUG=0 build
* build lib/wolfssl/wolfcrypt/src/logging.o unconditionally,
* gate debug printing in do_tpm_selftest() appropriately,
* initialize top_address in src/boot_x86_fsp.c:start() to fix -Wmaybe-uninitialized,
* and add __attribute__((used)) to static src/x86/exceptions.c:common_exception_handler() and _timer_handler() implementations to accommodate asm-only calling;
* fix parallel make: add dependency of stage1/loader_stage1.bin on wolfboot.elf.
* add -ffreestanding -static flags to avoid gcc compiler optimize strings functions

Co-authored-by: Daniel Pouzzner <douzzer@wolfssl.com>
2024-06-19 09:47:06 +02:00
David Garske 971cbe0ecc
Merge pull request #449 from danielinux/stm32h7_otp
Support for OTP Flash as trust anchor for keystore
2024-05-24 16:34:29 -07:00
Marco Oliverio bf55ac1ab5 x86_efi: fixes
- do not use a custom section for the keystore as it will not be loaded in the
UEFI env
- remove and disable WOLFBOOT_LOAD_ADDRESS
- copy .rodata from .elf to .efi as the new version of gnu-efi ld scripts do
not merge .rodata into .data anymore
- fix typo in compile_efi_linux.sh
2024-05-20 17:03:16 +02:00
Daniele Lacamera 84282c9bb1 Added full setup on stm32h5 2024-05-20 11:00:32 +02:00