1
0
mirror of https://review.coreboot.org/flashrom.git synced 2025-07-01 14:11:15 +02:00

Add support for the following AMIC SPI chips

http://www.amictechnology.com/pdf/A25L20P.pdf covers:
AMIC A25L05PT
AMIC A25L05PU
AMIC A25L10PT
AMIC A25L10PU
AMIC A25L20PT
AMIC A25L20PU
http://www.amictechnology.com/pdf/A25L16P.pdf covers:
AMIC A25L16PT
AMIC A25L16PU

Clarify the situation surrounding the A25L40PT and A25L40PU chips which
share the same RDID values, despite the fact that their erase block
layouts are different.  Rudolf Marek tested and confirmed the distinct
erase block layouts of these chips.

Add a pretty-printer for the AMIC SPI chip status register
Add a generic AMIC chip type.

Corresponding to flashrom svn r1096.

Signed-off-by: Daniel Lenski <dlenski@gmail.com>
Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
This commit is contained in:
Daniel Lenski
2010-07-22 11:44:38 +00:00
committed by Carl-Daniel Hailfinger
parent 74a828a6dd
commit df90d3a38f
3 changed files with 309 additions and 6 deletions

14
spi25.c
View File

@ -327,6 +327,16 @@ void spi_prettyprint_status_register_common(uint8_t status)
"%sset\n", (status & (1 << 0)) ? "" : "not ");
}
/* Prettyprint the status register. Works for
* AMIC A25L series
*/
void spi_prettyprint_status_register_amic_a25l(uint8_t status)
{
msg_cdbg("Chip status register: Status Register Write Disable "
"(SRWD) is %sset\n", (status & (1 << 7)) ? "" : "not ");
spi_prettyprint_status_register_common(status);
}
/* Prettyprint the status register. Works for
* ST M25P series
* MX MX25L series
@ -389,6 +399,10 @@ void spi_prettyprint_status_register(struct flashchip *flash)
status = spi_read_status_register();
msg_cdbg("Chip status register is %02x\n", status);
switch (flash->manufacture_id) {
case AMIC_ID:
if ((flash->model_id & 0xff00) == 0x2000)
spi_prettyprint_status_register_amic_a25l(status);
break;
case ST_ID:
if (((flash->model_id & 0xff00) == 0x2000) ||
((flash->model_id & 0xff00) == 0x2500))