This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Current priority level of processor

Hi,

I have been reading about the exception mechanism of Cortex-M (M4 to be precise). The exception request is accepted by the processor if the current priority level of the processor is less than the incoming exception (this is one of the conditions to accept the request). So I am a bit confused about what is meant by 'Current priority level of processor'. I can guess that when the processor is in handler mode, it will be the priority level of that exception. But when the processor is in thread mode, say just running a normal user program after reset, what is the priority level of the processor?

Thanks,

Gopal

Parents
  • Hi I know this thread s old but I would like to ask about it too.

    In ARM documentation is written somehing like this:

    To access the exception mask registers use the MSR and MRS instructions, or the CPS instruction to change the value of PRIMASK or FAULTMASK

    0] PRIMASK

    0 = no effect

    1 = prevents the activation of all exceptions with configurable priority.

    So if I want to use MRS instruction to reset this bit[0] how to do this. Lets say not to use CPS. ARM says written 0 has no effect! Why it is so?

Reply
  • Hi I know this thread s old but I would like to ask about it too.

    In ARM documentation is written somehing like this:

    To access the exception mask registers use the MSR and MRS instructions, or the CPS instruction to change the value of PRIMASK or FAULTMASK

    0] PRIMASK

    0 = no effect

    1 = prevents the activation of all exceptions with configurable priority.

    So if I want to use MRS instruction to reset this bit[0] how to do this. Lets say not to use CPS. ARM says written 0 has no effect! Why it is so?

Children