X-Git-Url: https://review.openocd.org/gitweb?a=blobdiff_plain;f=src%2Fflash%2Fnor%2Fstellaris.c;h=4e043222c0dceb288c903b4b6d870c90844efbf3;hb=017a202086603119793d8da56989591512d08ed0;hp=96a15d428191a465e0f5cce35ab3129fda8e02bd;hpb=7743e0fb4390d09c315ce9c6edbb2c3ba6b8c2d9;p=openocd.git diff --git a/src/flash/nor/stellaris.c b/src/flash/nor/stellaris.c index 96a15d4281..4e043222c0 100644 --- a/src/flash/nor/stellaris.c +++ b/src/flash/nor/stellaris.c @@ -18,7 +18,7 @@ * You should have received a copy of the GNU General Public License * * along with this program; if not, write to the * * Free Software Foundation, Inc., * - * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. * ***************************************************************************/ /*************************************************************************** @@ -124,7 +124,7 @@ struct stellaris_flash_bank { }; /* Autogenerated by contrib/gen-stellaris-part-header.pl */ -/* From Stellaris Firmware Development Package revision 8049 */ +/* From Stellaris Firmware Development Package revision 9453 */ static struct { uint8_t class; uint8_t partno; @@ -189,7 +189,6 @@ static struct { {0x04, 0xC9, "LM3S1R26"}, {0x04, 0x30, "LM3S1W16"}, {0x04, 0x2F, "LM3S1Z16"}, - {0x01, 0xD4, "LM3S2016"}, {0x01, 0x51, "LM3S2110"}, {0x01, 0x84, "LM3S2139"}, {0x03, 0x39, "LM3S2276"}, @@ -301,9 +300,7 @@ static struct { {0x01, 0x8B, "LM3S6637"}, {0x01, 0xA3, "LM3S6730"}, {0x01, 0x77, "LM3S6753"}, - {0x01, 0xD1, "LM3S6816"}, {0x01, 0xE9, "LM3S6911"}, - {0x01, 0xD3, "LM3S6916"}, {0x01, 0xE8, "LM3S6918"}, {0x01, 0x89, "LM3S6938"}, {0x01, 0x72, "LM3S6950"}, @@ -350,11 +347,9 @@ static struct { {0x04, 0x1E, "LM3S9BN5"}, {0x04, 0x1F, "LM3S9BN6"}, {0x06, 0x70, "LM3S9C97"}, - {0x06, 0x7A, "LM3S9CN5"}, {0x06, 0xA9, "LM3S9D81"}, {0x06, 0x7E, "LM3S9D90"}, {0x06, 0x92, "LM3S9D92"}, - {0x06, 0xC8, "LM3S9D95"}, {0x06, 0x9D, "LM3S9D96"}, {0x06, 0x7B, "LM3S9DN5"}, {0x06, 0x7C, "LM3S9DN6"}, @@ -365,7 +360,6 @@ static struct { {0x06, 0xA8, "LM3S9U81"}, {0x06, 0x7D, "LM3S9U90"}, {0x06, 0x90, "LM3S9U92"}, - {0x06, 0xB7, "LM3S9U95"}, {0x06, 0x9B, "LM3S9U96"}, {0x05, 0x18, "LM4F110B2QR"}, {0x05, 0x19, "LM4F110C4QR"}, @@ -401,6 +395,13 @@ static struct { {0x05, 0x60, "LM4F132E5QC"}, {0x05, 0x61, "LM4F132H5QC"}, {0x05, 0x65, "LM4F132H5QD"}, + {0x05, 0x70, "LM4F210E5QR"}, + {0x05, 0x73, "LM4F210H5QR"}, + {0x05, 0x80, "LM4F211E5QR"}, + {0x05, 0x83, "LM4F211H5QR"}, + {0x05, 0xE9, "LM4F212H5BB"}, + {0x05, 0xC4, "LM4F212H5QC"}, + {0x05, 0xC6, "LM4F212H5QD"}, {0x05, 0xA0, "LM4F230E5QR"}, {0x05, 0xA1, "LM4F230H5QR"}, {0x05, 0xB0, "LM4F231E5QR"}, @@ -410,8 +411,9 @@ static struct { {0x05, 0xC1, "LM4F232H5QC"}, {0x05, 0xC5, "LM4F232H5QD"}, {0x05, 0xE5, "LM4FS1AH5BB"}, + {0x05, 0xEA, "LM4FS1GH5BB"}, {0x05, 0xE4, "LM4FS99H5BB"}, - {0x05, 0xE0, "LM4FSXAH5BB"}, + {0x05, 0xE1, "LM4FSXLH5BB"}, {0xFF, 0x00, "Unknown Part"} }; @@ -1031,20 +1033,19 @@ static int stellaris_write_block(struct flash_bank *bank, while (target_alloc_working_area_try(target, buffer_size, &source) != ERROR_OK) { buffer_size /= 2; if (buffer_size <= buf_min) { - if (write_algorithm) - target_free_working_area(target, write_algorithm); + target_free_working_area(target, write_algorithm); return ERROR_TARGET_RESOURCE_NOT_AVAILABLE; } LOG_DEBUG("retry target_alloc_working_area(%s, size=%u)", target_name(target), (unsigned) buffer_size); }; - retval = target_write_buffer(target, write_algorithm->address, + target_write_buffer(target, write_algorithm->address, sizeof(stellaris_write_code), (uint8_t *) stellaris_write_code); armv7m_info.common_magic = ARMV7M_COMMON_MAGIC; - armv7m_info.core_mode = ARMV7M_MODE_ANY; + armv7m_info.core_mode = ARM_MODE_THREAD; init_reg_param(®_params[0], "r0", 32, PARAM_OUT); init_reg_param(®_params[1], "r1", 32, PARAM_OUT); @@ -1398,7 +1399,7 @@ struct flash_driver stellaris_flash = { .read = default_flash_read, .probe = stellaris_probe, .auto_probe = stellaris_probe, - .erase_check = default_flash_mem_blank_check, + .erase_check = default_flash_blank_check, .protect_check = stellaris_protect_check, .info = get_stellaris_info, };