Commit Graph

14 Commits

Author SHA1 Message Date
Karl Palsson b146fd6aa7 doc: stm32: flash: tidy up doxygen warnings and broken groupings 2020-03-06 01:14:17 +00:00
Karl Palsson 2bed518f09 stm32f7: doc: flash defines weren't grouped at all 2019-05-21 23:45:34 +00:00
Karl Palsson 659d52b952 stm32f7: flash: drop unimplemented function declaration
flash_art_disable was never implemented, and isn't really a super useful
function anyway, so just drop the decl, rather than implementing it.
2018-07-29 20:31:17 +00:00
Karl Palsson 231f21296f stm32: f247: flash: use common code.
This shows what is _actually_ different for f7.  A couple of option
bits, and a renaming of bit 7 of the status register, from Program
Sequence Error to Erase Sequence Error.

We keep the separate implementation of wait_for_last_operation, to meet
the "suggestions" of the reference manual to insert a DSB instruction.

Keeping the renamed bit/functions also requires us to keep separate
implementations of the flag clearing functions
2018-07-29 20:31:17 +00:00
Karl Palsson eafc46ff24 stm32: flash: extract wait_for_last_operation to top level
This then eliminates the misguided attempts at merging f2/4 and f3 flash
support.  Some headers remain.
2018-07-29 20:31:17 +00:00
Karl Palsson c272ea410e stm32: flash: move clear all status flags to single common header
We've got a "f" flash file for common apis now, use it.
2018-07-29 20:31:17 +00:00
Karl Palsson 850931dbcd stm32: flash_unlock_option_bytes is common code.
The keys differ between some familes, but the documentation and
implementation are standard.
2018-07-29 20:31:17 +00:00
Karl Palsson 2bf7eb4a0c stm32: flash: pull set_ws up to common code
All that changes is the size of the field.
2018-07-29 20:31:17 +00:00
Karl Palsson 4840b6bc7e stm32: flash: pull up clear_eop
All the "f" type flash parts have an EOP flag, even if it's in different
bit positions.  Add a header for this common functionality, and move
it's implementation to the existing common file.
2018-07-29 20:31:17 +00:00
Karl Palsson da7ebafcbe stm32: flash: pull lock/unlock up to common_f.
This is a common operation, so definition in _all, and every part except
l0/l1 have the same implementation.  Bring in an _f file too.
2018-07-29 20:31:17 +00:00
Karl Palsson b23dccc7ae stm32: flash: pull up prefetch to _all
Turns out, there's lots of common code for flash.  Pull up prefetch
on/off to start with, as there's only a single bit name different.

Pull up the definitions of common API functions too, starting with
flash_set_ws.  Even if the implementations are different, things that
meant to be the same, should be defined centrally.
2018-07-29 20:31:17 +00:00
Karl Palsson 9dd901ba27 stm32: flash: BSY bit has never been writable.
This has been copied around for years, but has never been a writable bit
on any target.
2018-07-29 20:31:17 +00:00
Matthew Lai ba0e0424b5 stm32f7: flash: added proper support 2018-07-03 22:23:00 +00:00
Sync c285bcb493 stm32f7: rcc: initial clock config for disco board
Add clock config for the 25MHz crystal found on the discovery board.
Verified to work on the STM32F7-Disco.

Reviewed-by: Karl Palsson <karlp@tweak.net.au>
Modified namespaces and types->structs to avoid namespace pollution as
was fixed for other families in:

3a7cbec7: stm32l/stm32f: name space standardization [BREAKING]
2017-03-30 21:48:07 +00:00