skb->protocol = eth_type_trans(skb, skge->netdev);  return skb; error:  if (netif_msg_rx_err(skge)) printk(KERN_DEBUG PFX "%s: rx err, slot %td control 0x%x status 0x%x\n", skge->netdev->name, e - skge->rx_ring.start, control, status);  if (skge->hw->chip_id == CHIP_ID_GENESIS) { if (status & (XMR_FS_RUNT|XMR_FS_LNG_ERR)) skge->net_stats.rx_length_errors++; if (status & XMR_FS_FRA_ERR) skge->net_stats.rx_frame_errors++; if (status & XMR_FS_FCS_ERR) skge->net_stats.rx_crc_errors++; } else { if (status & (GMR_FS_LONG_ERR|GMR_FS_UN_SIZE)) skge->net_stats.rx_length_errors++; if (status & GMR_FS_FRAGMENT) skge->net_stats.rx_frame_errors++; if (status & GMR_FS_CRC_ERR) skge->net_stats.rx_crc_errors++; }  resubmit: skge_rx_reuse(e, skge->rx_buf_size); return NULL;
static inline struct sk_buff *skge_rx_get(struct skge_port *skge,					  struct skge_element *e,					  unsigned int len){	struct sk_buff *nskb, *skb;	if (len < RX_COPY_THRESHOLD) {		nskb = skge_rx_alloc(skge->netdev, len + NET_IP_ALIGN);		if (unlikely(!nskb))			return NULL;		pci_dma_sync_single_for_cpu(skge->hw->pdev,					    pci_unmap_addr(e, mapaddr),					    len, PCI_DMA_FROMDEVICE);		memcpy(nskb->data, e->skb->data, len);		pci_dma_sync_single_for_device(skge->hw->pdev,					       pci_unmap_addr(e, mapaddr),					       len, PCI_DMA_FROMDEVICE);		if (skge->rx_csum) {			struct skge_rx_desc *rd = e->desc;			nskb->csum = le16_to_cpu(rd->csum2);			nskb->ip_summed = CHECKSUM_HW;		}		skge_rx_reuse(e, skge->rx_buf_size);		return nskb;	} else {		nskb = skge_rx_alloc(skge->netdev, skge->rx_buf_size);		if (unlikely(!nskb))			return NULL;		pci_unmap_single(skge->hw->pdev,				 pci_unmap_addr(e, mapaddr),				 pci_unmap_len(e, maplen),				 PCI_DMA_FROMDEVICE);		skb = e->skb;		if (skge->rx_csum) {			struct skge_rx_desc *rd = e->desc;			skb->csum = le16_to_cpu(rd->csum2);			skb->ip_summed = CHECKSUM_HW;		}		skge_rx_setup(skge, e, nskb, skge->rx_buf_size);		return skb;	}}