Hardware Reference
In-Depth Information
7.6
The sets of critical sections that can cause blocking under the Priority Ceiling
Protocol are the same as those derived in the previous exercise for the Priority
Inheritance Protocol. The only difference is that under the Priority Ceiling
Protocol each task can only be blocked for the duration of a single critical
section. Hence, we have the following:
The set of critical sections that can potentially block τ 1
is
{
Z 2 C , Z 3 B ,
Z 3 E , Z 4 A ,
Z 4 C ,
Z 4 E }
Hence, the maximum blocking time for τ 1
.
is
B 1 = δ 3 E
1=13
The set of critical sections that can potentially block τ 2
{
Z 3 B , Z 3 E ,
is
Z 4 A , Z 4 C , Z 4 E }
.
Hence, the maximum blocking time for τ 2
is B 2
=
δ 3 E
1=13.
The set of critical sections that can potentially block τ 3
is
{
Z 4 A , Z 4 C ,
Z 4 E }
1=10.
Task τ 4 cannot be blocked, because it is the task with the lowest priority (it
can only be preempted by higher priority tasks). Hence, we have B 4 =0.
. Hence, the maximum blocking time for τ 3 is B 3 = δ 4 E
7.7
The maximum blocking time for τ 2 is given by a push-through blocking on C 4
and E 3 . This means that for this to happen, τ 4 must start first and must enter
its critical section C 4 . Then, τ 3 must preempt τ 4 , entering E 3 . Now, when τ 1
arrives, it experiences a chained blocking when entering C 1 and E 1 , which are
both locked. The situation is illustrated in Figure 13.21.
W C
W E
τ 1
C
E
P 1
P 1
τ 2
C
τ 3
E
E
τ 4
C
C
Figure 13.21
Schedule produced by RM + PIP for the task set of Exercise 7.7.
7.8
If tasks are assigned decreasing preemption levels as π 1
=3, π 2
=2, and
π 3 =1, the resource ceilings have the values shown in Table 13.4.
 
Search WWH ::




Custom Search