From 29134f1238560fe97e063293e81abc570d5ee4b7 Mon Sep 17 00:00:00 2001 From: Kolja Waschk Date: Sat, 19 Apr 2008 11:31:39 +0000 Subject: [PATCH] [ 1946559 ] Support for Mitsubishi Flash Chips git-svn-id: https://urjtag.svn.sourceforge.net/svnroot/urjtag/trunk@1177 b68d4a1b-bc3d-0410-92ed-d4ac073336b7 --- jtag/ChangeLog | 3 +++ jtag/THANKS | 1 + jtag/src/flash/intel.c | 15 ++++++++++++--- 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/jtag/ChangeLog b/jtag/ChangeLog index 6d5a19ae..9cfd4abe 100644 --- a/jtag/ChangeLog +++ b/jtag/ChangeLog @@ -1,5 +1,8 @@ 2008-04-19 Kolja Waschk + * src/flash/intel.c: Handle chips that support "Mitsubishi + standard/enhanced command set" just like Intel chips. Need + to do more research about the differences (if any) [1946559] * src/tap/cable/usbblaster.c: clock() at highest possible rate using the byte shift mode for n>=8 (Thanks M. Banditt) * include/cmd.h, src/cmd/cmd.c, src/jtag.c: [ 1946331 ] command diff --git a/jtag/THANKS b/jtag/THANKS index eaf26754..25182ec4 100644 --- a/jtag/THANKS +++ b/jtag/THANKS @@ -29,6 +29,7 @@ Jiun-Shian Ho Jachym Holecek August Hörandl Rojhalat Ibrahim +Andrey F. Ilchuk Wojtek Kaniewski Stas Khirman Matej Kupljen diff --git a/jtag/src/flash/intel.c b/jtag/src/flash/intel.c index 24c5f74a..3e1bbb38 100644 --- a/jtag/src/flash/intel.c +++ b/jtag/src/flash/intel.c @@ -61,7 +61,9 @@ intel_flash_autodetect32( cfi_array_t *cfi_array ) if (bus_area( cfi_array->bus, cfi_array->address, &area ) != 0) return 0; - return ((cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_INTEL_ECS) + return ((cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_MITSUBISHI_SCS) + || (cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_MITSUBISHI_ECS) + || (cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_INTEL_ECS) || (cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_INTEL_SCS)) && (area.width == 32); } @@ -74,7 +76,9 @@ intel_flash_autodetect( cfi_array_t *cfi_array ) if (bus_area( cfi_array->bus, cfi_array->address, &area ) != 0) return 0; - return ((cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_INTEL_ECS) + return ((cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_MITSUBISHI_SCS) + || (cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_MITSUBISHI_ECS) + || (cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_INTEL_ECS) || (cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_INTEL_SCS)) && (area.width == 16); } @@ -87,7 +91,9 @@ intel_flash_autodetect8( cfi_array_t *cfi_array ) if (bus_area( cfi_array->bus, cfi_array->address, &area ) != 0) return 0; - return ((cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_INTEL_ECS) + return ((cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_MITSUBISHI_SCS) + || (cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_MITSUBISHI_ECS) + || (cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_INTEL_ECS) || (cfi_array->cfi_chips[0]->cfi.identification_string.pri_id_code == CFI_VENDOR_INTEL_SCS)) && (area.width == 8); } @@ -103,6 +109,9 @@ _intel_flash_print_info( cfi_array_t *cfi_array, int o ) case STD_MIC_INTEL: printf( _("Manufacturer: %s\n"), STD_MICN_INTEL ); break; + case STD_MIC_MITSUBISHI: + printf( _("Manufacturer: %s\n"), STD_MICN_MITSUBISHI ); + break; default: printf( _("Unknown manufacturer (0x%04X)!\n"), mid); break;