ramips: remove old code for Edimax BR-6524N
[openwrt.git] / target / linux / mpc85xx / patches-3.18 / 101-net-gianfar-use-mtd-mac-address.patch
1 --- a/drivers/net/ethernet/freescale/gianfar.c
2 +++ b/drivers/net/ethernet/freescale/gianfar.c
3 @@ -858,10 +858,13 @@ static int gfar_of_init(struct platform_
4         if (stash_len || stash_idx)
5                 priv->device_flags |= FSL_GIANFAR_DEV_HAS_BUF_STASHING;
6  
7 -       mac_addr = of_get_mac_address(np);
8 +       err = of_get_mac_address_mtd(np, dev->dev_addr);
9 +       if (err) {
10 +               mac_addr = of_get_mac_address(np);
11  
12 -       if (mac_addr)
13 -               memcpy(dev->dev_addr, mac_addr, ETH_ALEN);
14 +               if (mac_addr)
15 +                       memcpy(dev->dev_addr, mac_addr, ETH_ALEN);
16 +       }
17  
18         if (model && !strcasecmp(model, "TSEC"))
19                 priv->device_flags |= FSL_GIANFAR_DEV_HAS_GIGABIT |