diff options
author | iap10@labyrinth.cl.cam.ac.uk <iap10@labyrinth.cl.cam.ac.uk> | 2003-02-26 19:42:31 +0000 |
---|---|---|
committer | iap10@labyrinth.cl.cam.ac.uk <iap10@labyrinth.cl.cam.ac.uk> | 2003-02-26 19:42:31 +0000 |
commit | 937d9e4f01cf8fcd79cacc45c5ed73ab2fb9b05e (patch) | |
tree | 4035ba33193c4043d6b29d7f98a3e98434fb7214 /xenolinux-2.4.21-pre4-sparse | |
parent | 52c54dcbd1108d1b7e1b36b14a00be9766d06dfe (diff) | |
download | xen-937d9e4f01cf8fcd79cacc45c5ed73ab2fb9b05e.tar.gz xen-937d9e4f01cf8fcd79cacc45c5ed73ab2fb9b05e.tar.bz2 xen-937d9e4f01cf8fcd79cacc45c5ed73ab2fb9b05e.zip |
bitkeeper revision 1.103.1.1 (3e5d18a7GqCcFtgB4EjULbmAXiDJzw)
xenolinux network driver tx_event now set to tx_prod rather than tx_prod+1
seems to fix a network hang problem...
Diffstat (limited to 'xenolinux-2.4.21-pre4-sparse')
-rw-r--r-- | xenolinux-2.4.21-pre4-sparse/arch/xeno/drivers/network/network.c | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/xenolinux-2.4.21-pre4-sparse/arch/xeno/drivers/network/network.c b/xenolinux-2.4.21-pre4-sparse/arch/xeno/drivers/network/network.c index 8e742007cf..ca33b849a0 100644 --- a/xenolinux-2.4.21-pre4-sparse/arch/xeno/drivers/network/network.c +++ b/xenolinux-2.4.21-pre4-sparse/arch/xeno/drivers/network/network.c @@ -66,6 +66,17 @@ struct net_private }; +static void dbg_network_int(int irq, void *dev_id, struct pt_regs *ptregs) +{ + struct net_device *dev = (struct net_device *)dev_id; + struct net_private *np = dev->priv; + printk(KERN_ALERT "tx_full = %d, tx_entries = %d, tx_idx = %d, tx_cons = %d, tx_prod = %d, tx_event = %d, state=%d\n", + np->tx_full, np->tx_entries, np->tx_idx, + np->net_ring->tx_cons,np->net_ring->tx_prod,np->net_ring->tx_event, + test_bit(__LINK_STATE_XOFF, &dev->state)); +} + + static int network_open(struct net_device *dev) { struct net_private *np = dev->priv; @@ -123,6 +134,11 @@ static int network_open(struct net_device *dev) goto fail; } +#if 1 + request_irq( _EVENT_DEBUG, dbg_network_int, SA_SHARED, "debug", dev); +#endif + + printk("XenoLinux Virtual Network Driver installed as %s\n", dev->name); netif_start_queue(dev); @@ -268,7 +284,7 @@ static int network_start_xmit(struct sk_buff *skb, struct net_device *dev) else { /* Avoid unnecessary tx interrupts. */ - np->net_ring->tx_event = TX_RING_INC(np->net_ring->tx_prod); + np->net_ring->tx_event = np->net_ring->tx_prod; } spin_unlock_irq(&np->tx_lock); |