Skip to main content
iTTy
Associate III
November 28, 2023
Solved

Missing MPU initialization function

  • November 28, 2023
  • 4 replies
  • 2815 views

Hi there!

I just would like to report that enabling the MPU for the M7 core on my NUCLEO-H755ZI-Q, CubeMX (6.9.2, with H7 package version 1.11.1) generates 2 functions:
MPU_Initialize() and
MPU_Config().

While the second one is declared and defined in the main.c; the first one is just declared and never defined nor used generating a compiler warning.
It's simple to fix it by cancelling the useless declaration, but the warning com back any time the code is re-generated...

iTTy

 

Edit: Edited by ST Moderator to add right Label "STM32CubeMX"

This topic has been closed for replies.
Best answer by iTTy

Hi @tec683,

as mentioned above, updating the environment to a newer one (IDE v.1.14.0, MX v6.10.0 with H7 FW packages v. 1.11.1) seems to fix this issue.

By!

4 replies

TDK
Super User
November 28, 2023

Can you share your IOC? There are two different cores and lots of ways to configure the MPU.

"If you feel a post has answered your question, please click ""Accept as Solution""."
iTTy
iTTyAuthor
Associate III
November 29, 2023

Here my .ioc file.... I hope!

Since forum's form still don't recognize my .ioc I tryied to compress it in a .tar.

Technical Moderator
November 28, 2023

Hello @iTTy 

Can you please try with latest release of STM32CubeMX (v 6.10.0)? 

The static void MPU_Initialize(void); declaration is not added in this context.

Imen

"When your question is answered, please close this topic by clicking ""Accept as Solution"".ThanksImen"
iTTy
iTTyAuthor
Associate III
November 29, 2023

Hi everyone!

@TDK, I would like to attach my .ioc there but I get an error...

iTTy_0-1701252745332.png

Moreover seems there are more then 3 file attached, but I can't clean this section....

iTTy_1-1701252858074.png

I will try in the next post... sorry!

@Imen.D , I did it as follow:

  1. I downloaded and installed new enviroment (IDE v.1.14.0, MX v6.10.0 with H7 FW packages v. 1.11.1) on a spare laptop
  2. I copied the project on new laptop
  3. I migated the project and re-generated the code.

I confirm the wrong MPU_Initialize() declaration is no more present.

Associate III
December 14, 2023

This MPU_Initialize declared static warning has occurred across H7 and F7 families in my experience. It happens when code is generated with the MPU enabled. Not with an initial example. Should we be doing something with this? It is just a declaration with no code attached that I've found.

iTTy
iTTyAuthorBest answer
Associate III
December 19, 2023

Hi @tec683,

as mentioned above, updating the environment to a newer one (IDE v.1.14.0, MX v6.10.0 with H7 FW packages v. 1.11.1) seems to fix this issue.

By!