From: Michael Brown Date: Tue, 3 May 2011 19:04:21 +0000 (+0100) Subject: [netdevice] Improve detection of bugs in drivers' TX completion handling X-Git-Tag: v1.20.1~2134 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0b6808aadcbb9f04df34e1bba9012ed947e67cb0;p=thirdparty%2Fipxe.git [netdevice] Improve detection of bugs in drivers' TX completion handling Signed-off-by: Michael Brown --- diff --git a/src/net/netdevice.c b/src/net/netdevice.c index 2180c65fe..9a8a3aaf6 100644 --- a/src/net/netdevice.c +++ b/src/net/netdevice.c @@ -216,8 +216,7 @@ void netdev_tx_complete_err ( struct net_device *netdev, } /* Catch data corruption as early as possible */ - assert ( iobuf->list.next != NULL ); - assert ( iobuf->list.prev != NULL ); + list_check_contains ( iobuf, &netdev->tx_queue, list ); /* Dequeue and free I/O buffer */ list_del ( &iobuf->list );