1 --- a/drivers/net/ar231x.c
2 +++ b/drivers/net/ar231x.c
3 @@ -736,6 +736,7 @@ static void ar231x_load_rx_ring(struct n
4 for (i = 0; i < nr_bufs; i++) {
7 + int offset = RX_OFFSET;
11 @@ -751,7 +752,9 @@ static void ar231x_load_rx_ring(struct n
12 * Make sure IP header starts on a fresh cache line.
15 - skb_reserve(skb, RX_OFFSET);
17 + offset += sp->phy_dev->pkt_align;
18 + skb_reserve(skb, offset);
19 sp->rx_skb[idx] = skb;
21 rd = (ar231x_descr_t *) & sp->rx_ring[idx];
22 @@ -826,20 +829,23 @@ static int ar231x_rx_int(struct net_devi
23 /* alloc new buffer. */
24 skb_new = netdev_alloc_skb(dev, AR2313_BUFSIZE + RX_OFFSET);
25 if (skb_new != NULL) {
28 skb = sp->rx_skb[idx];
31 ((status >> DMA_RX_LEN_SHIFT) & 0x3fff) - CRC_LEN);
33 dev->stats.rx_bytes += skb->len;
34 - skb->protocol = eth_type_trans(skb, dev);
35 - /* pass the packet to upper layers */
38 + /* pass the packet to upper layers */
43 - skb_reserve(skb_new, RX_OFFSET);
46 + offset += sp->phy_dev->pkt_align;
47 + skb_reserve(skb_new, offset);
48 /* reset descriptor's curr_addr */
49 rxdesc->addr = virt_to_phys(skb_new->data);
51 @@ -1241,6 +1247,8 @@ static int ar231x_mdiobus_probe (struct
52 return PTR_ERR(phydev);
55 + sp->rx = phydev->netif_rx;
57 /* mask with MAC supported features */
58 phydev->supported &= (SUPPORTED_10baseT_Half
59 | SUPPORTED_10baseT_Full
60 --- a/drivers/net/ar231x.h
61 +++ b/drivers/net/ar231x.h
62 @@ -221,6 +221,8 @@ typedef struct {
64 struct ar231x_private {
65 struct net_device *dev;
66 + int (*rx)(struct sk_buff *skb);