From 7b35b4ebee70a1fd4379d3c442a854f1658844b3 Mon Sep 17 00:00:00 2001 From: Ulf Lilleengen Date: Wed, 29 Jun 2022 19:14:07 +0200 Subject: [PATCH 1/2] Fix RAM origin copy paste from nrf --- examples/boot/application/stm32f3/memory.x | 2 +- examples/boot/application/stm32f7/memory-bl.x | 2 +- examples/boot/application/stm32l0/memory.x | 2 +- examples/boot/application/stm32l1/memory.x | 2 +- examples/boot/application/stm32l4/memory.x | 2 +- examples/boot/application/stm32wl/memory.x | 2 +- examples/boot/bootloader/stm32/memory.x | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/examples/boot/application/stm32f3/memory.x b/examples/boot/application/stm32f3/memory.x index 14b2a2c9f..f51875766 100644 --- a/examples/boot/application/stm32f3/memory.x +++ b/examples/boot/application/stm32f3/memory.x @@ -5,7 +5,7 @@ MEMORY BOOTLOADER_STATE : ORIGIN = 0x08006000, LENGTH = 4K FLASH : ORIGIN = 0x08008000, LENGTH = 32K DFU : ORIGIN = 0x08010000, LENGTH = 36K - RAM (rwx) : ORIGIN = 0x20000008, LENGTH = 32K + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 32K } __bootloader_state_start = ORIGIN(BOOTLOADER_STATE) - ORIGIN(BOOTLOADER); diff --git a/examples/boot/application/stm32f7/memory-bl.x b/examples/boot/application/stm32f7/memory-bl.x index 47f3f4d9b..2058f6bf3 100644 --- a/examples/boot/application/stm32f7/memory-bl.x +++ b/examples/boot/application/stm32f7/memory-bl.x @@ -5,7 +5,7 @@ MEMORY BOOTLOADER_STATE : ORIGIN = 0x08040000, LENGTH = 256K ACTIVE : ORIGIN = 0x08080000, LENGTH = 256K DFU : ORIGIN = 0x080c0000, LENGTH = 512K - RAM (rwx) : ORIGIN = 0x20000008, LENGTH = 368K + 16K + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 368K + 16K } __bootloader_state_start = ORIGIN(BOOTLOADER_STATE) - ORIGIN(FLASH); diff --git a/examples/boot/application/stm32l0/memory.x b/examples/boot/application/stm32l0/memory.x index d0d2bd7bb..a99330145 100644 --- a/examples/boot/application/stm32l0/memory.x +++ b/examples/boot/application/stm32l0/memory.x @@ -5,7 +5,7 @@ MEMORY BOOTLOADER_STATE : ORIGIN = 0x08006000, LENGTH = 4K FLASH : ORIGIN = 0x08008000, LENGTH = 32K DFU : ORIGIN = 0x08010000, LENGTH = 36K - RAM (rwx) : ORIGIN = 0x20000008, LENGTH = 16K + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 16K } __bootloader_state_start = ORIGIN(BOOTLOADER_STATE) - ORIGIN(BOOTLOADER); diff --git a/examples/boot/application/stm32l1/memory.x b/examples/boot/application/stm32l1/memory.x index d0d2bd7bb..a99330145 100644 --- a/examples/boot/application/stm32l1/memory.x +++ b/examples/boot/application/stm32l1/memory.x @@ -5,7 +5,7 @@ MEMORY BOOTLOADER_STATE : ORIGIN = 0x08006000, LENGTH = 4K FLASH : ORIGIN = 0x08008000, LENGTH = 32K DFU : ORIGIN = 0x08010000, LENGTH = 36K - RAM (rwx) : ORIGIN = 0x20000008, LENGTH = 16K + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 16K } __bootloader_state_start = ORIGIN(BOOTLOADER_STATE) - ORIGIN(BOOTLOADER); diff --git a/examples/boot/application/stm32l4/memory.x b/examples/boot/application/stm32l4/memory.x index 14b2a2c9f..f51875766 100644 --- a/examples/boot/application/stm32l4/memory.x +++ b/examples/boot/application/stm32l4/memory.x @@ -5,7 +5,7 @@ MEMORY BOOTLOADER_STATE : ORIGIN = 0x08006000, LENGTH = 4K FLASH : ORIGIN = 0x08008000, LENGTH = 32K DFU : ORIGIN = 0x08010000, LENGTH = 36K - RAM (rwx) : ORIGIN = 0x20000008, LENGTH = 32K + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 32K } __bootloader_state_start = ORIGIN(BOOTLOADER_STATE) - ORIGIN(BOOTLOADER); diff --git a/examples/boot/application/stm32wl/memory.x b/examples/boot/application/stm32wl/memory.x index 14b2a2c9f..f51875766 100644 --- a/examples/boot/application/stm32wl/memory.x +++ b/examples/boot/application/stm32wl/memory.x @@ -5,7 +5,7 @@ MEMORY BOOTLOADER_STATE : ORIGIN = 0x08006000, LENGTH = 4K FLASH : ORIGIN = 0x08008000, LENGTH = 32K DFU : ORIGIN = 0x08010000, LENGTH = 36K - RAM (rwx) : ORIGIN = 0x20000008, LENGTH = 32K + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 32K } __bootloader_state_start = ORIGIN(BOOTLOADER_STATE) - ORIGIN(BOOTLOADER); diff --git a/examples/boot/bootloader/stm32/memory.x b/examples/boot/bootloader/stm32/memory.x index 110c23259..b6f185ef7 100644 --- a/examples/boot/bootloader/stm32/memory.x +++ b/examples/boot/bootloader/stm32/memory.x @@ -5,7 +5,7 @@ MEMORY BOOTLOADER_STATE : ORIGIN = 0x08006000, LENGTH = 4K ACTIVE : ORIGIN = 0x08008000, LENGTH = 32K DFU : ORIGIN = 0x08010000, LENGTH = 36K - RAM (rwx) : ORIGIN = 0x20000008, LENGTH = 16K + RAM (rwx) : ORIGIN = 0x20000000, LENGTH = 16K } __bootloader_state_start = ORIGIN(BOOTLOADER_STATE) - ORIGIN(FLASH); From 7b47bea72cf476639509e1f4c338a9dd0953db4a Mon Sep 17 00:00:00 2001 From: Ulf Lilleengen Date: Wed, 29 Jun 2022 19:19:24 +0200 Subject: [PATCH 2/2] Remove unused imports --- embassy-boot/stm32/build.rs | 3 --- 1 file changed, 3 deletions(-) diff --git a/embassy-boot/stm32/build.rs b/embassy-boot/stm32/build.rs index 03d0119fc..2cbc7ef5e 100644 --- a/embassy-boot/stm32/build.rs +++ b/embassy-boot/stm32/build.rs @@ -1,7 +1,4 @@ use std::env; -use std::fs::File; -use std::io::Write; -use std::path::PathBuf; fn main() { let target = env::var("TARGET").unwrap();