1. A switching device comprising: a routing module comprising a first group of packet processors, wherein each packet processor in the first group is configured to process an incoming packet to generate a respective processed packet, wherein each processed packet includes a respective action, a respective action code and a respective priority associated with the respective action from a first priority range; a bridging module comprising a second group of packet processors, wherein each packet processor in the second group is configured to process the incoming packet to generate a respective processed packet, wherein each processed packet includes a respective action, a respective action code and a respective priority associated with the respective action from a second priority range; and a priority arbiter communicatively coupled to the routing module and to the bridging module, the priority arbiter configured to: receive the processed packets from the routing module and the bridging module; process the action codes associated with the processed packets; reassign the priority associated with the respective action for a given processed packet based on a certain action code in the given processed packet, the certain action code indicating reassignment of the priority associated with the respective action for the given processed packet; and select an action associated with a highest priority from the actions for the processed packets to perform on the incoming packet.