diff options
author | Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> | 2014-07-19 22:03:29 +0000 |
---|---|---|
committer | Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> | 2014-07-19 22:03:29 +0000 |
commit | d441ea8ea864bda6b0d6c918da6da918579cf410 (patch) | |
tree | 5daecd880a16b7011be28e064fb7550f3e6b7e58 /at45db.c | |
parent | 6ba24a08730cd186fdbc32e2159ed299c210346b (diff) | |
download | flashrom-d441ea8ea864bda6b0d6c918da6da918579cf410.zip flashrom-d441ea8ea864bda6b0d6c918da6da918579cf410.tar.gz |
Rename programmer registration functions
Register_programmer suggests that we register a programmer. However,
that function registers a master for a given bus type, and a programmer
may support multiple masters (e.g. SPI, FWH). Rename a few other
functions to be more consistent.
Corresponding to flashrom svn r1831.
Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
Diffstat (limited to 'at45db.c')
-rw-r--r-- | at45db.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -241,7 +241,7 @@ int spi_read_at45db(struct flashctx *flash, uint8_t *buf, unsigned int addr, uns /* We have to split this up into chunks to fit within the programmer's read size limit, but those * chunks can cross page boundaries. */ - const unsigned int max_data_read = flash->pgm->spi.max_data_read; + const unsigned int max_data_read = flash->mst->spi.max_data_read; const unsigned int max_chunk = (max_data_read > 0) ? max_data_read : page_size; while (len > 0) { unsigned int chunk = min(max_chunk, len); @@ -272,7 +272,7 @@ int spi_read_at45db_e8(struct flashctx *flash, uint8_t *buf, unsigned int addr, /* We have to split this up into chunks to fit within the programmer's read size limit, but those * chunks can cross page boundaries. */ - const unsigned int max_data_read = flash->pgm->spi.max_data_read; + const unsigned int max_data_read = flash->mst->spi.max_data_read; const unsigned int max_chunk = (max_data_read > 0) ? max_data_read : page_size; while (len > 0) { const unsigned int addr_at45 = at45db_convert_addr(addr, page_size); @@ -463,7 +463,7 @@ static int at45db_fill_buffer1(struct flashctx *flash, const uint8_t *bytes, uns } /* Create a suitable buffer to store opcode, address and data chunks for buffer1. */ - const unsigned int max_data_write = flash->pgm->spi.max_data_write; + const unsigned int max_data_write = flash->mst->spi.max_data_write; const unsigned int max_chunk = (max_data_write > 0 && max_data_write <= page_size) ? max_data_write : page_size; uint8_t buf[4 + max_chunk]; |