summaryrefslogtreecommitdiffstats
path: root/programmer.h
diff options
context:
space:
mode:
authorNico Huber <nico.huber@secunet.com>2012-06-15 22:28:12 +0000
committerCarl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>2012-06-15 22:28:12 +0000
commit7bca126561b80f626dea269d7a6284a7cde0a8ed (patch)
tree45c6b31e39846a88d89d157d758134d7b8dc1db1 /programmer.h
parent3464d05eb41ab4c7a6faba9a1a36bfbeda0de850 (diff)
downloadast2050-flashrom-7bca126561b80f626dea269d7a6284a7cde0a8ed.zip
ast2050-flashrom-7bca126561b80f626dea269d7a6284a7cde0a8ed.tar.gz
Let the programmer driver decide how to do AAI transfers
Currently spi_aai_write() is implemented without an abstraction mechanism for the programmer driver. This adds another function pointer 'write_aai' to struct spi_programmer, which is set to default_spi_write_aai (renamed spi_aai_write) for all programmers for now. A patch which utilises this abstraction in the dediprog driver will follow. Corresponding to flashrom svn r1543. Signed-off-by: Nico Huber <nico.huber@secunet.com> Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Diffstat (limited to 'programmer.h')
-rw-r--r--programmer.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/programmer.h b/programmer.h
index 6f9ea8f..d60fc5d 100644
--- a/programmer.h
+++ b/programmer.h
@@ -530,6 +530,7 @@ struct spi_programmer {
/* Optimized functions for this programmer */
int (*read)(struct flashctx *flash, uint8_t *buf, unsigned int start, unsigned int len);
int (*write_256)(struct flashctx *flash, uint8_t *buf, unsigned int start, unsigned int len);
+ int (*write_aai)(struct flashctx *flash, uint8_t *buf, unsigned int start, unsigned int len);
const void *data;
};
@@ -538,6 +539,7 @@ int default_spi_send_command(struct flashctx *flash, unsigned int writecnt, unsi
int default_spi_send_multicommand(struct flashctx *flash, struct spi_command *cmds);
int default_spi_read(struct flashctx *flash, uint8_t *buf, unsigned int start, unsigned int len);
int default_spi_write_256(struct flashctx *flash, uint8_t *buf, unsigned int start, unsigned int len);
+int default_spi_write_aai(struct flashctx *flash, uint8_t *buf, unsigned int start, unsigned int len);
int register_spi_programmer(const struct spi_programmer *programmer);
/* The following enum is needed by ich_descriptor_tool and ich* code. */
OpenPOWER on IntegriCloud