1 Index: linux-2.6.32.7/drivers/net/ar231x.c
2 ===================================================================
3 --- linux-2.6.32.7.orig/drivers/net/ar231x.c 2010-02-03 17:02:28.998430523 +0100
4 +++ linux-2.6.32.7/drivers/net/ar231x.c 2010-02-03 17:03:01.346429245 +0100
6 static int ar231x_mdiobus_reset(struct mii_bus *bus);
7 static int ar231x_mdiobus_probe (struct net_device *dev);
8 static void ar231x_adjust_link(struct net_device *dev);
9 +static bool no_phy = false;
12 #define ERR(fmt, args...) printk("%s: " fmt, __func__, ##args)
15 mdiobus_register(sp->mii_bus);
17 + /* Workaround for Micrel switch, which is only available on
18 + * one PHY and cannot be configured through MDIO */
21 + get_phy_id(sp->mii_bus, 1, &phy_id);
22 + if (phy_id == 0x00221450)
27 + netif_carrier_on(dev);
32 if (ar231x_mdiobus_probe(dev) != 0) {
33 printk(KERN_ERR "%s: mdiobus_probe failed\n", dev->name);
34 rx_tasklet_cleanup(dev);
36 rx_tasklet_cleanup(dev);
37 ar231x_init_cleanup(dev);
38 unregister_netdev(dev);
39 - mdiobus_unregister(sp->mii_bus);
40 - mdiobus_free(sp->mii_bus);
42 + mdiobus_unregister(sp->mii_bus);
43 + mdiobus_free(sp->mii_bus);
49 dev->stats.rx_bytes += skb->len;
51 /* pass the packet to upper layers */
56 + skb->protocol = eth_type_trans(skb, skb->dev);
63 struct ar231x_private *sp = netdev_priv(dev);