From e6b6adc799afe7d6d847c683968b1eee7d82d85a Mon Sep 17 00:00:00 2001 From: mb Date: Tue, 19 Feb 2008 01:24:18 +0000 Subject: ssb: Update to latest upstream version of ssb. git-svn-id: svn://svn.openwrt.org/openwrt/trunk@10490 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- .../brcm47xx/patches-2.6.23/210-ssb_fixes.patch | 117 ++++++++++++++++----- 1 file changed, 88 insertions(+), 29 deletions(-) (limited to 'target/linux/brcm47xx/patches-2.6.23/210-ssb_fixes.patch') diff --git a/target/linux/brcm47xx/patches-2.6.23/210-ssb_fixes.patch b/target/linux/brcm47xx/patches-2.6.23/210-ssb_fixes.patch index 3b87a8c02..ce3a007b6 100644 --- a/target/linux/brcm47xx/patches-2.6.23/210-ssb_fixes.patch +++ b/target/linux/brcm47xx/patches-2.6.23/210-ssb_fixes.patch @@ -1,18 +1,18 @@ -Index: linux-2.6.23/drivers/ssb/driver_mipscore.c +Index: linux-2.6.23.16/drivers/ssb/driver_mipscore.c =================================================================== ---- linux-2.6.23.orig/drivers/ssb/driver_mipscore.c 2007-10-14 04:32:45.793470742 +0200 -+++ linux-2.6.23/drivers/ssb/driver_mipscore.c 2007-10-14 04:33:25.155713862 +0200 -@@ -222,3 +222,5 @@ +--- linux-2.6.23.16.orig/drivers/ssb/driver_mipscore.c 2008-02-19 01:35:53.000000000 +0100 ++++ linux-2.6.23.16/drivers/ssb/driver_mipscore.c 2008-02-19 02:01:16.000000000 +0100 +@@ -222,3 +222,5 @@ void ssb_mipscore_init(struct ssb_mipsco ssb_mips_serial_init(mcore); ssb_mips_flash_detect(mcore); } + +EXPORT_SYMBOL(ssb_mips_irq); -Index: linux-2.6.23/include/linux/ssb/ssb_driver_chipcommon.h +Index: linux-2.6.23.16/include/linux/ssb/ssb_driver_chipcommon.h =================================================================== ---- linux-2.6.23.orig/include/linux/ssb/ssb_driver_chipcommon.h 2007-10-14 04:32:45.817472111 +0200 -+++ linux-2.6.23/include/linux/ssb/ssb_driver_chipcommon.h 2007-10-14 04:33:25.159714091 +0200 -@@ -382,11 +382,45 @@ +--- linux-2.6.23.16.orig/include/linux/ssb/ssb_driver_chipcommon.h 2008-02-19 01:35:53.000000000 +0100 ++++ linux-2.6.23.16/include/linux/ssb/ssb_driver_chipcommon.h 2008-02-19 02:01:10.000000000 +0100 +@@ -382,11 +382,45 @@ extern void ssb_chipco_set_clockmode(str extern void ssb_chipco_watchdog_timer_set(struct ssb_chipcommon *cc, u32 ticks); @@ -61,10 +61,10 @@ Index: linux-2.6.23/include/linux/ssb/ssb_driver_chipcommon.h #ifdef CONFIG_SSB_SERIAL extern int ssb_chipco_serial_init(struct ssb_chipcommon *cc, -Index: linux-2.6.23/include/linux/ssb/ssb_driver_extif.h +Index: linux-2.6.23.16/include/linux/ssb/ssb_driver_extif.h =================================================================== ---- linux-2.6.23.orig/include/linux/ssb/ssb_driver_extif.h 2007-10-14 04:32:45.821472339 +0200 -+++ linux-2.6.23/include/linux/ssb/ssb_driver_extif.h 2007-10-14 04:33:25.167714544 +0200 +--- linux-2.6.23.16.orig/include/linux/ssb/ssb_driver_extif.h 2008-02-19 01:35:53.000000000 +0100 ++++ linux-2.6.23.16/include/linux/ssb/ssb_driver_extif.h 2008-02-19 01:39:40.000000000 +0100 @@ -153,7 +153,6 @@ #define SSB_EXTIF_WATCHDOG_CLK 48000000 /* Hz */ @@ -73,7 +73,7 @@ Index: linux-2.6.23/include/linux/ssb/ssb_driver_extif.h #ifdef CONFIG_SSB_DRIVER_EXTIF struct ssb_extif { -@@ -171,17 +170,42 @@ +@@ -171,17 +170,42 @@ extern void ssb_extif_get_clockcontrol(s extern void ssb_extif_timing_init(struct ssb_extif *extif, unsigned long ns); @@ -122,11 +122,11 @@ Index: linux-2.6.23/include/linux/ssb/ssb_driver_extif.h #else /* CONFIG_SSB_DRIVER_EXTIF */ /* extif disabled */ -Index: linux-2.6.23/include/linux/ssb/ssb.h +Index: linux-2.6.23.16/include/linux/ssb/ssb.h =================================================================== ---- linux-2.6.23.orig/include/linux/ssb/ssb.h 2007-10-14 04:32:45.833473010 +0200 -+++ linux-2.6.23/include/linux/ssb/ssb.h 2007-10-14 04:33:25.171714773 +0200 -@@ -255,6 +255,12 @@ +--- linux-2.6.23.16.orig/include/linux/ssb/ssb.h 2008-02-19 01:35:53.000000000 +0100 ++++ linux-2.6.23.16/include/linux/ssb/ssb.h 2008-02-19 01:39:40.000000000 +0100 +@@ -217,6 +217,12 @@ enum ssb_bustype { #define SSB_CHIPPACK_BCM4712M 2 /* Medium 225pin 4712 */ #define SSB_CHIPPACK_BCM4712L 0 /* Large 340pin 4712 */ @@ -139,7 +139,7 @@ Index: linux-2.6.23/include/linux/ssb/ssb.h #include #include #include -@@ -385,6 +391,16 @@ +@@ -349,6 +355,16 @@ static inline void ssb_write32(struct ss dev->ops->write32(dev, offset, value); } @@ -156,11 +156,11 @@ Index: linux-2.6.23/include/linux/ssb/ssb.h /* Translation (routing) bits that need to be ORed to DMA * addresses before they are given to a device. */ -Index: linux-2.6.23/drivers/ssb/driver_chipcommon.c +Index: linux-2.6.23.16/drivers/ssb/driver_chipcommon.c =================================================================== ---- linux-2.6.23.orig/drivers/ssb/driver_chipcommon.c 2007-10-14 04:32:45.797470966 +0200 -+++ linux-2.6.23/drivers/ssb/driver_chipcommon.c 2007-10-14 04:33:25.175715001 +0200 -@@ -351,21 +351,6 @@ +--- linux-2.6.23.16.orig/drivers/ssb/driver_chipcommon.c 2008-02-19 01:35:53.000000000 +0100 ++++ linux-2.6.23.16/drivers/ssb/driver_chipcommon.c 2008-02-19 02:01:16.000000000 +0100 +@@ -351,21 +351,6 @@ void ssb_chipco_watchdog_timer_set(struc chipco_write32(cc, SSB_CHIPCO_WATCHDOG, ticks); } @@ -182,11 +182,11 @@ Index: linux-2.6.23/drivers/ssb/driver_chipcommon.c #ifdef CONFIG_SSB_SERIAL int ssb_chipco_serial_init(struct ssb_chipcommon *cc, struct ssb_serial_port *ports) -Index: linux-2.6.23/drivers/ssb/driver_extif.c +Index: linux-2.6.23.16/drivers/ssb/driver_extif.c =================================================================== ---- linux-2.6.23.orig/drivers/ssb/driver_extif.c 2007-10-14 04:32:45.809471640 +0200 -+++ linux-2.6.23/drivers/ssb/driver_extif.c 2007-10-14 04:33:25.179715231 +0200 -@@ -110,20 +110,4 @@ +--- linux-2.6.23.16.orig/drivers/ssb/driver_extif.c 2008-02-19 01:35:53.000000000 +0100 ++++ linux-2.6.23.16/drivers/ssb/driver_extif.c 2008-02-19 01:39:40.000000000 +0100 +@@ -110,20 +110,4 @@ void ssb_extif_get_clockcontrol(struct s *m = extif_read32(extif, SSB_EXTIF_CLOCK_SB); } @@ -207,11 +207,11 @@ Index: linux-2.6.23/drivers/ssb/driver_extif.c - mask, value); -} -Index: linux-2.6.23/include/linux/mod_devicetable.h +Index: linux-2.6.23.16/include/linux/mod_devicetable.h =================================================================== ---- linux-2.6.23.orig/include/linux/mod_devicetable.h 2007-10-14 04:35:22.102378272 +0200 -+++ linux-2.6.23/include/linux/mod_devicetable.h 2007-10-14 04:34:41.172045787 +0200 -@@ -340,4 +340,19 @@ +--- linux-2.6.23.16.orig/include/linux/mod_devicetable.h 2008-02-19 01:35:53.000000000 +0100 ++++ linux-2.6.23.16/include/linux/mod_devicetable.h 2008-02-19 01:39:40.000000000 +0100 +@@ -340,4 +340,19 @@ struct parisc_device_id { #define PA_HVERSION_ANY_ID 0xffff #define PA_SVERSION_ANY_ID 0xffffffff @@ -231,3 +231,62 @@ Index: linux-2.6.23/include/linux/mod_devicetable.h +#define SSB_ANY_REV 0xFF + #endif /* LINUX_MOD_DEVICETABLE_H */ +Index: linux-2.6.23.16/drivers/ssb/main.c +=================================================================== +--- linux-2.6.23.16.orig/drivers/ssb/main.c 2008-02-19 01:45:24.000000000 +0100 ++++ linux-2.6.23.16/drivers/ssb/main.c 2008-02-19 02:01:16.000000000 +0100 +@@ -321,14 +321,16 @@ static int ssb_bus_match(struct device * + return 0; + } + +-static int ssb_device_uevent(struct device *dev, struct kobj_uevent_env *env) ++static int ssb_device_uevent(struct device *dev, char **envp, ++ int num_envp, char *buffer, int buffer_size) + { + struct ssb_device *ssb_dev = dev_to_ssb_dev(dev); ++ int i = 0, len = 0; + + if (!dev) + return -ENODEV; + +- return add_uevent_var(env, ++ return add_uevent_var(envp, num_envp, &i, buffer, buffer_size, &len, + "MODALIAS=ssb:v%04Xid%04Xrev%02X", + ssb_dev->id.vendor, ssb_dev->id.coreid, + ssb_dev->id.revision); +Index: linux-2.6.23.16/drivers/ssb/scan.c +=================================================================== +--- linux-2.6.23.16.orig/drivers/ssb/scan.c 2008-02-16 19:08:13.000000000 +0100 ++++ linux-2.6.23.16/drivers/ssb/scan.c 2008-02-19 01:56:02.000000000 +0100 +@@ -391,12 +391,14 @@ int ssb_bus_scan(struct ssb_bus *bus, + if (bus->bustype == SSB_BUSTYPE_PCI) { + /* Ignore PCI cores on PCI-E cards. + * Ignore PCI-E cores on PCI cards. */ ++ //FIXME kernel 2.6.23 doesn't have is_pcie. Add this check back when updating to 2.6.24 or later. + if (dev->id.coreid == SSB_DEV_PCI) { +- if (bus->host_pci->is_pcie) +- continue; ++//FIXME if (bus->host_pci->is_pcie) ++//FIXME continue; + } else { +- if (!bus->host_pci->is_pcie) +- continue; ++ continue; //FIXME ++//FIXME if (!bus->host_pci->is_pcie) ++//FIXME continue; + } + } + if (bus->pcicore.dev) { +Index: linux-2.6.23.16/drivers/ssb/driver_pcicore.c +=================================================================== +--- linux-2.6.23.16.orig/drivers/ssb/driver_pcicore.c 2008-02-19 02:01:11.000000000 +0100 ++++ linux-2.6.23.16/drivers/ssb/driver_pcicore.c 2008-02-19 02:01:32.000000000 +0100 +@@ -362,7 +362,7 @@ static int pcicore_is_in_hostmode(struct + chipid_top != 0x5300) + return 0; + +- if (bus->sprom.r1.boardflags_lo & SSB_PCICORE_BFL_NOPCI) ++ if (bus->sprom.boardflags_lo & SSB_PCICORE_BFL_NOPCI) + return 0; + + /* The 200-pin BCM4712 package does not bond out PCI. Even when -- cgit v1.2.3