There seems to be a deadlock issue with the mutex and/or cond_var setup in netif_stop_queue(). The issue could be in combination to how the Linux drivers callback the synchronisation functions also. The issue presents itself when very high transmission rate is applied under non-realistic test conditions. It is suspected the synchronisation functions of the transmission function netif_tx() is problematic. The symptom is the loss of receive ability when this deadlock happens. Fix includes:
Refactor of netif_tx() and synchronisation interface functions netif_start_queue(), netif_queue_stopped(), netif_wake_queue() and netif_stop_queue().
Implementation of queue fault recovery by replacing pthread_cond_wait() with pthread_cond_timedwait() with timeout handling.
There seems to be a deadlock issue with the mutex and/or cond_var setup in netif_stop_queue(). The issue could be in combination to how the Linux drivers callback the synchronisation functions also. The issue presents itself when very high transmission rate is applied under non-realistic test conditions. It is suspected the synchronisation functions of the transmission function netif_tx() is problematic. The symptom is the loss of receive ability when this deadlock happens. Fix includes: