summaryrefslogtreecommitdiff
path: root/programmer.h
diff options
context:
space:
mode:
authorstefanct <stefanct@2b7e53f0-3cfb-0310-b3e9-8179ed1497e1>2015-02-08 21:58:10 +0000
committerstefanct <stefanct@2b7e53f0-3cfb-0310-b3e9-8179ed1497e1>2015-02-08 21:58:10 +0000
commitef82032caba19e59bdd196764345631ae682c983 (patch)
tree597dd6c02ecd223e56d3088682e1c5314409af1f /programmer.h
parentf1dfa44726072f76ed5202140e3c76a212ed7625 (diff)
downloadflashrom-ef82032caba19e59bdd196764345631ae682c983.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 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> git-svn-id: https://code.coreboot.org/svn/flashrom/trunk@1881 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'programmer.h')
-rw-r--r--programmer.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/programmer.h b/programmer.h
index c61f429..913522b 100644
--- a/programmer.h
+++ b/programmer.h
@@ -102,6 +102,9 @@ enum programmer {
#if CONFIG_MSTARDDC_SPI == 1
PROGRAMMER_MSTARDDC_SPI,
#endif
+#if CONFIG_PICKIT2_SPI == 1
+ PROGRAMMER_PICKIT2_SPI,
+#endif
PROGRAMMER_INVALID /* This must always be the last entry. */
};
@@ -480,6 +483,11 @@ extern const struct dev_entry devs_usbblasterspi[];
int mstarddc_spi_init(void);
#endif
+/* pickit2_spi.c */
+#if CONFIG_PICKIT2_SPI == 1
+int pickit2_spi_init(void);
+#endif
+
/* rayer_spi.c */
#if CONFIG_RAYER_SPI == 1
int rayer_spi_init(void);
@@ -564,6 +572,9 @@ enum spi_controller {
#if CONFIG_MSTARDDC_SPI == 1
SPI_CONTROLLER_MSTARDDC,
#endif
+#if CONFIG_PICKIT2_SPI == 1
+ SPI_CONTROLLER_PICKIT2,
+#endif
};
#define MAX_DATA_UNSPECIFIED 0