From a400554d4d2960edf16d40a4fcc8040b3e2f6d74 Mon Sep 17 00:00:00 2001 From: hailfinger Date: Sat, 19 Jul 2014 22:03:29 +0000 Subject: 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. Signed-off-by: Carl-Daniel Hailfinger Acked-by: Stefan Tauner git-svn-id: https://code.coreboot.org/svn/flashrom/trunk@1831 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1 --- at45db.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'at45db.c') diff --git a/at45db.c b/at45db.c index 5396d7f..3293a85 100644 --- a/at45db.c +++ b/at45db.c @@ -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]; -- cgit v1.2.1