From 41f07b22f88a263bbd1e2166181696f36775038d Mon Sep 17 00:00:00 2001 From: mb Date: Thu, 28 Feb 2008 11:34:36 +0000 Subject: [PATCH] SSB-GigE: Fix IRQ routing. This makes the device work. Yay! :) git-svn-id: svn://svn.openwrt.org/openwrt/trunk@10532 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- .../700-ssb-gigabit-ethernet-driver.patch | 27 +++++++++++++++---- 1 file changed, 22 insertions(+), 5 deletions(-) diff --git a/target/linux/brcm47xx/patches-2.6.23/700-ssb-gigabit-ethernet-driver.patch b/target/linux/brcm47xx/patches-2.6.23/700-ssb-gigabit-ethernet-driver.patch index 7bae2b0c0..90346e289 100644 --- a/target/linux/brcm47xx/patches-2.6.23/700-ssb-gigabit-ethernet-driver.patch +++ b/target/linux/brcm47xx/patches-2.6.23/700-ssb-gigabit-ethernet-driver.patch @@ -31,8 +31,8 @@ Index: linux-2.6.23.16/drivers/ssb/Makefile Index: linux-2.6.23.16/drivers/ssb/driver_gige.c =================================================================== --- /dev/null 1970-01-01 00:00:00.000000000 +0000 -+++ linux-2.6.23.16/drivers/ssb/driver_gige.c 2008-02-22 20:59:46.000000000 +0100 -@@ -0,0 +1,281 @@ ++++ linux-2.6.23.16/drivers/ssb/driver_gige.c 2008-02-28 12:26:18.000000000 +0100 +@@ -0,0 +1,286 @@ +/* + * Sonics Silicon Backplane + * Broadcom Gigabit Ethernet core driver @@ -49,16 +49,17 @@ Index: linux-2.6.23.16/drivers/ssb/driver_gige.c +#include + + ++/* +MODULE_DESCRIPTION("SSB Broadcom Gigabit Ethernet driver"); +MODULE_AUTHOR("Michael Buesch"); +MODULE_LICENSE("GPL"); -+ ++*/ + +static const struct ssb_device_id ssb_gige_tbl[] = { + SSB_DEVICE(SSB_VENDOR_BROADCOM, SSB_DEV_ETHERNET_GBIT, SSB_ANY_REV), + SSB_DEVTABLE_END +}; -+MODULE_DEVICE_TABLE(ssb, ssb_gige_tbl); ++/* MODULE_DEVICE_TABLE(ssb, ssb_gige_tbl); */ + + +static inline u8 gige_read8(struct ssb_gige *dev, u16 offset) @@ -288,6 +289,10 @@ Index: linux-2.6.23.16/drivers/ssb/driver_gige.c + res->start = dev->mem_resource.start; + res->end = dev->mem_resource.end; + ++ /* Fixup interrupt lines. */ ++ pdev->irq = ssb_mips_irq(sdev) + 2; ++ pci_write_config_byte(pdev, PCI_INTERRUPT_LINE, pdev->irq); ++ + return 0; +} + @@ -912,7 +917,7 @@ Index: linux-2.6.23.16/drivers/ssb/ssb_private.h Index: linux-2.6.23.16/drivers/net/tg3.c =================================================================== --- linux-2.6.23.16.orig/drivers/net/tg3.c 2008-02-22 19:40:57.000000000 +0100 -+++ linux-2.6.23.16/drivers/net/tg3.c 2008-02-27 23:18:31.000000000 +0100 ++++ linux-2.6.23.16/drivers/net/tg3.c 2008-02-28 12:28:17.000000000 +0100 @@ -38,6 +38,7 @@ #include #include @@ -1229,3 +1234,15 @@ Index: linux-2.6.23.16/drivers/net/tg3.h struct tg3_hw_stats *hw_stats; dma_addr_t stats_mapping; +Index: linux-2.6.23.16/drivers/ssb/driver_mipscore.c +=================================================================== +--- linux-2.6.23.16.orig/drivers/ssb/driver_mipscore.c 2008-02-20 20:02:43.000000000 +0100 ++++ linux-2.6.23.16/drivers/ssb/driver_mipscore.c 2008-02-28 12:16:12.000000000 +0100 +@@ -211,6 +211,7 @@ void ssb_mipscore_init(struct ssb_mipsco + /* fallthrough */ + case SSB_DEV_PCI: + case SSB_DEV_ETHERNET: ++ case SSB_DEV_ETHERNET_GBIT: + case SSB_DEV_80211: + case SSB_DEV_USB20_HOST: + /* These devices get their own IRQ line if available, the rest goes on IRQ0 */ -- 2.20.1