kernel: update kernel 3.18 to version 3.18.23
[openwrt/staging/chunkeey.git] / target / linux / generic / patches-3.18 / 072-bgmac-fix-device-initialization-on-Northstar-SoCs-co.patch
1 From 21697336d46b71dd031f29e426dda0b1e7f06cc0 Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <zajec5@gmail.com>
3 Date: Wed, 11 Feb 2015 18:06:34 +0100
4 Subject: [PATCH] bgmac: fix device initialization on Northstar SoCs (condition
5 typo)
6 MIME-Version: 1.0
7 Content-Type: text/plain; charset=UTF-8
8 Content-Transfer-Encoding: 8bit
9
10 On Northstar (Broadcom's ARM architecture) we need to manually enable
11 all cores. Code for that is already in place, but the condition for it
12 was wrong.
13
14 Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
15 Signed-off-by: David S. Miller <davem@davemloft.net>
16 ---
17 drivers/net/ethernet/broadcom/bgmac.c | 5 +++--
18 1 file changed, 3 insertions(+), 2 deletions(-)
19
20 --- a/drivers/net/ethernet/broadcom/bgmac.c
21 +++ b/drivers/net/ethernet/broadcom/bgmac.c
22 @@ -1412,6 +1412,7 @@ static void bgmac_mii_unregister(struct
23 /* http://bcm-v4.sipsolutions.net/mac-gbit/gmac/chipattach */
24 static int bgmac_probe(struct bcma_device *core)
25 {
26 + struct bcma_chipinfo *ci = &core->bus->chipinfo;
27 struct net_device *net_dev;
28 struct bgmac *bgmac;
29 struct ssb_sprom *sprom = &core->bus->sprom;
30 @@ -1474,8 +1475,8 @@ static int bgmac_probe(struct bcma_devic
31 bgmac_chip_reset(bgmac);
32
33 /* For Northstar, we have to take all GMAC core out of reset */
34 - if (core->id.id == BCMA_CHIP_ID_BCM4707 ||
35 - core->id.id == BCMA_CHIP_ID_BCM53018) {
36 + if (ci->id == BCMA_CHIP_ID_BCM4707 ||
37 + ci->id == BCMA_CHIP_ID_BCM53018) {
38 struct bcma_device *ns_core;
39 int ns_gmac;
40