ia64/linux-2.6.18-xen.hg

changeset 518:7c844e8c3485

netfront: Bug fixes to support arp link monitoring for bonding module

Signed-off-by: Masroor Vettuparambil <masroor.vettuparambil@neterion.com>
author Keir Fraser <keir.fraser@citrix.com>
date Thu Apr 10 12:05:57 2008 +0100 (2008-04-10)
parents cf150ce22d43
children d71965a78c20
files drivers/xen/netfront/netfront.c
line diff
     1.1 --- a/drivers/xen/netfront/netfront.c	Tue Apr 08 11:30:38 2008 +0100
     1.2 +++ b/drivers/xen/netfront/netfront.c	Thu Apr 10 12:05:57 2008 +0100
     1.3 @@ -1031,6 +1031,7 @@ static int network_start_xmit(struct sk_
     1.4  
     1.5  	np->stats.tx_bytes += skb->len;
     1.6  	np->stats.tx_packets++;
     1.7 +	dev->trans_start = jiffies;
     1.8  
     1.9  	/* Note: It is not safe to access skb after network_tx_buf_gc()! */
    1.10  	network_tx_buf_gc(dev);
    1.11 @@ -1063,6 +1064,7 @@ static irqreturn_t netif_int(int irq, vo
    1.12  			netfront_accelerator_call_stop_napi_irq(np, dev);
    1.13  
    1.14  			netif_rx_schedule(dev);
    1.15 +			dev->last_rx = jiffies;
    1.16  		}
    1.17  	}
    1.18  
    1.19 @@ -1697,9 +1699,12 @@ static int xennet_set_mac_address(struct
    1.20  	struct netfront_info *np = netdev_priv(dev);
    1.21  	struct sockaddr *addr = p;
    1.22  
    1.23 +	if (netif_running(dev))
    1.24 +		return -EBUSY;
    1.25 +
    1.26  	if (!is_valid_ether_addr(addr->sa_data))
    1.27  		return -EADDRNOTAVAIL;
    1.28 -	
    1.29 +
    1.30  	memcpy(dev->dev_addr, addr->sa_data, dev->addr_len);
    1.31  	memcpy(np->mac, addr->sa_data, ETH_ALEN);
    1.32