summaryrefslogtreecommitdiff
path: root/hw/bsp/stm32c5/linker/stm32c542xc_flash.icf
blob: ea826ba8e9607d5fef4c72bb3aab1c66bab31714 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/**
******************************************************************************
* @file    stm32c542xc_flash.icf
* @brief   Linker File
******************************************************************************
* @attention
*
* Copyright (c) 2026 STMicroelectronics.
* All rights reserved.
*
* This software is licensed under terms that can be found in the LICENSE file
* in the root directory of this software component.
* If no LICENSE file comes with this software, it is provided AS-IS.
*
******************************************************************************
*/

define memory mem with size = 4G;
define region ROM = mem:[from 0x8000000 size 0x40000];
define region RAM = mem:[from 0x20000000 size 0x10000];

/* define blocks */
define block HEAP with alignment = 8, size = 0x200 { };
define block CSTACK with alignment = 8, size = 0x1000 { };

/* setup initialization strategies */
initialize by copy {
  readwrite
};

do not initialize {
  section .noinit
};

place at start of ROM { readonly section .intvec } ;

/* sections placements */
place in ROM {
  readonly
};

place in RAM {
  readwrite,
  block HEAP,
  block CSTACK
};