aboutsummaryrefslogtreecommitdiff
path: root/src/flash/nor/at91samd.c
AgeCommit message (Collapse)Author
2014-03-29at91samd: Bail early if trying to erase protected sectorAndrey Smirnov
Bail early if trying to erase protected sector and also do not double-erase already erased sectors. Change-Id: Ic2d39af48c3b8e10e78d52dd978b9bc01f671c6a Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Reviewed-on: http://openocd.zylin.com/2026 Tested-by: jenkins Reviewed-by: Paul Fertser <fercerpav@gmail.com>
2014-03-29at91samd: Bail early if trying to write to protected sectorAndrey Smirnov
Bail early if trying to write to protected sector also mark the sector we are writing to as dirty. Change-Id: I892f83461792e1cc2dcccade7aa65717831a6805 Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Reviewed-on: http://openocd.zylin.com/2025 Tested-by: jenkins Reviewed-by: Paul Fertser <fercerpav@gmail.com>
2014-03-29at91samd: Remove 'first' and 'last' checks in 'samd_erase'Andrey Smirnov
Remove 'first' and 'last' checks in 'samd_protect' since those parameters are checked in 'handle_flash_erase_command'. Change-Id: I30e5598a9ab656d81055f26cc63e291377605300 Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Reviewed-on: http://openocd.zylin.com/2024 Tested-by: jenkins Reviewed-by: Andrey Yurovsky <yurovsky@gmail.com> Reviewed-by: Paul Fertser <fercerpav@gmail.com>
2014-03-17flash: Constify write bufferAndreas Fritiofson
Change-Id: Ic812098d3ed5a2992c26bb57d08ae350e2c5d5d8 Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com> Reviewed-on: http://openocd.zylin.com/2040 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2014-01-20flash: samd: declare const dataAndrey Yurovsky
Make the chip information lookup tables const (thanks to Spencer Oliver for pointing this out). Also fix spacing on one macro. No functional changes. Change-Id: I053c4951c2626b8aa4541a79673b500394ef08e8 Signed-off-by: Andrey Yurovsky <yurovsky@gmail.com> Reviewed-on: http://openocd.zylin.com/1874 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2014-01-15Atmel samd: add support for SAMD21Andrey Yurovsky
Tested with SAMD21J18A on the SAMD21 Xplained Pro board. Change-Id: Ice9ebcd229ed038b3193baf92d910f9256d7ce91 Signed-off-by: Andrey Yurovsky <yurovsky@gmail.com> Reviewed-on: http://openocd.zylin.com/1873 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
2014-01-09add support for Atmel SAMD NOR FlashAndrey Yurovsky
This adds a new NOR Flash driver, "at91samd", which supports the built-in Flash on Atmel's D-series Cortex M MCUs, starting with the D20. Parts and their geometry are detected automatically using the DSU and lookup schemes described in the D20 document, 42129F–SAM–10/2013. Future D-series variants and families should presumably use this controller as well (possibly with minor changes and improvements). Tested on the SAMD20 Xplained Pro board, for which we also add the corresponding Flash configuration. Change-Id: Id8d3dd601e9f53121682d1a1190d0be4ea3b83eb Signed-off-by: Andrey Yurovsky <yurovsky@gmail.com> Reviewed-on: http://openocd.zylin.com/1684 Tested-by: jenkins Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>