- Reducing stack usage for recursive scripts
- Do not exit on bogus arguments to reset_config. No longer exit the application upon bogus arguments to reset_config, but return errors.
thanks to Øyvind Harboe for these patches.
git-svn-id: svn://svn.berlios.de/openocd/trunk@226
b42882b7-edfa-0310-969c-
e2dbd0fdcd60
int at91sam7_protect(struct flash_bank_s *bank, int set, int first, int last)
{
int at91sam7_protect(struct flash_bank_s *bank, int set, int first, int last)
{
- u32 cmd, pagen, status;
u8 flashplane;
int lockregion;
u8 flashplane;
int lockregion;
int printed;
cfi_flash_bank_t *cfi_info = bank->driver_priv;
int printed;
cfi_flash_bank_t *cfi_info = bank->driver_priv;
- if (cfi_info->qry[0] == -1)
+ if (cfi_info->qry[0] == (char)-1)
{
printed = snprintf(buf, buf_size, "\ncfi flash bank not probed yet\n");
return ERROR_OK;
{
printed = snprintf(buf, buf_size, "\ncfi flash bank not probed yet\n");
return ERROR_OK;
{
int retval = ERROR_OK;
int old_command_mode;
{
int retval = ERROR_OK;
int old_command_mode;
+ char *buffer=malloc(4096);
+ if (buffer==NULL)
+ {
+ return ERROR_INVALID_ARGUMENTS;
+ }
old_command_mode = context->mode;
context->mode = mode;
old_command_mode = context->mode;
context->mode = mode;
}
context->mode = old_command_mode;
}
context->mode = old_command_mode;
if (validate_tries > 5)
{
ERROR("Could not validate JTAG chain, exit");
if (validate_tries > 5)
{
ERROR("Could not validate JTAG chain, exit");
+ jtag = NULL;
+ return ERROR_JTAG_INVALID_INTERFACE;
jtag_reset_config = RESET_TRST_AND_SRST;
else
{
jtag_reset_config = RESET_TRST_AND_SRST;
else
{
- ERROR("invalid reset_config argument");
- exit(-1);
+ ERROR("invalid reset_config argument, defaulting to none");
+ jtag_reset_config = RESET_NONE;
+ return ERROR_INVALID_ARGUMENTS;
jtag_reset_config &= ~(RESET_SRST_PULLS_TRST | RESET_TRST_PULLS_SRST);
else
{
jtag_reset_config &= ~(RESET_SRST_PULLS_TRST | RESET_TRST_PULLS_SRST);
else
{
- ERROR("invalid reset_config argument");
- exit(-1);
+ ERROR("invalid reset_config argument, defaulting to none");
+ jtag_reset_config = RESET_NONE;
+ return ERROR_INVALID_ARGUMENTS;
jtag_reset_config &= ~RESET_TRST_OPEN_DRAIN;
else
{
jtag_reset_config &= ~RESET_TRST_OPEN_DRAIN;
else
{
- ERROR("invalid reset_config argument");
- exit(-1);
+ ERROR("invalid reset_config argument, defaulting to none");
+ jtag_reset_config = RESET_NONE;
+ return ERROR_INVALID_ARGUMENTS;
jtag_reset_config &= ~RESET_SRST_PUSH_PULL;
else
{
jtag_reset_config &= ~RESET_SRST_PUSH_PULL;
else
{
- ERROR("invalid reset_config argument");
- exit(-1);
+ ERROR("invalid reset_config argument, defaulting to none");
+ jtag_reset_config = RESET_NONE;
+ return ERROR_INVALID_ARGUMENTS;
Linking to existing account procedure
If you already have an account and want to add another login method
you
MUST first sign in with your existing account and
then change URL to read
https://review.openocd.org/login/?link
to get to this page again but this time it'll work for linking. Thank you.
SSH host keys fingerprints
1024 SHA256:YKx8b7u5ZWdcbp7/4AeXNaqElP49m6QrwfXaqQGJAOk gerrit-code-review@openocd.zylin.com (DSA)
384 SHA256:jHIbSQa4REvwCFG4cq5LBlBLxmxSqelQPem/EXIrxjk gerrit-code-review@openocd.org (ECDSA)
521 SHA256:UAOPYkU9Fjtcao0Ul/Rrlnj/OsQvt+pgdYSZ4jOYdgs gerrit-code-review@openocd.org (ECDSA)
256 SHA256:A13M5QlnozFOvTllybRZH6vm7iSt0XLxbA48yfc2yfY gerrit-code-review@openocd.org (ECDSA)
256 SHA256:spYMBqEYoAOtK7yZBrcwE8ZpYt6b68Cfh9yEVetvbXg gerrit-code-review@openocd.org (ED25519)
+--[ED25519 256]--+
|=.. |
|+o.. . |
|*.o . . |
|+B . . . |
|Bo. = o S |
|Oo.+ + = |
|oB=.* = . o |
| =+=.+ + E |
|. .=o . o |
+----[SHA256]-----+
2048 SHA256:0Onrb7/PHjpo6iVZ7xQX2riKN83FJ3KGU0TvI0TaFG4 gerrit-code-review@openocd.zylin.com (RSA)