Using The User-Supervisor Protection Model - Intel i960 Jx Developer's Manual

Microprocessor
Table of Contents

Advertisement

PROGRAMMING ENVIRONMENT
3.8.2

Using the User-Supervisor Protection Model

A program switches from user mode to supervisor mode by making a system-supervisor call (also
referred to as a supervisor call). A system-supervisor call is a call executed with the call-system
instruction (
calls
). With
calls
, the IP for the called procedure comes from the system procedure
table. An entry in the system procedure table can specify an execution mode switch to supervisor
mode when the called procedure is executed. The instruction
calls
and the system procedure table
thus provide a tightly controlled interface to procedures that can execute in supervisor mode. Once
the processor switches to supervisor mode, it remains in that mode until a return is performed to
the procedure that caused the original mode switch.
Interrupts and faults can cause the processor to switch from user to supervisor mode. When the
processor handles an interrupt, it automatically switches to supervisor mode. However, it does not
switch to the supervisor stack. Instead, it switches to the interrupt stack. Fault table entries
determine when a particular fault transitions the processor from user to supervisor mode.
When an application does not require a user-supervisor protection mechanism, the processor can
always execute in supervisor mode. At initialization, the processor is placed in supervisor mode
prior to executing the first instruction of the application code. The processor then remains in
supervisor mode indefinitely, as long as no action is taken to change execution mode to user mode.
The processor does not need a user stack in this case.
3-24

Advertisement

Table of Contents
loading

Table of Contents