> What negative consequences can result from removing this check?

One negative consequence is that the answer returned can be
wrong. It might be possible to determine if the MMU *was* on
or off when the query happened, but if the CPU is running, then
it could have changed state by the time the fn returns.

As the code is implemented it would return whether or not the
MMU was on/off last time the CPU was polled, whether or
not it is currently running.

Perhaps the best solution would be to specify that the target->type->mmu()
requires the target to be halted by the contract of that API fn?

-- 
Øyvind Harboe
US toll free 1-866-980-3434 / International +47 51 63 25 00
http://www.zylin.com/zy1000.html
ARM7 ARM9 ARM11 XScale Cortex
JTAG debugger and flash programmer
_______________________________________________
Openocd-development mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/openocd-development

Reply via email to