aboutsummaryrefslogtreecommitdiff
path: root/src/flash/nor/stm32f1x.c
AgeCommit message (Collapse)Author
2012-01-12cmd: add missing usage varSpencer Oliver
Change-Id: I0f05d643b0801b19cc3beb88f0d12d7e4c83ef9c Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-on: http://openocd.zylin.com/356 Tested-by: jenkins
2012-01-12flash: use correct device_id maskSpencer Oliver
The stm32 drivers have been using 0x7ff as the DEV_ID mask, this should have been 0xfff. Change-Id: I232469620969d6dd1b9a2a2aa15ec18b947dbb05 Signed-off-by: Spencer Oliver <spen@spen-soft.co.uk> Reviewed-on: http://openocd.zylin.com/352 Tested-by: jenkins Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2012-01-04Change return value on error.Mathias K
On wrong parameters a error is signalized to the calling function. Change-Id: I484443fdb39938e20382edc9246d5ec546a5c960 Signed-off-by: Mathias K <kesmtp@freenet.de> Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com> Reviewed-on: http://openocd.zylin.com/282 Tested-by: jenkins Reviewed-by: Øyvind Harboe <oyvindharboe@gmail.com>
2011-11-17stm32f1x: improve variable naming and avoid potential divide-by-zeroAndreas Fritiofson
Don't call a variable num_pages if it holds the flash size. Also rearrange flash size to num_pages calculation to avoid divide-by-zero if there will be a device with < 1024 byte pages someday. Change-Id: I2febea39694a2f9750de141f52ec88ae1599c086 Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com> Reviewed-on: http://openocd.zylin.com/211 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2011-11-16stm32f1x: add more assertsØyvind Harboe
this at least checks the post conditions after convoluted code. Change-Id: Idfa8cbedce5288d8bae5743687949f141dfb07b2 Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com> Reviewed-on: http://openocd.zylin.com/187 Tested-by: jenkins Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2011-10-28Fixes comment typo for page sizeJonathan Dumaresq
Change-Id: I6dd8aadcecd680c48e696aeec0daf74d2addbb05 Signed-off-by: Jonathan Dumaresq <jdumaresq@cimeq.qc.ca> Reviewed-on: http://openocd.zylin.com/132 Tested-by: jenkins Reviewed-by: Peter Stuge <peter@stuge.se>
2011-10-09stm32f1x: use async algorithm in flash programming routineAndreas Fritiofson
Let the target algorithm be running in the background and buffer data continuously through a FIFO. This reduces or removes the effect of latency because only a very small number of queue executions needs to be done per buffer fill. Previously, the many repeated target state changes, register accesses (really inefficient) and algorithm uploads caused the flash programming to be latency bound in many cases. Now it should scale better with increased throughput. Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2011-10-09stm32f1x: use register base instead of register offsetAndreas Fritiofson
Access the different flash banks' registers using a bank specific register base and a register specific offset. This is equivalent but feels more natural. Some accesses were discovered that maybe should not be hard coded to bank0 registers. Add a note about that. Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
2011-08-25This will add the Value Line HD of stm32 devices.Jonathan Dumaresq
This has been tested on STM32F100VE
2011-07-28flash: update stm32 driver namesSpencer Oliver
Use consistent names for the stm32 family flash drivers, eg. stm32x -> stm32f1x stm32f2xxx -> stm32f2x this makes it easier to add support for newer stm32 families. Signed-off-by: Spencer Oliver <ntfreak@users.sourceforge.net>