so return 1 and requeue this packet.6*/78spin_unlock_irq(&lp->lock);9if(net_debug) printk("cs89x0: Tx buffer not free!\n");10//当检测到网卡暂时无法发送数据时,会直接return 1,而没有调dev_kfree_skb (skb)。11
1/**2* __netdev_alloc_skb - allocate an skbuff for rx on a specific device3* @dev: network device to receive on4* @len: length to allocate5* @gfp_mask: get_free_pages mask, passed to alloc_skb6*7* Allocate a new &sk_buff and assign it a usage count of one. The8* buffer...
There is no need to call dev_kfree_skb() when usb_submit_urb() fails because can_put_echo_skb() deletes original skb and can_free_echo_skb() deletes the cloned skb. Bug: 228694483 Fixes: 0024d8a ("can: usb_8dev: Add support for USB2CAN interface from 8 devices") Link: https...
The skb is finally freed by one of the in-irq-context safe functions: dev_consume_skb_any() or dev_kfree_skb_any(). The "any" version is used because some drivers might call can_get_echo_skb() in a normal context. The reason for this issue to occur is that initially, in the ...
kfree_skb –减少skb引用,为0则释放,用于出错丢包时释放skb使用; 1/**2* kfree_skb - free an sk_buff3* @skb: buffer to free4*5* Drop a reference to the buffer and free it if the usage count has6* hit zero.7*/8/*9释放skb10*/11voidkfree_skb(structsk_buff *skb)12{13if(unlike...
+ dev_kfree_skb_any(skb); return NETDEV_TX_OK; } @@ -6715,7 +6715,7 @@ dma_error: PCI_DMA_TODEVICE); } - dev_kfree_skb(skb); + dev_kfree_skb_any(skb); return NETDEV_TX_OK; } -- 2.3.5 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in...
- dev_kfree_skb(new_skb); + dev_kfree_skb_any(new_skb); ret = -1; } else { u32 save_entry = *entry; @@ -7798,13 +7798,13 @@ static int tigon3_dma_hwbug_workaround(struct tg3_napi *tnapi, new_skb->len, base_flags, ...
+ dev_kfree_skb(dev->rx_skb_pool[i]); } static void rx_fixup(unsigned long data) @@ -946,8 +945,7 @@ static void rtl8150_disconnect(struct usb_interface *intf) unlink_all_urbs(dev); free_all_urbs(dev); free_skb_pool(dev); - if (dev->rx_skb) - dev_kfree_skb(dev->rx...
+ dev_kfree_skb_any(skb); return NETDEV_TX_OK; } @@ -3746,7 +3746,7 @@ static int bond_xmit_broadcast(struct sk_buff *skb, struct net_device *bond_dev) if (slave && IS_UP(slave->dev) && slave->link == BOND_LINK_UP) ...
+ dev_kfree_skb_any(skb); cp->dev->stats.tx_dropped++; goto out_unlock; } -- 2.3.5 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info athttp://vger.kernel.org/majordomo-info.htm...