From aeb3c4f37e9c83e45ea1b9ef9f23bbdbb451fca2 Mon Sep 17 00:00:00 2001 From: Christopher Kilgour Date: Wed, 23 May 2012 11:05:28 -0700 Subject: kinetis: update support for all program flash granularities MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Updates the Kinetis NOR flash support to handle all known block and sector sizes. Previously only 2kiB sectors were hard-coded, now all four known combinations non-volatile sector sizes are supported. The premise of separating Kinetis Program Flash (PFLASH) from FlexNVM is also introduced. This means each "block" of flash (in Freescale terms) is treated as a bank in OpenOCD. Correspondingly, the existing board configuration for the TWR-K60M512 eval system is updated to recognize two banks instead of one. A board config for the TWR-K60F120M is also added. Bank and sector erase and programming has been checked with both of the mentioned eval boards. Change-Id: Iae2d10ebf8f548d0a3698df5430bbbe1ccadc58a Signed-off-by: Christopher Kilgour Reviewed-on: http://openocd.zylin.com/663 Tested-by: jenkins Reviewed-by: Mathias Küster Reviewed-by: Jan Dakinevich Reviewed-by: Spencer Oliver --- tcl/board/twr-k60n512.cfg | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'tcl/board/twr-k60n512.cfg') diff --git a/tcl/board/twr-k60n512.cfg b/tcl/board/twr-k60n512.cfg index 4fe35bb..3b3b02f 100644 --- a/tcl/board/twr-k60n512.cfg +++ b/tcl/board/twr-k60n512.cfg @@ -11,4 +11,5 @@ $_TARGETNAME configure -event reset-init { # # Bank definition for the 'program flash' (instructions and/or data) # -flash bank pflash.pflash kinetis 0x00000000 0x80000 0 4 $_TARGETNAME +flash bank pflash.0 kinetis 0x00000000 0x40000 0 4 $_TARGETNAME +flash bank pflash.1 kinetis 0x00040000 0x40000 0 4 $_TARGETNAME -- cgit v1.1