Make your own free website on Tripod.com

CS 635, Lecture 4 Part 3

Token Ring (priority)

The token ring (priority) uses a token to provide priority access to the network. This approach is used widely in vendor products today is is endorsed in the IEEE 802.5 standard. It has many similarities to a conventional token-passing ring Each station is required to examine the token.  Picture of the Token Ring

A General View of  A Token Ring

Assume a token ring has five stations attached to a priority ring (picture above). Station A has priority access of 1 (lowest priority), station B and have priority of 2, and station C and E have priorities of 3 (highest priority).  Assume A had already seized the ring and is transmitting data frames. The token has a bit set to indicate that the token is busy. The following sequence of events illustrates one approach to priority token passing:

The IEEE 802.5 Priority Scheme

The 802.5 priority scheme is similar more sophisticated than the general token ring priority scheme. The priority scheme is provided through the use of the following fields and registers:
 
RRR
Reservation bits allow high-priority stations to request the use of the next token
PPP
Priority bits indicate the priority of the token, and therefore which stations are allowed to use the ring
Rr
Storage register for the reservation value
Pr
Storage register for the priority value
Sr
Stack register to store the value of Pr
Sx
Stack register to store the value of the token that was transmitted
Pm
Priority level of a frame queued and ready for transmission


 Picture of the token
 
 

The priority bits (PPP) and the reservation bits (RRR) contained in the token give access to the highest priority frame that is ready for transmission on the ring. These values are stored in registers Pr and Rr. The current ring service priority is indicated by the priority bits (PPP) and the token which is circulated around the ring.

The priority mechanism operates in such a way that equal access to the ring is maintained for all stations within a priority level. This is accomplished by having the same station that raised the service priority level of the ring (the stacking station) return the ring to the original service priority. The Sx and Sr stacks are used to perform this function.

When a station has a priority frame to transmit, it requests a priority token by changing the reservation bits  (RRR) as the station repeats the token. If the priority level (Pm) of the frame that is ready for transmission is greater than the RRR bits, the station increases the value of the RRR field to the value Pm. If the value of the RRR bits is equal to or greater than Pm, the reservation bits (RRR) are repeated unchanged.

After a station has claimed the token, the station transmits frames until it has completed transmission, or until the transmission of another frame could not be completed before a time expires, in which case the station generates a new token for transmission on the ring.

If the station does not have additional frames to transmit or if the station does not have a reservation request (contained in register Rr) which is greater than the present ring service priority (contained in register Pr), the token is transmitted with its priority at the present ring service priority and the reservation bits (RRR) at the greater of Rr or Pm, and no further actions is taken.

However, if the station has a frame ready for transmission or a reservation request (Rr), either of which is greater than the present ring service priority, the token is generated with its priority at the greater of Pm or Rr and its reservation bits (RRR) as 0. Since the station has raised the service priority level of the ring, the station becomes a stacking station and must store the value of the old ring service priority as Sr and the new ring service priority as Sx. These values are used later to lower the service priority of the ring when the re are no frames ready to transmit on the ring whose priority (Pm) is equal to or greater than the stacked Sx.

Upon becoming a stacker, the station claims every token that it receives that has a priority (PPP) equal to its highest stacked transmitted priority (Sx). The RRR bits of the token are examined in order to raise, maintain , or lower the service priority of the ring. The new token is transmitted with its PPP bits equal to the value of the reservation bits (RRR), but no lower than the value of the highest stacked received priority (Sr), which was the original ring priority service level. This approach ensures that the highest priority gets access to the ring.

If the value of the new ring service priority (PPP equal to Rr) is greater than Sr, the RRR bits are transmitted as 0, the old ring service priority contained in Sx is replaced with a new value Sx equal to Rr, and the station continues its role as a stacking station.

However, if the Rr value is equal to or less than the value of the highest stacked received priority (Sr), the new token is transmitted at a priority value of the Sr, both Sx and Sr are removed from the stack, and , if no other values of Sx and Sr are stacked, the station discontinues its role as a stacking station . This technique allows the lower priority stations to use the ring once the high-priority stations are through.
 

 Picture of the token with data

 Top   Prev