Skip to content

Commit

Permalink
[cortex-m] Invalidate CM7 caches only after enabling them
Browse files Browse the repository at this point in the history
  • Loading branch information
salkinium committed Dec 30, 2024
1 parent 0e1fc86 commit e7fc5eb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/modm/platform/core/cortex/startup.c.in
Original file line number Diff line number Diff line change
Expand Up @@ -101,13 +101,13 @@ void __modm_startup(void)
%#
%% if with_icache
// Enable instruction cache
SCB_InvalidateICache();
SCB_EnableICache();
SCB_InvalidateICache();
%% endif
%% if with_dcache
// Enable data cache with default WBWA policy
SCB_CleanInvalidateDCache();
SCB_EnableDCache();
SCB_CleanInvalidateDCache();
%% endif
%#
%% if core != "cortex-m0"
Expand Down

0 comments on commit e7fc5eb

Please sign in to comment.