From 7b5012b37477a10ef3d8fc08e56341e233499879 Mon Sep 17 00:00:00 2001 From: David Garske Date: Fri, 5 Jul 2024 09:44:59 -0700 Subject: [PATCH] Cleanups from testing. --- config/examples/stm32u5.config | 2 ++ docs/Targets.md | 11 +++++------ hal/spi/spi_drv_stm32.h | 2 ++ 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/config/examples/stm32u5.config b/config/examples/stm32u5.config index 57638bb8..f3571f9c 100644 --- a/config/examples/stm32u5.config +++ b/config/examples/stm32u5.config @@ -11,6 +11,8 @@ NO_ASM?=0 NO_MPU=1 EXT_FLASH?=0 SPI_FLASH?=0 +QSPI_FLASH?=0 +OCTOSPI_FLASH?=0 ALLOW_DOWNGRADE?=0 NVM_FLASH_WRITEONCE?=1 WOLFBOOT_VERSION?=1 diff --git a/docs/Targets.md b/docs/Targets.md index 53ace4a8..dad9c4eb 100644 --- a/docs/Targets.md +++ b/docs/Targets.md @@ -357,9 +357,7 @@ ST-LINK_gdbserver -d -cp /opt/st/stm32cubeide_1.3.0/plugins/com.st.stm32cube.ide Max OS/X: ```sh -sudo ln -s /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.stlink-gdb-server.macos64_1.6.0.202101291314/tools/bin/native/mac_x64/libSTLinkUSBDriver.dylib /usr/local/lib/libSTLinkUSBDriver.dylib - -/Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.stlink-gdb-server.macos64_1.6.0.202101291314/tools/bin/ST-LINK_gdbserver -d -cp ./Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.macos64_1.6.0.202101291314/tools/bin -e -r 1 -p 3333 +/Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.stlink-gdb-server.macos64_2.1.300.202403291623/tools/bin/ST-LINK_gdbserver -d -cp /Applications/STM32CubeIDE.app/Contents/Eclipse/plugins/com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.macos64_2.1.201.202404072231/tools/bin -e -r 1 -p 3333 ``` Win: @@ -374,6 +372,7 @@ wolfBoot has a .gdbinit to configure add-symbol-file test-app/image.elf ``` + ## STM32L0 Example 192KB partitioning on STM32-L073 @@ -2214,8 +2213,8 @@ Note: ### Running on 64-bit QEMU Two example configuration files are available: `config/examples/x86_fsp_qemu.config` and `config/examples/x86_fsp_qemu_seal.config`. -Both will try to load a 64bit ELF/Multiboot2 payload from the emulated sata drive. -The second one is an example of configuration that also do measure boot and seal/unseal secrets using a TPM. +Both will try to load a 64bit ELF/Multiboot2 payload from the emulated sata drive. +The second one is an example of configuration that also do measure boot and seal/unseal secrets using a TPM. A test ELF/Multiboot2 image is provided as well. To test `config/examples/x86_fsp_qemu.config` use the following steps: @@ -2502,7 +2501,7 @@ To compile a flashable image run the following steps: cp config/examples/kontron_vx3060_s2.config .config ./tools/scripts/x86_fsp/tgl/tgl_download_fsp.sh make tpmtools -./tools/scripts/x86_fsp/tgl/assemble_image.sh -k +./tools/scripts/x86_fsp/tgl/assemble_image.sh -k make CFLAGS_EXTRA="-DHAVE_ECC256" ./tools/scripts/x86_fsp/tgl/assemble_image.sh -n /path/to/original/flash/dump ``` diff --git a/hal/spi/spi_drv_stm32.h b/hal/spi/spi_drv_stm32.h index 06b9e389..57033878 100644 --- a/hal/spi/spi_drv_stm32.h +++ b/hal/spi/spi_drv_stm32.h @@ -51,7 +51,9 @@ #define OCTOSPI1_BASE (PERIPH_BASE + 0x020D1400UL) #define OCTOSPI2_BASE (PERIPH_BASE + 0x020D2400UL) +#ifndef OCTOSPI_BASE #define OCTOSPI_BASE OCTOSPI2_BASE +#endif /* Registers mapping */ #define APB2PERIPH_BASE (PERIPH_BASE + 0x00012C00UL)