IEEE 802.1W or Rapid Spanning Tree Protocol (RSTP) takes the improvements and concepts from propriety protocols such as PVST and PVST+, which were spanning tree instances that ran on a per-VLAN basis rather than across the entire topology.
A per-VLAN spanning tree instance can introduce advantages such as allowing simple load balancing and traffic steering.
RSTP is backwards compatible with regular STP. On an RSTP link establishment a handshake is attempted. If this RSTP based handshake is not successful the port reverts to regular STP behaviour and all the link delays that come with it (2 sets of 15 seconds of listening and learning periods)
Another instance where a RSTP reverts to STP behaviour is if it connects to a half-duplex link such as a network hub.
RSTP reduces the number of port states from four to three.
Discarding – The switch port is in an online state but does not forward any traffic to ensure that a loop is not created.
Learning – The switch port learns any MAC addresses of any network traffic it receives but continues not to forward any network traffic except BPDUs
Forwarding – The switch forwards all network traffic and updates the MAC address table.
Edge Port – This is a port at the edge of a network that connects directly to a host device making it impossible to loop. These ports have the port-fast feature enabled.
Root Port – This port has the best path by cost to the root bridge of the topology in that VLAN. Similar to STP there can only be one root port.
Point to Point Port – This port connects to any other port that also runs RSTP running full-duplex. In a full duplex link only two devices can be connected directly together.