- // The device was retrying a packet. It didn't work, so we'll leave
- // it at the head of the retry list.
- retryingPort = 0;
-
- // We shouldn't be receiving a packet from one port when a different
- // one is retrying.
- assert(port == retryingPort);
+ if (port->onRetryList()) {
+ // The device was retrying a packet. It didn't work, so we'll leave
+ // it at the head of the retry list.
+ assert(port == retryList.front());
+ inRetry = false;
+ }
+ else {
+ port->onRetryList(true);
+ retryList.push_back(port);
+ }