diff --git a/chipdrivers.h b/chipdrivers.h index 059100e..0835109 100644 --- a/chipdrivers.h +++ b/chipdrivers.h @@ -77,29 +77,26 @@ int write_sector_jedec_common(struct flashchip *flash, uint8_t *src, chipaddr ds /* m29f400bt.c */ int probe_m29f400bt(struct flashchip *flash); int erase_m29f400bt(struct flashchip *flash); int block_erase_m29f400bt(struct flashchip *flash, unsigned int start, unsigned int len); int block_erase_chip_m29f400bt(struct flashchip *flash, unsigned int start, unsigned int len); int write_m29f400bt(struct flashchip *flash, uint8_t *buf); int write_coreboot_m29f400bt(struct flashchip *flash, uint8_t *buf); void protect_m29f400bt(chipaddr bios); void write_page_m29f400bt(chipaddr bios, uint8_t *src, chipaddr dst, int page_size); /* pm49fl00x.c */ -int probe_49fl00x(struct flashchip *flash); -int erase_49fl00x(struct flashchip *flash); -int write_49fl00x(struct flashchip *flash, uint8_t *buf); int unlock_49fl00x(struct flashchip *flash); /* sharplhf00l04.c */ int probe_lhf00l04(struct flashchip *flash); int erase_lhf00l04_block(struct flashchip *flash, unsigned int blockaddr, unsigned int blocklen); int write_lhf00l04(struct flashchip *flash, uint8_t *buf); void protect_lhf00l04(chipaddr bios); /* sst28sf040.c */ int probe_28sf040(struct flashchip *flash); int erase_chip_28sf040(struct flashchip *flash, unsigned int addr, unsigned int blocklen); int erase_sector_28sf040(struct flashchip *flash, unsigned int address, unsigned int sector_size); int write_28sf040(struct flashchip *flash, uint8_t *buf); diff --git a/flashchips.c b/flashchips.c index 45e67c6..5005997 100644 --- a/flashchips.c +++ b/flashchips.c @@ -1296,27 +1296,28 @@ struct flashchip flashchips[] = { .tested = TEST_UNTESTED, .probe = probe_jedec, .probe_timing = TIMING_ZERO, /* routine is wrapper to probe_jedec (pm49fl00x.c) */ .block_erasers = { { .eraseblocks = { {64 * 1024, 8} }, .block_erase = erase_block_jedec, }, { .eraseblocks = { {512 * 1024, 1} }, .block_erase = erase_chip_block_jedec, } }, - .write = write_49fl00x, + .unlock = unlock_49fl00x, + .write = write_jedec_1, .read = read_memmapped, }, { .vendor = "EMST", .name = "F49B002UA", .bustype = CHIP_BUSTYPE_PARALLEL, .manufacture_id = EMST_ID, .model_id = EMST_F49B002UA, .total_size = 256, .page_size = 4096, .feature_bits = FEATURE_EITHER_RESET, .tested = TEST_UNTESTED, @@ -3337,27 +3338,27 @@ struct flashchip flashchips[] = { { { .eraseblocks = { {4 * 1024, 64} }, .block_erase = erase_sector_jedec, }, { .eraseblocks = { {16 * 1024, 16} }, .block_erase = erase_block_jedec, }, { .eraseblocks = { {256 * 1024, 1} }, .block_erase = erase_chip_block_jedec, } }, .unlock = unlock_49fl00x, - .write = write_49fl00x, + .write = write_jedec_1, .read = read_memmapped, }, { .vendor = "PMC", .name = "Pm49FL004", .bustype = CHIP_BUSTYPE_LPC | CHIP_BUSTYPE_FWH, /* A/A Mux*/ .manufacture_id = PMC_ID_NOPREFIX, .model_id = PMC_49FL004, .total_size = 512, .page_size = 64 * 1024, .feature_bits = FEATURE_REGISTERMAP | FEATURE_EITHER_RESET, .tested = TEST_UNTESTED, @@ -3367,27 +3368,27 @@ struct flashchip flashchips[] = { { { .eraseblocks = { {4 * 1024, 128} }, .block_erase = erase_sector_jedec, }, { .eraseblocks = { {64 * 1024, 8} }, .block_erase = erase_block_jedec, }, { .eraseblocks = { {512 * 1024, 1} }, .block_erase = erase_chip_block_jedec, } }, .unlock = unlock_49fl00x, - .write = write_49fl00x, + .write = write_jedec_1, .read = read_memmapped, }, { .vendor = "Sanyo", .name = "LF25FW203A", .bustype = CHIP_BUSTYPE_SPI, .manufacture_id = SANYO_ID, .model_id = SANYO_LE25FW203A, .total_size = 2048, .page_size = 256, .tested = TEST_UNTESTED, .probe = probe_spi_rdid,