static void __netif_up(netif_t *netif) { struct net_device *dev = netif->dev; spin_lock_bh(&dev->xmit_lock); netif->active = 1; spin_unlock_bh(&dev->xmit_lock); enable_irq(netif->irq); netif_schedule_work(netif); }
static void net_tx_error(struct XenNetDev *netdev, netif_tx_request_t *txp, RING_IDX end) { #if 0 /* * Hmm, why netback fails everything in the ring? * Should we do that even when not supporting SG and TSO? */ RING_IDX cons = netdev->tx_ring.req_cons; do { make_tx_response(netif, txp, NETIF_RSP_ERROR); if (cons >= end) break; txp = RING_GET_REQUEST(&netdev->tx_ring, cons++); } while (1); netdev->tx_ring.req_cons = cons; netif_schedule_work(netif); netif_put(netif); #else net_tx_response(netdev, txp, NETIF_RSP_ERROR); #endif }