1
0
Fork 0
forked from len0rd/rockbox
foxbox/utils/hwstub/tools
Amaury Pouly fdb98c258f hwstub/jz4760b: add lua code to probe for ei/di and ext instructions
Add lua code to check whether ei/di and ext instructions are supported. This
is unclear since xburst is somewhere between mips32r1 and mips32r2. Details
results are below, but in summary: they don't work (ei has no effect, di/ext
cause illegal instruction exceptions)

> ./hwstub_shell -q -b -e 'require("jz/misc"); JZ.misc.enable_sram()' \
  -f lua/xburst.lua -e "XBURST.test_ext_inst(0xb32d0000)"
[...]
Selecting soc jz4760b. Redirecting HW to hwstub.soc.jz4760b
  data: d7168acf
error: lua/xburst.lua:209: call failed
trapped exception in call

> ./hwstub_shell -q -b -e 'require("jz/misc"); JZ.misc.enable_sram()' \
  -f lua/xburst.lua -e "XBURST.test_ei_di_inst(0xb32d0000)"
[...]
Selecting soc jz4760b. Redirecting HW to hwstub.soc.jz4760b
Testing ei
  Test SR
    Enable interrupts with CP0
    SR: 0x1
    Disable interrupts with CP0
    SR: 0x0
  Test ei/di
    Enable interrupts with ei
    SR: 0x0
    Disable interrupts with di
error: lua/xburst.lua:244: call failed
trapped exception in call

Change-Id: I2e162b5dd5e70488bcd8b58f3ca401a3ecab3c4b
2017-01-24 15:34:20 +01:00
..
lua hwstub/jz4760b: add lua code to probe for ei/di and ext instructions 2017-01-24 15:34:20 +01:00
hwstub_dump.cpp hwstub: add tool to dump memory regions (such as ROM, RAM, or peripherals) 2017-01-24 15:34:19 +01:00
hwstub_load.cpp hwstub: small fixes to argument processing and usage() 2017-01-24 15:34:05 +01:00
hwstub_server.cpp hwstub: rewrite and expand library 2016-04-08 19:37:30 +02:00
hwstub_shell.cpp hwstub: small fixes to argument processing and usage() 2017-01-24 15:34:05 +01:00
hwstub_test.cpp hwstub: rewrite and expand library 2016-04-08 19:37:30 +02:00
init.lua hwstub: port hwstub_shell to the new library 2016-04-08 19:38:18 +02:00
Makefile hwstub: add tool to dump memory regions (such as ROM, RAM, or peripherals) 2017-01-24 15:34:19 +01:00
prompt.c hwstub: Add completion and some pretty printing to the shell 2015-06-28 17:55:17 +02:00
prompt.h hwstub: Add completion and some pretty printing to the shell 2015-06-28 17:55:17 +02:00