mirror of
https://review.coreboot.org/flashrom.git
synced 2025-07-01 22:21:16 +02:00
Add support for RayeR SPIPGM hardware as described in http://rayer.ic.cz/elektro/spipgm.htm
To use the RayeR driver, run flashrom -p rayer_spi -V Known bugs/limitations: - Won't compile/work on non-x86 architectures. - Will always use direct port I/O access. Log follows: flashrom v0.9.2-r1039 on MS-DOS 7 (i686), built with libpci 3.1.5, GCC 4.3.2, little endian Calibrating delay loop... OK. Initializing rayer_bitbang_spi programmer Using port 0x378 as I/O base for parallel port access. ... Probing for Macronix MX25L1605, 2048 KB: probe_spi_rdid_generic: id1 0xc2, id2 0x2015 ... Found chip "Macronix MX25L1605" (2048 KB, SPI) at physical address 0xffe00000. ... No operations were specified. Corresponding to flashrom svn r1093. Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net> Acked-by: Martin Rehak <rayer@seznam.cz> Acked-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
This commit is contained in:
14
flash.h
14
flash.h
@ -80,6 +80,9 @@ enum programmer {
|
||||
#endif
|
||||
#if CONFIG_DEDIPROG == 1
|
||||
PROGRAMMER_DEDIPROG,
|
||||
#endif
|
||||
#if CONFIG_RAYER_SPI == 1
|
||||
PROGRAMMER_RAYER_SPI,
|
||||
#endif
|
||||
PROGRAMMER_INVALID /* This must always be the last entry. */
|
||||
};
|
||||
@ -129,6 +132,9 @@ void programmer_delay(int usecs);
|
||||
|
||||
enum bitbang_spi_master_type {
|
||||
BITBANG_SPI_INVALID = 0, /* This must always be the first entry. */
|
||||
#if CONFIG_RAYER_SPI == 1
|
||||
BITBANG_SPI_MASTER_RAYER,
|
||||
#endif
|
||||
};
|
||||
|
||||
struct bitbang_spi_master {
|
||||
@ -531,6 +537,11 @@ int ft2232_spi_send_command(unsigned int writecnt, unsigned int readcnt, const u
|
||||
int ft2232_spi_read(struct flashchip *flash, uint8_t *buf, int start, int len);
|
||||
int ft2232_spi_write_256(struct flashchip *flash, uint8_t *buf, int start, int len);
|
||||
|
||||
/* rayer_spi.c */
|
||||
#if CONFIG_RAYER_SPI == 1
|
||||
int rayer_spi_init(void);
|
||||
#endif
|
||||
|
||||
/* bitbang_spi.c */
|
||||
int bitbang_spi_init(const struct bitbang_spi_master *master, int halfperiod);
|
||||
int bitbang_spi_send_command(unsigned int writecnt, unsigned int readcnt, const unsigned char *writearr, unsigned char *readarr);
|
||||
@ -649,6 +660,9 @@ enum spi_controller {
|
||||
#endif
|
||||
#if CONFIG_DEDIPROG == 1
|
||||
SPI_CONTROLLER_DEDIPROG,
|
||||
#endif
|
||||
#if CONFIG_RAYER_SPI == 1
|
||||
SPI_CONTROLLER_RAYER,
|
||||
#endif
|
||||
SPI_CONTROLLER_INVALID /* This must always be the last entry. */
|
||||
};
|
||||
|
Reference in New Issue
Block a user