Re: [PATCH 2/3] MIPS: lantiq: add ethernet driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: John Crispin <blogic@xxxxxxxxxxx>
Date: Tue, 12 Apr 2011 18:11:14 +0200

> This patch adds the driver for the ETOP Packet Processing Engine (PPE32) found
> inside the XWAY family of Lantiq MIPS SoCs. This driver makes 100MBit ethernet
> work. Support for all 8 dma channels, gbit and the embedded switch found on
> the ar9/vr9 still needs to be implemented.
> 
> Signed-off-by: John Crispin <blogic@xxxxxxxxxxx>
> Signed-off-by: Ralph Hempel <ralph.hempel@xxxxxxxxxx>

This driver needs some work.

> +
> +	skb_put(skb, len);
> +	skb->dev = dev;
> +	skb->protocol = eth_type_trans(skb, dev);
> +	netif_rx(skb);
> +	priv->stats.rx_packets++;
> +	priv->stats.rx_bytes += len;

Please convert this driver to use NAPI for packet reception.

> +	local_irq_save(flags);
> +	priv->rx_tasklet_running = 0;
> +	if (priv->rx_channel_mask) {
> +		priv->rx_tasklet_running = 1;
> +		tasklet_schedule(&priv->rx_tasklet);
> +	}
> +	local_irq_restore(flags);

This doesn't protect anything, use proper locking.



[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux