Hardware Reference
In-Depth Information
δ i,k
denotes the duration of Z i,k .
z i,h
z i,k
indicates that z i,h
is entirely contained in z i,k .
σ i
denotes the set of semaphores used by τ i .
σ i,j denotes the set of semaphores that can block τ i , used by the lower-priority
task τ j .
γ i,j denotes the set of the longest critical sections that can block τ i , accessed by
the lower priority task τ j . That is,
γ i,j =
{
Z j,k
|
( P j <P i ) and ( S k
σ i,j )
}
(7.1)
γ i
denotes the set of all the longest critical sections that can block τ i . That is,
γ i =
j : P j <P i
γ i,j
(7.2)
Moreover, the properties of the protocols are valid under the following assumptions:
Tasks τ 1 2 ,...,τ n are assumed to have different priorities and are listed in de-
scending order of nominal priority, with τ 1 having the highest nominal priority.
Tasks do not suspend themselves on I/O operations or on explicit synchronization
primitives (except on locked semaphores).
The critical sections used by any task are properly nested; that is, given any pair
z i,h
and z i,k , then either z i,h
z i,k , z i,k
z i,h ,or z i,h
z i,k =
.
Critical sections are guarded by binary semaphores, meaning that only one task
at a time can be within a critical section.
7.4
NON-PREEMPTIVE PROTOCOL
A simple solution that avoids the unbounded priority inversion problem is to disallow
preemption during the execution of any critical section. This method, also referred to
as Non-Preemptive Protocol (NPP), can be implemented by raising the priority of a
task to the highest priority level whenever it enters a shared resource. In particular, as
soon as a task τ i enters a resource R k , its dynamic priority is raised to the level:
p i ( R k )=ma h {
P h }
.
(7.3)
Search WWH ::




Custom Search