aboutsummaryrefslogtreecommitdiff
path: root/src/flash
diff options
context:
space:
mode:
Diffstat (limited to 'src/flash')
-rw-r--r--src/flash/nor/stm32f1x.c43
1 files changed, 39 insertions, 4 deletions
diff --git a/src/flash/nor/stm32f1x.c b/src/flash/nor/stm32f1x.c
index 30652c6f..105bd79c 100644
--- a/src/flash/nor/stm32f1x.c
+++ b/src/flash/nor/stm32f1x.c
@@ -921,8 +921,8 @@ static int stm32x_probe(struct flash_bank *bank)
stm32x_info->option_offset = 6;
stm32x_info->default_rdp = 0x55AA;
break;
- case 0x440: /* stm32f0x */
- case 0x444:
+ case 0x440: /* stm32f05x */
+ case 0x444: /* stm32f03x */
page_size = 1024;
stm32x_info->ppage_size = 4;
max_flash_size_in_kb = 64;
@@ -930,6 +930,14 @@ static int stm32x_probe(struct flash_bank *bank)
stm32x_info->option_offset = 6;
stm32x_info->default_rdp = 0x55AA;
break;
+ case 0x448: /* stm32f07x */
+ page_size = 2048;
+ stm32x_info->ppage_size = 4;
+ max_flash_size_in_kb = 128;
+ stm32x_info->user_data_offset = 16;
+ stm32x_info->option_offset = 6;
+ stm32x_info->default_rdp = 0x55AA;
+ break;
default:
LOG_WARNING("Cannot identify target as a STM32 family.");
return ERROR_FAIL;
@@ -1167,9 +1175,36 @@ static int get_stm32x_info(struct flash_bank *bank, char *buf, int buf_size)
}
break;
- case 0x440:
case 0x444:
- device_str = "STM32F0xx";
+ device_str = "STM32F03x";
+
+ switch (rev_id) {
+ case 0x1000:
+ rev_str = "1.0";
+ break;
+
+ case 0x2000:
+ rev_str = "2.0";
+ break;
+ }
+ break;
+
+ case 0x440:
+ device_str = "STM32F05x";
+
+ switch (rev_id) {
+ case 0x1000:
+ rev_str = "1.0";
+ break;
+
+ case 0x2000:
+ rev_str = "2.0";
+ break;
+ }
+ break;
+
+ case 0x448:
+ device_str = "STM32F07x";
switch (rev_id) {
case 0x1000: