openocd/src/flash
Andreas Fritiofson 9a8edbfa8b flash: reduce code duplication in stm32 flash probe
Remove a lot of the repetitive code in stm32f1x flash probe by converting
the large if-selector to a switch, moving the common checks outside it and
concentrating the failure handling to a single point.

Do the same with stm32f2x and stm32lx for consistency.

Change-Id: Ic0ecfb1533c49f5d2108cda5fd20c8372d7c71ef
Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Reviewed-on: http://openocd.zylin.com/746
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-by: Freddie Chopin <freddie.chopin@gmail.com>
2012-07-30 06:33:58 +00:00
..
nand Sometime in the past, nand_fileio_finish started to return ERROR_OK (with the value of zero) on success. 2012-02-22 20:54:09 +00:00
nor flash: reduce code duplication in stm32 flash probe 2012-07-30 06:33:58 +00:00
ocl/at91sam7x change #include "ocl.h" to <flash/nor/ocl.h> 2009-12-03 04:24:49 -08:00
common.c build: cleanup src/flash directory 2012-02-06 10:51:49 +00:00
common.h build: cleanup src/flash directory 2012-02-06 10:51:49 +00:00
Makefile.am build: add common.mk 2010-11-18 14:05:56 +00:00
mflash.c doxygen: use correct comment syntax 2012-02-06 12:55:03 +00:00
mflash.h build: cleanup src/flash directory 2012-02-06 10:51:49 +00:00
startup.tcl flash: add support for deprecated stm32 flash cmds 2011-07-28 12:47:49 +01:00