This is an automated email from Gerrit. Oleksij Rempel (li...@rempel-privat.de) just uploaded a new patch set to Gerrit, which you can find at http://openocd.zylin.com/1931
-- gerrit commit a095f2df55288e05b0c083e441e42fe43be1b829 Author: Oleksij Rempel <li...@rempel-privat.de> Date: Tue Jan 21 20:48:14 2014 +0100 mips32.c: fix IB and DB bits check for EJTAG v2.0 Change-Id: I4e28dddc1d5d9c2b923ae17beacdd7f73591b1d0 Signed-off-by: Oleksij Rempel <li...@rempel-privat.de> diff --git a/src/target/mips32.c b/src/target/mips32.c index 188e88b..a2e4db1 100644 --- a/src/target/mips32.c +++ b/src/target/mips32.c @@ -540,10 +540,15 @@ int mips32_configure_break_unit(struct target *target) if (retval != ERROR_OK) return retval; - /* EJTAG 2.0 does not specify EJTAG_DCR_IB and EJTAG_DCR_DB bits, - * assume IB and DB registers are always present. */ - if (ejtag_info->ejtag_version == EJTAG_VERSION_20) - dcr |= EJTAG_DCR_IB | EJTAG_DCR_DB; + /* EJTAG 2.0 set IB and DB bits in IMP instead of DCR. + * Since this DCR bits should be reseved on DCR 2.0, we can + * just remap them. */ + if (ejtag_info->ejtag_version == EJTAG_VERSION_20) { + if (!(ejtag_info->impcode & EJTAG_V20_IMP_NOIB)) + dcr |= EJTAG_DCR_IB; + if (!(ejtag_info->impcode & EJTAG_V20_IMP_NODB)) + dcr |= EJTAG_DCR_DB; + } if (dcr & EJTAG_DCR_IB) { retval = mips32_configure_ibs(target); -- ------------------------------------------------------------------------------ Managing the Performance of Cloud-Based Applications Take advantage of what the Cloud has to offer - Avoid Common Pitfalls. Read the Whitepaper. http://pubads.g.doubleclick.net/gampad/clk?id=121051231&iu=/4140/ostg.clktrk _______________________________________________ OpenOCD-devel mailing list OpenOCD-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openocd-devel