aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFlorian Fainelli <florian@openwrt.org>2008-08-30 12:23:18 +0000
committerFlorian Fainelli <florian@openwrt.org>2008-08-30 12:23:18 +0000
commit94c30fd8964b4ac313841b9f259d202580b2ad54 (patch)
tree28b534c0114ef2cd97678960b1ecf24b1562b022
parentcee791127b9a6cdcb3de9ca27334ca2a9eee8a70 (diff)
downloadupstream-94c30fd8964b4ac313841b9f259d202580b2ad54.tar.gz
upstream-94c30fd8964b4ac313841b9f259d202580b2ad54.tar.bz2
upstream-94c30fd8964b4ac313841b9f259d202580b2ad54.zip
Switch ar7 to 2.6.26, thanks sn9
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@12436 3c298f89-4303-0410-b956-a3cf2f4a3e73
-rw-r--r--target/linux/ar7/Makefile2
-rw-r--r--target/linux/ar7/patches-2.6.26/110-flash.patch40
-rw-r--r--target/linux/ar7/patches-2.6.26/150-cpmac_up_and_running.diff47
-rw-r--r--target/linux/ar7/patches-2.6.26/900-cpmac_multiqueue.patch70
4 files changed, 111 insertions, 48 deletions
diff --git a/target/linux/ar7/Makefile b/target/linux/ar7/Makefile
index 8d48a2addb..4d07238070 100644
--- a/target/linux/ar7/Makefile
+++ b/target/linux/ar7/Makefile
@@ -11,7 +11,7 @@ BOARD:=ar7
BOARDNAME:=TI AR7
FEATURES:=squashfs jffs2 atm
-LINUX_VERSION:=2.6.25.16
+LINUX_VERSION:=2.6.26.3
include $(INCLUDE_DIR)/target.mk
diff --git a/target/linux/ar7/patches-2.6.26/110-flash.patch b/target/linux/ar7/patches-2.6.26/110-flash.patch
new file mode 100644
index 0000000000..39bf83affc
--- /dev/null
+++ b/target/linux/ar7/patches-2.6.26/110-flash.patch
@@ -0,0 +1,40 @@
+diff -ruN linux-2.6.26.3.orig/drivers/mtd/Kconfig linux-2.6.26.3/drivers/mtd/Kconfig
+--- linux-2.6.26.3.orig/drivers/mtd/Kconfig 2008-08-27 19:37:48.000000000 -0700
++++ linux-2.6.26.3/drivers/mtd/Kconfig 2008-08-27 19:39:14.000000000 -0700
+@@ -174,6 +174,12 @@
+ ---help---
+ TI AR7 partitioning support
+
++config MTD_AR7_PARTS
++ tristate "TI AR7 partitioning support"
++ depends on MTD_PARTITIONS
++ ---help---
++ TI AR7 partitioning support
++
+ comment "User Modules And Translation Layers"
+
+ config MTD_CHAR
+diff -ruN linux-2.6.26.3.orig/drivers/mtd/Makefile linux-2.6.26.3/drivers/mtd/Makefile
+--- linux-2.6.26.3.orig/drivers/mtd/Makefile 2008-08-27 19:37:48.000000000 -0700
++++ linux-2.6.26.3/drivers/mtd/Makefile 2008-08-27 19:39:14.000000000 -0700
+@@ -13,6 +13,7 @@
+ obj-$(CONFIG_MTD_AFS_PARTS) += afs.o
+ obj-$(CONFIG_MTD_AR7_PARTS) += ar7part.o
+ obj-$(CONFIG_MTD_OF_PARTS) += ofpart.o
++obj-$(CONFIG_MTD_AR7_PARTS) += ar7part.o
+
+ # 'Users' - code which presents functionality to userspace.
+ obj-$(CONFIG_MTD_CHAR) += mtdchar.o
+diff -ruN linux-2.6.26.3.orig/drivers/mtd/maps/physmap.c linux-2.6.26.3/drivers/mtd/maps/physmap.c
+--- linux-2.6.26.3.orig/drivers/mtd/maps/physmap.c 2008-08-27 19:37:48.000000000 -0700
++++ linux-2.6.26.3/drivers/mtd/maps/physmap.c 2008-08-27 19:39:14.000000000 -0700
+@@ -87,7 +87,8 @@
+
+ static const char *rom_probe_types[] = { "cfi_probe", "jedec_probe", "map_rom", NULL };
+ #ifdef CONFIG_MTD_PARTITIONS
+-static const char *part_probe_types[] = { "cmdlinepart", "RedBoot", NULL };
++static const char *part_probe_types[] = {"cmdlinepart", "RedBoot",
++ "ar7part", NULL };
+ #endif
+
+ static int physmap_flash_probe(struct platform_device *dev)
diff --git a/target/linux/ar7/patches-2.6.26/150-cpmac_up_and_running.diff b/target/linux/ar7/patches-2.6.26/150-cpmac_up_and_running.diff
deleted file mode 100644
index d11bbf2e58..0000000000
--- a/target/linux/ar7/patches-2.6.26/150-cpmac_up_and_running.diff
+++ /dev/null
@@ -1,47 +0,0 @@
---- a/arch/mips/ar7/platform.c
-+++ b/arch/mips/ar7/platform.c
-@@ -33,6 +33,8 @@
- #include <linux/vlynq.h>
- #include <linux/leds.h>
- #include <linux/string.h>
-+#include <linux/phy.h>
-+#include <linux/phy_fixed.h>
-
- #include <asm/addrspace.h>
- #include <asm/ar7/ar7.h>
-@@ -205,6 +207,13 @@
- .width = 2,
- };
-
-+/* lets assume this is suitable for both high and low cpmacs links */
-+static struct fixed_phy_status fixed_phy_status __initdata = {
-+ .link = 1,
-+ .speed = 100,
-+ .duplex = 1,
-+};
-+
- static struct plat_cpmac_data cpmac_low_data = {
- .reset_bit = 17,
- .power_bit = 20,
-@@ -506,6 +515,10 @@
- }
-
- if (ar7_has_high_cpmac()) {
-+ res = fixed_phy_add(PHY_POLL, cpmac_high.id, &fixed_phy_status);
-+ if (res && res != -ENODEV)
-+ return res;
-+
- cpmac_get_mac(1, cpmac_high_data.dev_addr);
- res = platform_device_register(&cpmac_high);
- if (res)
-@@ -514,6 +527,10 @@
- cpmac_low_data.phy_mask = 0xffffffff;
- }
-
-+ res = fixed_phy_add(PHY_POLL, cpmac_low.id, &fixed_phy_status);
-+ if (res && res != -ENODEV)
-+ return res;
-+
- cpmac_get_mac(0, cpmac_low_data.dev_addr);
- res = platform_device_register(&cpmac_low);
- if (res)
diff --git a/target/linux/ar7/patches-2.6.26/900-cpmac_multiqueue.patch b/target/linux/ar7/patches-2.6.26/900-cpmac_multiqueue.patch
new file mode 100644
index 0000000000..16e7320465
--- /dev/null
+++ b/target/linux/ar7/patches-2.6.26/900-cpmac_multiqueue.patch
@@ -0,0 +1,70 @@
+This patch fixes the network driver cpmac.c for compilation with
+configuration option CONFIG_NETDEVICES_MULTIQUEUE.
+
+These compiler warnings are fixed by the patch:
+drivers/net/cpmac.c: In function 'cpmac_end_xmit':
+drivers/net/cpmac.c:630: warning: passing argument 2 of 'netif_subqueue_stopped' makes pointer from integer without a cast
+drivers/net/cpmac.c:641: warning: passing argument 2 of 'netif_subqueue_stopped' makes pointer from integer without a cast
+drivers/net/cpmac.c: In function 'cpmac_probe':
+drivers/net/cpmac.c:1128: warning: unused variable 'i'
+
+During runtime, the unpatched driver raises a fatal runtime exception.
+This is fixed by calling __netif_subqueue_stopped instead
+of netif_subqueue_stopped, too.
+
+Two additional code parts were modified for CONFIG_NETDEVICES_MULTIQUEUE
+because other drivers do it in the same way.
+
+ Signed-off-by: Stefan Weil <weil@mail.berlios.de>
+
+--- a/drivers/net/cpmac.c 2008-07-13 23:51:29.000000000 +0200
++++ b/drivers/net/cpmac.c 2008-08-14 20:48:49.000000000 +0200
+@@ -627,7 +627,7 @@
+ dev_kfree_skb_irq(desc->skb);
+ desc->skb = NULL;
+ #ifdef CONFIG_NETDEVICES_MULTIQUEUE
+- if (netif_subqueue_stopped(dev, queue))
++ if (__netif_subqueue_stopped(dev, queue))
+ netif_wake_subqueue(dev, queue);
+ #else
+ if (netif_queue_stopped(dev))
+@@ -638,7 +638,7 @@
+ printk(KERN_WARNING
+ "%s: end_xmit: spurious interrupt\n", dev->name);
+ #ifdef CONFIG_NETDEVICES_MULTIQUEUE
+- if (netif_subqueue_stopped(dev, queue))
++ if (__netif_subqueue_stopped(dev, queue))
+ netif_wake_subqueue(dev, queue);
+ #else
+ if (netif_queue_stopped(dev))
+@@ -1124,7 +1124,7 @@
+
+ static int __devinit cpmac_probe(struct platform_device *pdev)
+ {
+- int rc, phy_id, i;
++ int rc, phy_id;
+ char *mdio_bus_id = "0";
+ struct resource *mem;
+ struct cpmac_priv *priv;
+@@ -1152,7 +1152,11 @@
+ }
+ }
+
++#ifdef CONFIG_NETDEVICES_MULTIQUEUE
+ dev = alloc_etherdev_mq(sizeof(*priv), CPMAC_QUEUES);
++#else
++ dev = alloc_etherdev(sizeof(*priv));
++#endif
+
+ if (!dev) {
+ printk(KERN_ERR "cpmac: Unable to allocate net_device\n");
+@@ -1179,7 +1183,9 @@
+ dev->set_multicast_list = cpmac_set_multicast_list;
+ dev->tx_timeout = cpmac_tx_timeout;
+ dev->ethtool_ops = &cpmac_ethtool_ops;
++#ifdef CONFIG_NETDEVICES_MULTIQUEUE
+ dev->features |= NETIF_F_MULTI_QUEUE;
++#endif
+
+ netif_napi_add(dev, &priv->napi, cpmac_poll, 64);
+