NETIF_QUEUE_STOPPED: 【作用】检查net_device的发送队列是否stopped 【实现】检查设备发送队列_tx[0]的状态state的_QUEUE_STATE_XOFF是否置1,置1的话返回1,置0返回0。 ===用法=== netif_start_queue一般在open函数中调用,开启数据包的传输。 netif_stop_queue一般用于驱动程序通知网络子系统暂停数据包传输,从来...
函数名称:测试如果发送队列阻塞 函数原型:static inline bool netif_queue_stopped(const struct net_device *dev) 返回类型:bool 参数: 类型参数名称 const struct net_device * dev 3189 返回:netif_tx_queue_stopped(netdev_get_tx_queue(dev, 0)) 源...
*/voidmwifiex_stop_net_dev_queue(struct net_device *netdev, struct mwifiex_adapter *adapter){unsignedlongdev_queue_flags; spin_lock_irqsave(&adapter->queue_lock, dev_queue_flags);netif_tx_stop_all_queues(netdev); spin_unlock_irqrestore(&adapter->queue_lock, dev_queue_flags); } 开发者...
u32 curr_frag;#ifVERBOSE > SHOW_ERROR_MESSAGESDEBUG(SHOW_FUNCTION_CALLS,"islpci_eth_transmit \n");#endif/* lock the driver code */spin_lock_irqsave(&priv->slock, flags);/* check whether the destination queue has enough fragments for the frame */curr_frag = le32_to_cpu(cb->driver...
DBG0("%s: opening SMD port\n", __func__);netif_carrier_on(_dev);if(netif_queue_stopped(_dev)) { DBG0("%s: re-starting if queue\n", __func__); netif_wake_queue(_dev); }break;caseSMD_EVENT_CLOSE: DBG0("%s: closing SMD port\n", __func__); ...
atomic_dec(&dev->active_tx_urbs);if(!netif_device_present(netdev))return;if(netif_queue_stopped(netdev)) netif_wake_queue(netdev); } 开发者ID:harlanstars,项目名称:linux,代码行数:22,代码来源:gs_usb.c 示例13: dev_watchdog ▲点赞 1▼ ...
netif_wake_subqueue(dev,queue); }else{if(netif_msg_tx_err(priv) && net_ratelimit()) printk(KERN_WARNING"%s: end_xmit: spurious interrupt\n", dev->name);if(netif_subqueue_stopped(dev,queue)) netif_wake_subqueue(dev,queue);
netif_stop_queue(netdev);if(netif_running(netdev)) {if(dev != netdev) bus_bitmask_start |= (1<< j); priv->tx.pending =0; priv->tx.echo_put =0; priv->tx.echo_get =0;/* * this bus' may just have called open_candev() ...
skb_queue_tail(&dev->rx_frames, skb); } skb =NULL; skb2 = skb_dequeue(&dev->rx_frames);while(skb2) {if(status <0|| ETH_HLEN > skb2->len || skb2->len > ETH_FRAME_LEN) { dev->net->stats.rx_errors++; dev->net->stats.rx_length_errors++; ...
__netif_tx_lock(txq, cpu);#ifdefined (CONFIG_RAETH_BQL)netdev_tx_completed_queue(txq,0, bytes_sent_ge1);#endifif(netif_tx_queue_stopped(txq)) netif_tx_wake_queue(txq); __netif_tx_unlock(txq); }#ifdefined (CONFIG_PSEUDO_SUPPORT)if(netif_running(ei_local->PseudoDev)) { ...