From 5420ff3638409fab4b5dc088da3e4a9fb1285ccf Mon Sep 17 00:00:00 2001 From: Uwe Bonnes Date: Fri, 9 Jan 2015 11:16:04 +0100 Subject: [PATCH] stm32f09x: Print info in get_stm32x_info. Change-Id: I5f9b765fe04906e124e2c95ff6bf7193be9d4ce2 Signed-off-by: Uwe Bonnes Reviewed-on: http://openocd.zylin.com/2456 Tested-by: jenkins Reviewed-by: Spencer Oliver --- src/flash/nor/stm32f1x.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/flash/nor/stm32f1x.c b/src/flash/nor/stm32f1x.c index a2bd2a2b..6b5aafc1 100644 --- a/src/flash/nor/stm32f1x.c +++ b/src/flash/nor/stm32f1x.c @@ -1273,6 +1273,20 @@ static int get_stm32x_info(struct flash_bank *bank, char *buf, int buf_size) } break; + case 0x442: + device_str = "STM32F09x"; + + switch (rev_id) { + case 0x1000: + rev_str = "1.0"; + break; + + case 0x2000: + rev_str = "2.0"; + break; + } + break; + default: snprintf(buf, buf_size, "Cannot identify target as a STM32F0/1/3\n"); return ERROR_FAIL; -- 2.39.5