summaryrefslogtreecommitdiffstats
path: root/flashrom.c
diff options
context:
space:
mode:
authorJustin Chevrier <jchevrier@gmail.com>2015-02-08 21:58:10 +0000
committerStefan Tauner <stefan.tauner@alumni.tuwien.ac.at>2015-02-08 21:58:10 +0000
commit66e554bc88a29ec6bc55c86320799c31b5b0e6c1 (patch)
tree597dd6c02ecd223e56d3088682e1c5314409af1f /flashrom.c
parent5673450316b0624f3b0a763babdcaf9f13fde12c (diff)
downloadast2050-flashrom-66e554bc88a29ec6bc55c86320799c31b5b0e6c1.zip
ast2050-flashrom-66e554bc88a29ec6bc55c86320799c31b5b0e6c1.tar.gz
Add support for the Microchip PICkit2 as an SPI programmer
This patch was inspired by the code in AVRDude (open source Atmel AVR programmer) to support the PICkit2 written by Doug Brown [1]. The Dediprog code in flashrom was used as the template for this code with some reference to the ft2232 code as well. [1] - https://github.com/steve-m/avrdude/blob/master/pickit2.c Corresponding to flashrom svn r1881. Signed-off-by: Justin Chevrier <jchevrier@gmail.com> Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
Diffstat (limited to 'flashrom.c')
-rw-r--r--flashrom.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/flashrom.c b/flashrom.c
index e58f707..a389cb2 100644
--- a/flashrom.c
+++ b/flashrom.c
@@ -366,6 +366,19 @@ const struct programmer_entry programmer_table[] = {
},
#endif
+#if CONFIG_PICKIT2_SPI == 1
+ {
+ .name = "pickit2_spi",
+ .type = OTHER,
+ /* FIXME */
+ .devs.note = "Microchip PICkit2\n",
+ .init = pickit2_spi_init,
+ .map_flash_region = fallback_map,
+ .unmap_flash_region = fallback_unmap,
+ .delay = internal_delay,
+ },
+#endif
+
{0}, /* This entry corresponds to PROGRAMMER_INVALID. */
};
OpenPOWER on IntegriCloud