[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] Update suspend/resume functions for xenbus.
# HG changeset patch # User cl349@xxxxxxxxxxxxxxxxxxxx # Node ID 70be155e9e9cb5534c3e6d55aee3a4fbb28bf105 # Parent b88e1417bd14b6625f55645f81ea01ef7727deea Update suspend/resume functions for xenbus. Signed-off-by: Christian Limpach <Christian.Limpach@xxxxxxxxxxxx> diff -r b88e1417bd14 -r 70be155e9e9c linux-2.6-xen-sparse/drivers/xen/netfront/netfront.c --- a/linux-2.6-xen-sparse/drivers/xen/netfront/netfront.c Mon Aug 29 17:14:08 2005 +++ b/linux-2.6-xen-sparse/drivers/xen/netfront/netfront.c Mon Aug 29 17:15:56 2005 @@ -1272,25 +1272,24 @@ static int netfront_suspend(struct xenbus_device *dev) { - struct net_private *np = dev->data; - /* Avoid having tx/rx stuff happen until we're ready. */ - unbind_evtchn_from_irqhandler(np->evtchn, np->netdev); - return 0; + struct netfront_info *info = dev->data; + + unregister_xenbus_watch(&info->watch); + kfree(info->backend); + info->backend = NULL; + + netif_free(info); + + return 0; } static int netfront_resume(struct xenbus_device *dev) { - struct net_private *np = dev->data; - /* - * Connect regardless of whether IFF_UP flag set. - * Stop bad things from happening until we're back up. - */ - np->backend_state = BEST_DISCONNECTED; - memset(np->tx, 0, PAGE_SIZE); - memset(np->rx, 0, PAGE_SIZE); - - // send_interface_connect(np); - return 0; + struct net_private *np = dev->data; + int err; + + err = talk_to_backend(dev, np); + return err; } static struct xenbus_driver netfront = { _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |