| |||
| Home > RVISS Reference > Coprocessor model interface > STC | |||
This function is called when an STC instruction
is recognized for a coprocessor.
unsigned STC(void *handle, inttype, ARMwordinstr, ARMword *data)
where:
handleis the handle from ARMulif_InstallCoprocessorV5.
typeis the type of the coprocessor access. This can be one of:
ARMul_CP_FIRSTindicates that this is the first time the coprocessor model has been called for this instruction.
ARMul_CP_BUSYindicates that this is a subsequent call, after the first call was busy-waited.
ARMul_CP_INTERRUPTwarns the coprocessor that the ARM processor is about
to service an interrupt, so the coprocessor must discard the current
instruction. Usually, the instruction is retried later. In that
case the is reset
to typeARMul_CP_FIRST.
ARMul_CP_DATAindicates that the coprocessor must return valid data in *.data
instris the current opcode.
datais a pointer to the location of the data being saved to memory.
The function must return one of:
ARMul_CP_INC, to indicate that
there is more data to transfer to the core (only in response to ARMul_CP_FIRST, ARMul_CP_BUSY,
or ARMul_CP_DATA).
ARMul_CP_DONE, to indicate that
the coprocessor operation is complete (only in response to ARMul_CP_DATA).
ARMul_CP_BUSY, to indicate that
the coprocessor is busy (only in response to ARMul_CP_FIRST or ARMul_CP_BUSY).
ARMul_CP_CANT, to indicate that
the instruction is not supported, or the specified register cannot
be accessed (only in response to ARMul_CP_FIRST or ARMul_CP_BUSY).
ARMUL_CP_LAST, to indicate that
the next save is the last in the sequence. This is only required
for ARM9.