{bp-19454} boards/stm32f3: nucleo-f302r8:ihm07m1_b16: enable LTO to fit flash - #19705
Open
jerpelea wants to merge 5 commits into
Open
{bp-19454} boards/stm32f3: nucleo-f302r8:ihm07m1_b16: enable LTO to fit flash#19705jerpelea wants to merge 5 commits into
jerpelea wants to merge 5 commits into
Conversation
jerpelea
requested review from
Donny9,
GUIDINGLI,
pkarashchenko and
raiden00pl
as code owners
August 6, 2026 06:11
Contributor
Author
|
PLEASE DO NOT MERGE UNLESS CI PASSES |
cederom
approved these changes
Aug 6, 2026
xiaoxiang781216
approved these changes
Aug 6, 2026
jerpelea
requested review from
Ouss4,
antmerlino,
btashton,
davids5,
gustavonihei,
hartmannathan,
masayuki2009,
michallenc,
rcsim,
simbit18 and
yamt
as code owners
August 6, 2026 07:20
Contributor
Author
|
CI should be restarted after #19716 is merged or (arm-08) will fail due to lack of flash space |
The ihm07m1_b16 (FOC motor control) configuration overflows the STM32F302R8 64 KiB flash region by ~470 bytes, so it no longer links. Enable GNU Full LTO (CONFIG_LTO_FULL=y); cross-module dead-code elimination brings the image back under the limit (flash drops from ~66.0 KiB to ~57.7 KiB, 88%). Signed-off-by: anjiahao <anjiahao@xiaomi.com>
Replace the divergent board conventions for the timer input clock frequency with a single uniform convention provided by every board: - STM32_APBx_TIMn_CLKIN and BOARD_TIMn_FREQUENCY -> STM32_TIMn_CLKIN - STM32_APBx_LPTIMn_CLKIN, BOARD_LPTIMn_FREQUENCY and STM32_LPTIMn_FREQUENCY -> STM32_LPTIMn_CLKIN - STM32_APB1_THRTIM1_CLKIN and BOARD_HRTIM1_FREQUENCY -> STM32_HRTIM1_CLKIN All STM32 consumers (tim/lptim/pwm/adc/dac/capture/sdadc/dfsdm/ pulsecount) updated to match; the timer input clock is now bus-agnostic in the drivers. Boards that carried the same timer clock in more than one convention now define STM32_TIMn_CLKIN exactly once, derived from the APB bus clock (PCLKx with the x2 doubler when the APB prescaler is greater than 1), instead of redefining it with a second, sometimes different, value. BREAKING CHANGE: The timer input-clock board macros STM32_APBx_TIMn_CLKIN, BOARD_TIMn_FREQUENCY, STM32_APBx_LPTIMn_CLKIN, BOARD_LPTIMn_FREQUENCY, STM32_LPTIMn_FREQUENCY, STM32_APB1_THRTIM1_CLKIN and BOARD_HRTIM1_FREQUENCY are removed in favor of STM32_TIMn_CLKIN, STM32_LPTIMn_CLKIN and STM32_HRTIM1_CLKIN. Out-of-tree boards must define the new macros (drop the APB bus from the name, keep the value), and out-of-tree drivers referencing the old names must be updated. Signed-off-by: raiden00pl <raiden00@railab.me>
xiaoxiang781216
approved these changes
Aug 6, 2026
Contributor
Author
|
#19723 needs to be merged before restating CI |
This reverts commit 1240ee3. which is out of sync with releases/13.0 nuttx-apps Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
New series of the STM32F746G-DISCO use Winbond W25Q128JVEQ. This commit adds support for it. Signed-off-by: Martin Vajnar <martin.vajnar@gmail.com>
Build fs_link.c unconditionally so link() remains available even when CONFIG_PSEUDOFS_SOFTLINKS is disabled. Return ENOSYS in that configuration instead of leaving applications with an undefined symbol. Signed-off-by: Felipe Moura <moura.fmo@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The ihm07m1_b16 (FOC motor control) configuration overflows the STM32F302R8 64 KiB flash region by ~470 bytes, so it no longer links. Enable GNU Full LTO (CONFIG_LTO_FULL=y); cross-module dead-code elimination brings the image back under the limit (flash drops from ~66.0 KiB to ~57.7 KiB, 88%).
Includes
#19212
#19297
Impact
RELEASE
Testing
CI