In a linux network driver, I must provide a function, hard_start_xmit(), that actually sends packets on the wire. I understand that if it can't send the packet, hard_start_xmit() should return an error, which will cause the packet to be retried later. However, since hard_start_xmit() may be called at with IRQs disabled, it cannot wait very long to determine whether the packet could be sent.
How do I deal with a transmission error that happens after hard_start_xmit() has already returned success? Is it correct to simply drop the packet, free the skb, and count a transmit error?