X-Git-Url: https://git.rohieb.name/openwrt.git/blobdiff_plain/c9e9be9d3afa44d8775583c36fcab3c0bc552fe7..3330f0fa390bb1da4c9049efd8f9f388c49ee6e6:/target/linux/brcm47xx/patches-2.6.23/120-b44_ssb_support.patch diff --git a/target/linux/brcm47xx/patches-2.6.23/120-b44_ssb_support.patch b/target/linux/brcm47xx/patches-2.6.23/120-b44_ssb_support.patch index 06865cff3..4f33615a5 100644 --- a/target/linux/brcm47xx/patches-2.6.23/120-b44_ssb_support.patch +++ b/target/linux/brcm47xx/patches-2.6.23/120-b44_ssb_support.patch @@ -1,7 +1,5 @@ -Index: linux-2.6.23/drivers/net/b44.c -=================================================================== ---- linux-2.6.23.orig/drivers/net/b44.c 2007-10-13 10:58:27.872607266 +0200 -+++ linux-2.6.23/drivers/net/b44.c 2007-10-13 11:00:46.916530927 +0200 +--- a/drivers/net/b44.c ++++ b/drivers/net/b44.c @@ -1,7 +1,9 @@ -/* b44.c: Broadcom 4400 device driver. +/* b44.c: Broadcom 4400/47xx device driver. @@ -663,7 +661,7 @@ Index: linux-2.6.23/drivers/net/b44.c bw32(bp, B44_RCV_LAZY, 0); bw32(bp, B44_ENET_CTRL, ENET_CTRL_DISABLE); b44_wait_bit(bp, B44_ENET_CTRL, ENET_CTRL_DISABLE, 200, 1); -@@ -1294,19 +1242,23 @@ +@@ -1294,19 +1242,24 @@ } bw32(bp, B44_DMARX_CTRL, 0); bp->rx_prod = bp->rx_cons = 0; @@ -687,6 +685,7 @@ Index: linux-2.6.23/drivers/net/b44.c + & MDIO_CTRL_MAXF_MASK))); + break; + case SSB_BUSTYPE_PCI: ++ case SSB_BUSTYPE_PCMCIA: + bw32(bp, B44_MDIO_CTRL, (MDIO_CTRL_PREAMBLE | (0x0d & MDIO_CTRL_MAXF_MASK))); + break; @@ -695,7 +694,7 @@ Index: linux-2.6.23/drivers/net/b44.c br32(bp, B44_MDIO_CTRL); if (!(br32(bp, B44_DEVCTRL) & DEVCTRL_IPP)) { -@@ -1349,6 +1301,7 @@ +@@ -1349,6 +1302,7 @@ { struct b44 *bp = netdev_priv(dev); struct sockaddr *addr = p; @@ -703,7 +702,7 @@ Index: linux-2.6.23/drivers/net/b44.c if (netif_running(dev)) return -EBUSY; -@@ -1359,7 +1312,11 @@ +@@ -1359,7 +1313,11 @@ memcpy(dev->dev_addr, addr->sa_data, dev->addr_len); spin_lock_irq(&bp->lock); @@ -716,7 +715,7 @@ Index: linux-2.6.23/drivers/net/b44.c spin_unlock_irq(&bp->lock); return 0; -@@ -1445,18 +1402,6 @@ +@@ -1445,18 +1403,6 @@ return err; } @@ -735,7 +734,7 @@ Index: linux-2.6.23/drivers/net/b44.c #ifdef CONFIG_NET_POLL_CONTROLLER /* * Polling receive - used by netconsole and other diagnostic tools -@@ -1570,7 +1515,6 @@ +@@ -1570,7 +1516,6 @@ static void b44_setup_wol(struct b44 *bp) { u32 val; @@ -743,7 +742,7 @@ Index: linux-2.6.23/drivers/net/b44.c bw32(bp, B44_RXCONFIG, RXCONFIG_ALLMULTI); -@@ -1594,13 +1538,6 @@ +@@ -1594,13 +1539,6 @@ } else { b44_setup_pseudo_magicp(bp); } @@ -757,7 +756,7 @@ Index: linux-2.6.23/drivers/net/b44.c } static int b44_close(struct net_device *dev) -@@ -1700,7 +1637,7 @@ +@@ -1700,7 +1638,7 @@ val = br32(bp, B44_RXCONFIG); val &= ~(RXCONFIG_PROMISC | RXCONFIG_ALLMULTI); @@ -766,7 +765,7 @@ Index: linux-2.6.23/drivers/net/b44.c val |= RXCONFIG_PROMISC; bw32(bp, B44_RXCONFIG, val); } else { -@@ -1747,12 +1684,8 @@ +@@ -1747,12 +1685,8 @@ static void b44_get_drvinfo (struct net_device *dev, struct ethtool_drvinfo *info) { @@ -779,7 +778,7 @@ Index: linux-2.6.23/drivers/net/b44.c } static int b44_nway_reset(struct net_device *dev) -@@ -2035,6 +1968,245 @@ +@@ -2035,6 +1969,245 @@ .get_ethtool_stats = b44_get_ethtool_stats, }; @@ -1025,7 +1024,7 @@ Index: linux-2.6.23/drivers/net/b44.c static int b44_ioctl(struct net_device *dev, struct ifreq *ifr, int cmd) { struct mii_ioctl_data *data = if_mii(ifr); -@@ -2044,40 +2216,64 @@ +@@ -2044,40 +2217,64 @@ if (!netif_running(dev)) goto out; @@ -1102,12 +1101,12 @@ Index: linux-2.6.23/drivers/net/b44.c - bp->dev->dev_addr[5] = eeprom[82]; + switch (instance) { + case 1: -+ addr = sdev->bus->sprom.r1.et0mac; -+ bp->phy_addr = sdev->bus->sprom.r1.et0phyaddr; ++ addr = sdev->bus->sprom.et0mac; ++ bp->phy_addr = sdev->bus->sprom.et0phyaddr; + break; + default: -+ addr = sdev->bus->sprom.r1.et1mac; -+ bp->phy_addr = sdev->bus->sprom.r1.et1phyaddr; ++ addr = sdev->bus->sprom.et1mac; ++ bp->phy_addr = sdev->bus->sprom.et1phyaddr; + break; + } + @@ -1115,7 +1114,7 @@ Index: linux-2.6.23/drivers/net/b44.c if (!is_valid_ether_addr(&bp->dev->dev_addr[0])){ printk(KERN_ERR PFX "Invalid MAC address found in EEPROM\n"); -@@ -2086,103 +2282,52 @@ +@@ -2086,103 +2283,52 @@ memcpy(bp->dev->perm_addr, bp->dev->dev_addr, bp->dev->addr_len); @@ -1228,7 +1227,7 @@ Index: linux-2.6.23/drivers/net/b44.c bp->rx_pending = B44_DEF_RX_RING_PENDING; bp->tx_pending = B44_DEF_TX_RING_PENDING; -@@ -2201,16 +2346,16 @@ +@@ -2201,16 +2347,16 @@ dev->poll_controller = b44_poll_controller; #endif dev->change_mtu = b44_change_mtu; @@ -1248,7 +1247,7 @@ Index: linux-2.6.23/drivers/net/b44.c } bp->mii_if.dev = dev; -@@ -2229,61 +2374,52 @@ +@@ -2229,61 +2375,52 @@ err = register_netdev(dev); if (err) { @@ -1326,7 +1325,7 @@ Index: linux-2.6.23/drivers/net/b44.c del_timer_sync(&bp->timer); -@@ -2301,33 +2437,22 @@ +@@ -2301,33 +2438,22 @@ b44_init_hw(bp, B44_PARTIAL_RESET); b44_setup_wol(bp); } @@ -1363,7 +1362,7 @@ Index: linux-2.6.23/drivers/net/b44.c return rc; } -@@ -2346,29 +2471,31 @@ +@@ -2346,29 +2472,31 @@ return 0; } @@ -1401,10 +1400,8 @@ Index: linux-2.6.23/drivers/net/b44.c } module_init(b44_init); -Index: linux-2.6.23/drivers/net/b44.h -=================================================================== ---- linux-2.6.23.orig/drivers/net/b44.h 2007-10-13 10:58:27.880607722 +0200 -+++ linux-2.6.23/drivers/net/b44.h 2007-10-13 11:00:46.904530245 +0200 +--- a/drivers/net/b44.h ++++ b/drivers/net/b44.h @@ -129,6 +129,7 @@ #define RXCONFIG_FLOW 0x00000020 /* Flow Control Enable */ #define RXCONFIG_FLOW_ACCEPT 0x00000040 /* Accept Unicast Flow Control Frame */ @@ -1528,10 +1525,8 @@ Index: linux-2.6.23/drivers/net/b44.h struct net_device *dev; dma_addr_t rx_ring_dma, tx_ring_dma; -Index: linux-2.6.23/drivers/net/Kconfig -=================================================================== ---- linux-2.6.23.orig/drivers/net/Kconfig 2007-10-13 10:58:27.888608180 +0200 -+++ linux-2.6.23/drivers/net/Kconfig 2007-10-13 11:00:46.912530699 +0200 +--- a/drivers/net/Kconfig ++++ b/drivers/net/Kconfig @@ -1577,7 +1577,7 @@ config B44