Lines Matching refs:rx_buff
184 struct buffer_state *rx_buff = &priv->rx_buff[*last_rx_bd]; in arc_emac_rx() local
242 dma_unmap_single(dev, dma_unmap_addr(rx_buff, addr), in arc_emac_rx()
243 dma_unmap_len(rx_buff, len), DMA_FROM_DEVICE); in arc_emac_rx()
248 skb_put(rx_buff->skb, pktlen); in arc_emac_rx()
249 rx_buff->skb->dev = ndev; in arc_emac_rx()
250 rx_buff->skb->protocol = eth_type_trans(rx_buff->skb, ndev); in arc_emac_rx()
252 netif_receive_skb(rx_buff->skb); in arc_emac_rx()
254 rx_buff->skb = skb; in arc_emac_rx()
255 dma_unmap_addr_set(rx_buff, addr, addr); in arc_emac_rx()
256 dma_unmap_len_set(rx_buff, len, EMAC_BUFFER_SIZE); in arc_emac_rx()
444 struct buffer_state *rx_buff = &priv->rx_buff[*last_rx_bd]; in arc_emac_open() local
446 rx_buff->skb = netdev_alloc_skb_ip_align(ndev, in arc_emac_open()
448 if (unlikely(!rx_buff->skb)) in arc_emac_open()
451 addr = dma_map_single(dev, (void *)rx_buff->skb->data, in arc_emac_open()
455 dev_kfree_skb(rx_buff->skb); in arc_emac_open()
458 dma_unmap_addr_set(rx_buff, addr, addr); in arc_emac_open()
459 dma_unmap_len_set(rx_buff, len, EMAC_BUFFER_SIZE); in arc_emac_open()
591 struct buffer_state *rx_buff = &priv->rx_buff[i]; in arc_free_rx_queue() local
593 if (rx_buff->skb) { in arc_free_rx_queue()
595 dma_unmap_addr(rx_buff, addr), in arc_free_rx_queue()
596 dma_unmap_len(rx_buff, len), in arc_free_rx_queue()
600 dev_kfree_skb_irq(rx_buff->skb); in arc_free_rx_queue()
605 rx_buff->skb = NULL; in arc_free_rx_queue()