* Copyright (C) 2005 by Dominic Rath *
* Dominic.Rath@gmx.de *
* *
- * Copyright (C) 2007,2008,2009 Øyvind Harboe *
+ * Copyright (C) 2007-2010 Øyvind Harboe *
* oyvind.harboe@zylin.com *
* *
* Copyright (C) 2008 by Spencer Oliver *
uint8_t field1_out[1];
uint8_t field2_out[1];
- jtag_set_end_state(TAP_IDLE);
- arm_jtag_scann(ice_reg->jtag_info, 0x2);
+ arm_jtag_scann(ice_reg->jtag_info, 0x2, TAP_IDLE);
- arm_jtag_set_instr(ice_reg->jtag_info, ice_reg->jtag_info->intest_instr, NULL);
+ arm_jtag_set_instr(ice_reg->jtag_info, ice_reg->jtag_info->intest_instr, NULL, TAP_IDLE);
/* bits 31:0 -- data (ignored here) */
fields[0].num_bits = 32;
/* bits 36:32 -- register */
fields[1].num_bits = 5;
fields[1].out_value = field1_out;
- fields[1].out_value[0] = reg_addr;
+ field1_out[0] = reg_addr;
fields[1].in_value = NULL;
fields[1].check_value = NULL;
fields[1].check_mask = NULL;
/* bit 37 -- 0/read */
fields[2].num_bits = 1;
fields[2].out_value = field2_out;
- fields[2].out_value[0] = 0;
+ field2_out[0] = 0;
fields[2].in_value = NULL;
fields[2].check_value = NULL;
fields[2].check_mask = NULL;
* EICE_COMMS_DATA would read the register twice
* reading the control register is safe
*/
- fields[1].out_value[0] = eice_regs[EICE_COMMS_CTRL].addr;
+ field1_out[0] = eice_regs[EICE_COMMS_CTRL].addr;
/* traverse Update-DR, reading but with no other side effects */
jtag_add_dr_scan_check(ice_reg->jtag_info->tap, 3, fields, TAP_IDLE);
uint8_t field1_out[1];
uint8_t field2_out[1];
- jtag_set_end_state(TAP_IDLE);
- arm_jtag_scann(jtag_info, 0x2);
- arm_jtag_set_instr(jtag_info, jtag_info->intest_instr, NULL);
+ arm_jtag_scann(jtag_info, 0x2, TAP_IDLE);
+ arm_jtag_set_instr(jtag_info, jtag_info->intest_instr, NULL, TAP_IDLE);
fields[0].num_bits = 32;
fields[0].out_value = NULL;
fields[1].num_bits = 5;
fields[1].out_value = field1_out;
- fields[1].out_value[0] = eice_regs[EICE_COMMS_DATA].addr;
+ field1_out[0] = eice_regs[EICE_COMMS_DATA].addr;
fields[1].in_value = NULL;
fields[2].num_bits = 1;
fields[2].out_value = field2_out;
- fields[2].out_value[0] = 0;
+ field2_out[0] = 0;
fields[2].in_value = NULL;
jtag_add_dr_scan(jtag_info->tap, 3, fields, TAP_IDLE);
* to avoid reading additional data from the DCC data reg
*/
if (size == 1)
- fields[1].out_value[0] = eice_regs[EICE_COMMS_CTRL].addr;
+ field1_out[0] = eice_regs[EICE_COMMS_CTRL].addr;
fields[0].in_value = (uint8_t *)data;
jtag_add_dr_scan(jtag_info->tap, 3, fields, TAP_IDLE);
LOG_DEBUG("%i: 0x%8.8" PRIx32 "", ice_reg->addr, value);
- jtag_set_end_state(TAP_IDLE);
- arm_jtag_scann(ice_reg->jtag_info, 0x2);
+ arm_jtag_scann(ice_reg->jtag_info, 0x2, TAP_IDLE);
- arm_jtag_set_instr(ice_reg->jtag_info, ice_reg->jtag_info->intest_instr, NULL);
+ arm_jtag_set_instr(ice_reg->jtag_info, ice_reg->jtag_info->intest_instr, NULL, TAP_IDLE);
uint8_t reg_addr = ice_reg->addr & 0x1f;
embeddedice_write_reg_inner(ice_reg->jtag_info->tap, reg_addr, value);
uint8_t field1_out[1];
uint8_t field2_out[1];
- jtag_set_end_state(TAP_IDLE);
- arm_jtag_scann(jtag_info, 0x2);
- arm_jtag_set_instr(jtag_info, jtag_info->intest_instr, NULL);
+ arm_jtag_scann(jtag_info, 0x2, TAP_IDLE);
+ arm_jtag_set_instr(jtag_info, jtag_info->intest_instr, NULL, TAP_IDLE);
fields[0].num_bits = 32;
fields[0].out_value = field0_out;
fields[1].num_bits = 5;
fields[1].out_value = field1_out;
- fields[1].out_value[0] = eice_regs[EICE_COMMS_DATA].addr;
+ field1_out[0] = eice_regs[EICE_COMMS_DATA].addr;
fields[1].in_value = NULL;
fields[2].num_bits = 1;
fields[2].out_value = field2_out;
- fields[2].out_value[0] = 1;
+ field2_out[0] = 1;
fields[2].in_value = NULL;
while (size > 0)
{
- buf_set_u32(fields[0].out_value, 0, 32, *data);
+ buf_set_u32(field0_out, 0, 32, *data);
jtag_add_dr_scan(jtag_info->tap, 3, fields, TAP_IDLE);
data++;
else
return ERROR_INVALID_ARGUMENTS;
- jtag_set_end_state(TAP_IDLE);
- arm_jtag_scann(jtag_info, 0x2);
- arm_jtag_set_instr(jtag_info, jtag_info->intest_instr, NULL);
+ arm_jtag_scann(jtag_info, 0x2, TAP_IDLE);
+ arm_jtag_set_instr(jtag_info, jtag_info->intest_instr, NULL, TAP_IDLE);
fields[0].num_bits = 32;
fields[0].out_value = NULL;
fields[1].num_bits = 5;
fields[1].out_value = field1_out;
- fields[1].out_value[0] = eice_regs[EICE_COMMS_DATA].addr;
+ field1_out[0] = eice_regs[EICE_COMMS_DATA].addr;
fields[1].in_value = NULL;
fields[2].num_bits = 1;
fields[2].out_value = field2_out;
- fields[2].out_value[0] = 0;
+ field2_out[0] = 0;
fields[2].in_value = NULL;
jtag_add_dr_scan(jtag_info->tap, 3, fields, TAP_IDLE);