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

Add support for Olimex programmers to ft2232_spi

- add support for Olimex' ARM-USB-TINY, ARM-USB-TINY-H, ARM-USB-OCD
AND ARM-USB-OCD-H and adjust man page - minor string change ("First
International Computer, Inc." -> "FIC")

Corresponding to flashrom svn r1331.

Signed-off-by: Pete Batard <pbatard@gmail.com>
Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
This commit is contained in:
Pete Batard
2011-06-11 12:21:37 +00:00
committed by Stefan Tauner
parent 5520694cab
commit c020706948
2 changed files with 31 additions and 5 deletions

View File

@ -183,7 +183,7 @@ cards)"
.BR "* it87spi" " (for flash ROMs behind an ITE IT87xx Super I/O LPC/SPI \ .BR "* it87spi" " (for flash ROMs behind an ITE IT87xx Super I/O LPC/SPI \
translation unit)" translation unit)"
.sp .sp
.BR "* ft2232_spi" " (for SPI flash ROMs attached to a FT2232H/FT4232H/JTAGkey \ .BR "* ft2232_spi" " (for SPI flash ROMs attached to an FT2232/FT4232H family \
based USB SPI programmer)" based USB SPI programmer)"
.sp .sp
.BR "* serprog" " (for flash ROMs attached to a programmer speaking serprog)" .BR "* serprog" " (for flash ROMs attached to a programmer speaking serprog)"
@ -361,8 +361,9 @@ type and interface/port it should support. For that you have to use the
.sp .sp
syntax where syntax where
.B model .B model
can be any of can be one of
.BR 2232H ", " JTAGkey ", or " 4232H .BR 2232H ", " 4232H ", " jtagkey ", " openmoko ", " arm-usb-tiny ", " \
arm-usb-tiny-h ", " arm-usb-ocd " or " arm-usb-ocd-h
and and
.B interface .B interface
can be any of can be any of

View File

@ -38,13 +38,22 @@
#define FIC_VID 0x1457 #define FIC_VID 0x1457
#define OPENMOKO_DBGBOARD_PID 0x5118 #define OPENMOKO_DBGBOARD_PID 0x5118
#define OLIMEX_VID 0x15BA
#define OLIMEX_ARM_OCD_PID 0x0003
#define OLIMEX_ARM_TINY_PID 0x0004
#define OLIMEX_ARM_OCD_H_PID 0x002B
#define OLIMEX_ARM_TINY_H_PID 0x002A
const struct usbdev_status devs_ft2232spi[] = { const struct usbdev_status devs_ft2232spi[] = {
{FTDI_VID, FTDI_FT2232H_PID, OK, "FTDI", "FT2232H"}, {FTDI_VID, FTDI_FT2232H_PID, OK, "FTDI", "FT2232H"},
{FTDI_VID, FTDI_FT4232H_PID, OK, "FTDI", "FT4232H"}, {FTDI_VID, FTDI_FT4232H_PID, OK, "FTDI", "FT4232H"},
{FTDI_VID, AMONTEC_JTAGKEY_PID, OK, "Amontec", "JTAGkey"}, {FTDI_VID, AMONTEC_JTAGKEY_PID, OK, "Amontec", "JTAGkey"},
{FIC_VID, OPENMOKO_DBGBOARD_PID, OK, {FIC_VID, OPENMOKO_DBGBOARD_PID, OK, "FIC",
"First International Computer, Inc.",
"OpenMoko Neo1973 Debug board (V2+)"}, "OpenMoko Neo1973 Debug board (V2+)"},
{OLIMEX_VID, OLIMEX_ARM_OCD_PID, NT, "Olimex", "ARM-USB-OCD"},
{OLIMEX_VID, OLIMEX_ARM_TINY_PID, OK, "Olimex", "ARM-USB-TINY"},
{OLIMEX_VID, OLIMEX_ARM_OCD_H_PID, NT, "Olimex", "ARM-USB-OCD-H"},
{OLIMEX_VID, OLIMEX_ARM_TINY_H_PID, NT, "Olimex", "ARM-USB-TINY-H"},
{}, {},
}; };
@ -167,6 +176,22 @@ int ft2232_spi_init(void)
ft2232_vid = FIC_VID; ft2232_vid = FIC_VID;
ft2232_type = OPENMOKO_DBGBOARD_PID; ft2232_type = OPENMOKO_DBGBOARD_PID;
ft2232_interface = INTERFACE_A; ft2232_interface = INTERFACE_A;
} else if (!strcasecmp(arg, "arm-usb-ocd")) {
ft2232_vid = OLIMEX_VID;
ft2232_type = OLIMEX_ARM_OCD_PID;
ft2232_interface = INTERFACE_A;
} else if (!strcasecmp(arg, "arm-usb-tiny")) {
ft2232_vid = OLIMEX_VID;
ft2232_type = OLIMEX_ARM_TINY_PID;
ft2232_interface = INTERFACE_A;
} else if (!strcasecmp(arg, "arm-usb-ocd-h")) {
ft2232_vid = OLIMEX_VID;
ft2232_type = OLIMEX_ARM_OCD_H_PID;
ft2232_interface = INTERFACE_A;
} else if (!strcasecmp(arg, "arm-usb-tiny-h")) {
ft2232_vid = OLIMEX_VID;
ft2232_type = OLIMEX_ARM_TINY_H_PID;
ft2232_interface = INTERFACE_A;
} else { } else {
msg_perr("Error: Invalid device type specified.\n"); msg_perr("Error: Invalid device type specified.\n");
free(arg); free(arg);