Re: Ingenic T31

2023-12-21 Thread Andrew Walsh
Great responses everyone.
I am feeding these through to a group running openIPC using Ingenic T31.
See https://github.com/HackerHomestead/teacup
Having openOCD on a dev board like this would be ideal.
I think one of us has already found a pin used to put it into JTAG mode.
Documentation is not the best!
Once I get anything definitive I will post back.

Regards
Andrew.


On Thu, Dec 21, 2023 at 11:41 PM Daniel Glöckner  wrote:

> On Thu, Dec 21, 2023 at 11:40:26AM +0100, Oleksij Rempel wrote:
> > "Ingenic Xburst" is kind of special architecture, not 100% compatible
> with MIPS 4K,
> > but latest OpenOCD version already includes some of Xburst quirks. With
> other words,
> > there is a good chance to have some kind of working starting point.
>
> I know of 3 quirks I had to do to make it work with the JZ4730:
>
>  - Branch target buffer needs to be disabled before doing first branch
>in debug mode
>
>  - Writing 1 to ROCC is not ignored
>
>  - Entering Pause-IR and Pause-DR causes changes to IR/DR to be
>lost
>
> I know the last one was fixed for some JTAG adapters by never idling in
> Pause-*R, which is possible because we can usually stop TCK. But for which
> of the other two issues has a workaround been merged? All I can find is
> a commit that says that JZ4780 needs NOPs after DRET.
>
> Best regards,
>
>   Daniel
>


Re: Ingenic T31

2023-12-21 Thread Daniel Glöckner
On Thu, Dec 21, 2023 at 11:40:26AM +0100, Oleksij Rempel wrote:
> "Ingenic Xburst" is kind of special architecture, not 100% compatible with 
> MIPS 4K,
> but latest OpenOCD version already includes some of Xburst quirks. With other 
> words,
> there is a good chance to have some kind of working starting point.

I know of 3 quirks I had to do to make it work with the JZ4730:

 - Branch target buffer needs to be disabled before doing first branch
   in debug mode

 - Writing 1 to ROCC is not ignored

 - Entering Pause-IR and Pause-DR causes changes to IR/DR to be
   lost

I know the last one was fixed for some JTAG adapters by never idling in
Pause-*R, which is possible because we can usually stop TCK. But for which
of the other two issues has a workaround been merged? All I can find is
a commit that says that JZ4780 needs NOPs after DRET.

Best regards,

  Daniel



Re: Ingenic T31

2023-12-21 Thread Oleksij Rempel

Hi Andrew,

Am 20.12.23 um 04:15 schrieb Andrew Walsh:

This is a MIPS32 based embedded Linux device with UART pins multiplexed as JTAG.
There is very little information provided by Ingenic on the use of these pins 
as JTAG.
I would like to know if it is possible to get openocd working on this chip if 
we can break out these
pins.




Your docs say compatible with mips_4k.
Here is some info on our core.
Do you think it is possible to get openocd working here or is it a lost cause?


"Ingenic Xburst" is kind of special architecture, not 100% compatible with MIPS 
4K,
but latest OpenOCD version already includes some of Xburst quirks. With other 
words,
there is a good chance to have some kind of working starting point.

--
Regards,
Oleksij