From 88401c2052f78509c26b72d24c7fb0c260ec55f2 Mon Sep 17 00:00:00 2001
From: Imre Kaloz <kaloz@openwrt.org>
Date: Wed, 11 Nov 2009 11:38:02 +0000
Subject: [PATCH] we don't support the 2.6.27 kernels for a long time now

SVN-Revision: 18369
---
 target/linux/ar7/config-2.6.27                | 143 ------------------
 .../patches-2.6.27/100-board_support.patch    |  86 -----------
 .../linux/ar7/patches-2.6.27/110-flash.patch  |  26 ----
 .../ar7/patches-2.6.27/120-gpio_chrdev.patch  |  28 ----
 .../linux/ar7/patches-2.6.27/130-vlynq.patch  |  20 ---
 .../patches-2.6.27/140-watchdog_bootcr.patch  |  29 ----
 .../patches-2.6.27/150-cpmac_not_broken.patch |  11 --
 .../160-cpmac_up_and_running.patch            |  47 ------
 .../patches-2.6.27/500-serial_kludge.patch    |  40 -----
 .../patches-2.6.27/900-cpmac_multiqueue.patch |  70 ---------
 .../patches-2.6.27/910-cpmac_fixed_phy.patch  |  92 -----------
 11 files changed, 592 deletions(-)
 delete mode 100644 target/linux/ar7/config-2.6.27
 delete mode 100644 target/linux/ar7/patches-2.6.27/100-board_support.patch
 delete mode 100644 target/linux/ar7/patches-2.6.27/110-flash.patch
 delete mode 100644 target/linux/ar7/patches-2.6.27/120-gpio_chrdev.patch
 delete mode 100644 target/linux/ar7/patches-2.6.27/130-vlynq.patch
 delete mode 100644 target/linux/ar7/patches-2.6.27/140-watchdog_bootcr.patch
 delete mode 100644 target/linux/ar7/patches-2.6.27/150-cpmac_not_broken.patch
 delete mode 100644 target/linux/ar7/patches-2.6.27/160-cpmac_up_and_running.patch
 delete mode 100644 target/linux/ar7/patches-2.6.27/500-serial_kludge.patch
 delete mode 100644 target/linux/ar7/patches-2.6.27/900-cpmac_multiqueue.patch
 delete mode 100644 target/linux/ar7/patches-2.6.27/910-cpmac_fixed_phy.patch

diff --git a/target/linux/ar7/config-2.6.27 b/target/linux/ar7/config-2.6.27
deleted file mode 100644
index 2d74680c8bc5..000000000000
--- a/target/linux/ar7/config-2.6.27
+++ /dev/null
@@ -1,143 +0,0 @@
-CONFIG_32BIT=y
-# CONFIG_64BIT is not set
-CONFIG_AR7_GPIO=y
-CONFIG_AR7_WDT=y
-CONFIG_AR7=y
-# CONFIG_ARCH_HAS_ILOG2_U32 is not set
-# CONFIG_ARCH_HAS_ILOG2_U64 is not set
-CONFIG_ARCH_POPULATES_NODE_MAP=y
-# CONFIG_ARCH_SUPPORTS_MSI is not set
-CONFIG_ARCH_SUPPORTS_OPROFILE=y
-CONFIG_ARCH_SUSPEND_POSSIBLE=y
-CONFIG_BASE_SMALL=0
-# CONFIG_BCM47XX is not set
-CONFIG_BITREVERSE=y
-CONFIG_BOOT_ELF32=y
-CONFIG_CEVT_R4K=y
-CONFIG_CLASSIC_RCU=y
-CONFIG_CMDLINE="rootfstype=squashfs,jffs2"
-CONFIG_CPMAC=y
-# CONFIG_CPU_BIG_ENDIAN is not set
-CONFIG_CPU_HAS_LLSC=y
-CONFIG_CPU_HAS_PREFETCH=y
-CONFIG_CPU_HAS_SYNC=y
-CONFIG_CPU_LITTLE_ENDIAN=y
-# CONFIG_CPU_LOONGSON2 is not set
-CONFIG_CPU_MIPS32_R1=y
-# CONFIG_CPU_MIPS32_R2 is not set
-CONFIG_CPU_MIPS32=y
-# CONFIG_CPU_MIPS64_R1 is not set
-# CONFIG_CPU_MIPS64_R2 is not set
-CONFIG_CPU_MIPSR1=y
-# CONFIG_CPU_NEVADA is not set
-# CONFIG_CPU_R10000 is not set
-# CONFIG_CPU_R3000 is not set
-# CONFIG_CPU_R4300 is not set
-# CONFIG_CPU_R4X00 is not set
-# CONFIG_CPU_R5000 is not set
-# CONFIG_CPU_R5432 is not set
-# CONFIG_CPU_R6000 is not set
-# CONFIG_CPU_R8000 is not set
-# CONFIG_CPU_RM7000 is not set
-# CONFIG_CPU_RM9000 is not set
-# CONFIG_CPU_SB1 is not set
-CONFIG_CPU_SUPPORTS_32BIT_KERNEL=y
-CONFIG_CPU_SUPPORTS_HIGHMEM=y
-# CONFIG_CPU_TX39XX is not set
-# CONFIG_CPU_TX49XX is not set
-# CONFIG_CPU_VR41XX is not set
-CONFIG_CSRC_R4K=y
-# CONFIG_DM9000 is not set
-CONFIG_DMA_NEED_PCI_MAP_STATE=y
-CONFIG_DMA_NONCOHERENT=y
-CONFIG_EARLY_PRINTK=y
-CONFIG_FIXED_PHY=y
-CONFIG_GENERIC_CLOCKEVENTS_BUILD=y
-CONFIG_GENERIC_CLOCKEVENTS=y
-CONFIG_GENERIC_CMOS_UPDATE=y
-# CONFIG_GENERIC_FIND_FIRST_BIT is not set
-CONFIG_GENERIC_FIND_NEXT_BIT=y
-CONFIG_GENERIC_GPIO=y
-CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y
-CONFIG_HAS_DMA=y
-CONFIG_HAS_IOMEM=y
-CONFIG_HAS_IOPORT=y
-CONFIG_HAVE_ARCH_KGDB=y
-# CONFIG_HAVE_ARCH_TRACEHOOK is not set
-# CONFIG_HAVE_CLK is not set
-# CONFIG_HAVE_DMA_ATTRS is not set
-# CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS is not set
-# CONFIG_HAVE_GENERIC_DMA_COHERENT is not set
-CONFIG_HAVE_IDE=y
-# CONFIG_HAVE_IOREMAP_PROT is not set
-# CONFIG_HAVE_KPROBES is not set
-# CONFIG_HAVE_KRETPROBES is not set
-CONFIG_HAVE_OPROFILE=y
-CONFIG_HW_RANDOM=y
-# CONFIG_I2C is not set
-# CONFIG_IDE is not set
-CONFIG_INITRAMFS_SOURCE=""
-CONFIG_IRQ_CPU=y
-# CONFIG_ISDN is not set
-CONFIG_KALLSYMS=y
-CONFIG_LEDS_GPIO=y
-# CONFIG_LEMOTE_FULONG is not set
-# CONFIG_MACH_ALCHEMY is not set
-# CONFIG_MACH_DECSTATION is not set
-# CONFIG_MACH_JAZZ is not set
-# CONFIG_MACH_TX39XX is not set
-# CONFIG_MACH_TX49XX is not set
-# CONFIG_MACH_VR41XX is not set
-# CONFIG_MIKROTIK_RB532 is not set
-# CONFIG_MIPS_COBALT is not set
-CONFIG_MIPS_L1_CACHE_SHIFT=5
-# CONFIG_MIPS_MACHINE is not set
-# CONFIG_MIPS_MALTA is not set
-CONFIG_MIPS_MT_DISABLED=y
-# CONFIG_MIPS_MT_SMP is not set
-# CONFIG_MIPS_MT_SMTC is not set
-# CONFIG_MIPS_SIM is not set
-CONFIG_MIPS=y
-CONFIG_MTD_AR7_PARTS=y
-CONFIG_MTD_CFI_STAA=y
-CONFIG_MTD_PHYSMAP_BANKWIDTH=2
-CONFIG_MTD_PHYSMAP_LEN=0
-CONFIG_MTD_PHYSMAP_START=0x10000000
-CONFIG_MTD_PHYSMAP=y
-CONFIG_NO_EXCEPT_FILL=y
-# CONFIG_NO_IOPORT is not set
-CONFIG_PAGEFLAGS_EXTENDED=y
-# CONFIG_PCSPKR_PLATFORM is not set
-CONFIG_PHYLIB=y
-# CONFIG_PMC_MSP is not set
-# CONFIG_PMC_YOSEMITE is not set
-# CONFIG_PNX8550_JBS is not set
-# CONFIG_PNX8550_STB810 is not set
-# CONFIG_PROBE_INITRD_HEADER is not set
-CONFIG_SCHED_NO_NO_OMIT_FRAME_POINTER=y
-# CONFIG_SCSI_DMA is not set
-# CONFIG_SERIAL_8250_EXTENDED is not set
-# CONFIG_SGI_IP22 is not set
-# CONFIG_SGI_IP27 is not set
-# CONFIG_SGI_IP28 is not set
-# CONFIG_SGI_IP32 is not set
-# CONFIG_SIBYTE_BIGSUR is not set
-# CONFIG_SIBYTE_CARMEL is not set
-# CONFIG_SIBYTE_CRHINE is not set
-# CONFIG_SIBYTE_CRHONE is not set
-# CONFIG_SIBYTE_LITTLESUR is not set
-# CONFIG_SIBYTE_RHONE is not set
-# CONFIG_SIBYTE_SENTOSA is not set
-# CONFIG_SIBYTE_SWARM is not set
-CONFIG_SWAP_IO_SPACE=y
-CONFIG_SYS_HAS_CPU_MIPS32_R1=y
-CONFIG_SYS_HAS_EARLY_PRINTK=y
-CONFIG_SYS_SUPPORTS_32BIT_KERNEL=y
-CONFIG_SYS_SUPPORTS_ARBIT_HZ=y
-CONFIG_SYS_SUPPORTS_BIG_ENDIAN=y
-CONFIG_SYS_SUPPORTS_LITTLE_ENDIAN=y
-CONFIG_TICK_ONESHOT=y
-CONFIG_TRAD_SIGNALS=y
-# CONFIG_VGASTATE is not set
-CONFIG_VLYNQ=y
-CONFIG_ZONE_DMA_FLAG=0
diff --git a/target/linux/ar7/patches-2.6.27/100-board_support.patch b/target/linux/ar7/patches-2.6.27/100-board_support.patch
deleted file mode 100644
index 58bd909fbc20..000000000000
--- a/target/linux/ar7/patches-2.6.27/100-board_support.patch
+++ /dev/null
@@ -1,86 +0,0 @@
---- a/arch/mips/Kconfig
-+++ b/arch/mips/Kconfig
-@@ -19,6 +19,24 @@ choice
- 	prompt "System type"
- 	default SGI_IP22
- 
-+config AR7
-+	bool "Texas Instruments AR7"
-+	select BOOT_ELF32
-+	select DMA_NONCOHERENT
-+	select CEVT_R4K
-+	select CSRC_R4K
-+	select IRQ_CPU
-+	select NO_EXCEPT_FILL
-+	select SWAP_IO_SPACE
-+	select SYS_HAS_CPU_MIPS32_R1
-+	select SYS_HAS_EARLY_PRINTK
-+	select SYS_SUPPORTS_32BIT_KERNEL
-+	select SYS_SUPPORTS_KGDB
-+	select SYS_SUPPORTS_LITTLE_ENDIAN
-+	select SYS_SUPPORTS_BIG_ENDIAN
-+	select GENERIC_GPIO
-+	select GENERIC_HARDIRQS_NO__DO_IRQ
-+
- config MACH_ALCHEMY
- 	bool "Alchemy processor based machines"
- 
---- a/arch/mips/kernel/traps.c
-+++ b/arch/mips/kernel/traps.c
-@@ -1203,9 +1203,22 @@ void *set_except_vector(int n, void *add
- 
- 	exception_handlers[n] = handler;
- 	if (n == 0 && cpu_has_divec) {
--		*(u32 *)(ebase + 0x200) = 0x08000000 |
--					  (0x03ffffff & (handler >> 2));
--		local_flush_icache_range(ebase + 0x200, ebase + 0x204);
-+		if ((handler ^ (ebase + 4)) & 0xfc000000) {
-+			/* lui k0, 0x0000 */
-+			*(u32 *)(ebase + 0x200) = 0x3c1a0000 | (handler >> 16);
-+			/* ori k0, 0x0000 */
-+			*(u32 *)(ebase + 0x204) =
-+					0x375a0000 | (handler & 0xffff);
-+			/* jr k0 */
-+			*(u32 *)(ebase + 0x208) = 0x03400008;
-+			/* nop */
-+			*(u32 *)(ebase + 0x20C) = 0x00000000;
-+			flush_icache_range(ebase + 0x200, ebase + 0x210);
-+		} else {
-+			*(u32 *)(ebase + 0x200) =
-+				0x08000000 | (0x03ffffff & (handler >> 2));
-+			flush_icache_range(ebase + 0x200, ebase + 0x204);
-+		}
- 	}
- 	return (void *)old_handler;
- }
---- a/arch/mips/Makefile
-+++ b/arch/mips/Makefile
-@@ -167,6 +167,13 @@ libs-$(CONFIG_SIBYTE_CFE)	+= arch/mips/s
- #
- 
- #
-+# Texas Instruments AR7
-+#
-+core-$(CONFIG_AR7)		+= arch/mips/ar7/
-+cflags-$(CONFIG_AR7)		+= -Iinclude/asm-mips/ar7
-+load-$(CONFIG_AR7)		+= 0xffffffff94100000
-+
-+#
- # Acer PICA 61, Mips Magnum 4000 and Olivetti M700.
- #
- core-$(CONFIG_MACH_JAZZ)	+= arch/mips/jazz/
---- a/include/asm-mips/page.h
-+++ b/include/asm-mips/page.h
-@@ -182,8 +182,10 @@ typedef struct { unsigned long pgprot; }
- #define VM_DATA_DEFAULT_FLAGS	(VM_READ | VM_WRITE | VM_EXEC | \
- 				 VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC)
- 
--#define UNCAC_ADDR(addr)	((addr) - PAGE_OFFSET + UNCAC_BASE)
--#define CAC_ADDR(addr)		((addr) - UNCAC_BASE + PAGE_OFFSET)
-+#define UNCAC_ADDR(addr)	((addr) - PAGE_OFFSET + UNCAC_BASE +	\
-+				 PHYS_OFFSET)
-+#define CAC_ADDR(addr)		((addr) - UNCAC_BASE + PAGE_OFFSET -	\
-+				 PHYS_OFFSET)
- 
- #include <asm-generic/memory_model.h>
- #include <asm-generic/page.h>
diff --git a/target/linux/ar7/patches-2.6.27/110-flash.patch b/target/linux/ar7/patches-2.6.27/110-flash.patch
deleted file mode 100644
index 60c7f335d5cb..000000000000
--- a/target/linux/ar7/patches-2.6.27/110-flash.patch
+++ /dev/null
@@ -1,26 +0,0 @@
---- a/drivers/mtd/Kconfig
-+++ b/drivers/mtd/Kconfig
-@@ -188,6 +188,12 @@ config MTD_MYLOADER_PARTS
- 	  You will still need the parsing functions to be called by the driver
- 	  for your particular device. It won't happen automatically.
- 
-+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
---- a/drivers/mtd/maps/physmap.c
-+++ b/drivers/mtd/maps/physmap.c
-@@ -85,7 +85,7 @@ static int physmap_flash_remove(struct p
- 
- 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.27/120-gpio_chrdev.patch b/target/linux/ar7/patches-2.6.27/120-gpio_chrdev.patch
deleted file mode 100644
index 5df86ee6dbc2..000000000000
--- a/target/linux/ar7/patches-2.6.27/120-gpio_chrdev.patch
+++ /dev/null
@@ -1,28 +0,0 @@
---- a/drivers/char/Kconfig
-+++ b/drivers/char/Kconfig
-@@ -968,6 +968,15 @@ config MWAVE
- 	  To compile this driver as a module, choose M here: the
- 	  module will be called mwave.
- 
-+config AR7_GPIO
-+	tristate "TI AR7 GPIO Support"
-+	depends on AR7
-+	help
-+	  Give userspace access to the GPIO pins on the Texas Instruments AR7 
-+	  processors.
-+
-+	  If compiled as a module, it will be called ar7_gpio.
-+
- config SCx200_GPIO
- 	tristate "NatSemi SCx200 GPIO Support"
- 	depends on SCx200
---- a/drivers/char/Makefile
-+++ b/drivers/char/Makefile
-@@ -90,6 +90,7 @@ obj-$(CONFIG_HW_RANDOM)		+= hw_random/
- obj-$(CONFIG_PPDEV)		+= ppdev.o
- obj-$(CONFIG_NWBUTTON)		+= nwbutton.o
- obj-$(CONFIG_NWFLASH)		+= nwflash.o
-+obj-$(CONFIG_AR7_GPIO)		+= ar7_gpio.o
- obj-$(CONFIG_SCx200_GPIO)	+= scx200_gpio.o
- obj-$(CONFIG_PC8736x_GPIO)	+= pc8736x_gpio.o
- obj-$(CONFIG_NSC_GPIO)		+= nsc_gpio.o
diff --git a/target/linux/ar7/patches-2.6.27/130-vlynq.patch b/target/linux/ar7/patches-2.6.27/130-vlynq.patch
deleted file mode 100644
index 9ab3638eaa18..000000000000
--- a/target/linux/ar7/patches-2.6.27/130-vlynq.patch
+++ /dev/null
@@ -1,20 +0,0 @@
---- a/drivers/Kconfig
-+++ b/drivers/Kconfig
-@@ -100,5 +100,7 @@ source "drivers/auxdisplay/Kconfig"
- 
- source "drivers/uio/Kconfig"
- 
-+source "drivers/vlynq/Kconfig"
-+
- source "drivers/xen/Kconfig"
- endmenu
---- a/drivers/Makefile
-+++ b/drivers/Makefile
-@@ -96,6 +96,7 @@ obj-$(CONFIG_DCA)		+= dca/
- obj-$(CONFIG_HID)		+= hid/
- obj-$(CONFIG_PPC_PS3)		+= ps3/
- obj-$(CONFIG_OF)		+= of/
-+obj-$(CONFIG_VLYNQ)		+= vlynq/
- obj-$(CONFIG_SSB)		+= ssb/
- obj-$(CONFIG_VIRTIO)		+= virtio/
- obj-$(CONFIG_REGULATOR)		+= regulator/
diff --git a/target/linux/ar7/patches-2.6.27/140-watchdog_bootcr.patch b/target/linux/ar7/patches-2.6.27/140-watchdog_bootcr.patch
deleted file mode 100644
index 95535def0c63..000000000000
--- a/target/linux/ar7/patches-2.6.27/140-watchdog_bootcr.patch
+++ /dev/null
@@ -1,29 +0,0 @@
---- a/drivers/watchdog/ar7_wdt.c	2009-01-25 01:17:01.000000000 +1300
-+++ b/drivers/watchdog/ar7_wdt.c	2009-01-25 01:19:15.000000000 +1300
-@@ -293,12 +293,26 @@
- 	.fops		= &ar7_wdt_fops,
- };
- 
-+#define AR7_WDT_HARDWARE_ENABLE 0x10
-+
- static int __init ar7_wdt_init(void)
- {
- 	int rc;
-+	u32 *bootcr;
-+	u32 bootcr_value;
- 
- 	ar7_wdt_get_regs();
- 
-+	/* arch/mips/ar7/clocks.c is the only other thing that reads this */
-+	bootcr = (u32 *)ioremap_nocache(AR7_REGS_DCL, 4);
-+	bootcr_value = *bootcr;
-+	iounmap(bootcr);
-+
-+	if (!(bootcr_value & AR7_WDT_HARDWARE_ENABLE)) {
-+		printk(KERN_INFO DRVNAME ": watchdog disabled in hardware (bootcr=%#x)\n", bootcr_value);
-+		return -ENODEV;
-+	}
-+
- 	if (!request_mem_region(ar7_regs_wdt, sizeof(struct ar7_wdt),
- 							LONGNAME)) {
- 		printk(KERN_WARNING DRVNAME ": watchdog I/O region busy\n");
diff --git a/target/linux/ar7/patches-2.6.27/150-cpmac_not_broken.patch b/target/linux/ar7/patches-2.6.27/150-cpmac_not_broken.patch
deleted file mode 100644
index e43369bdec00..000000000000
--- a/target/linux/ar7/patches-2.6.27/150-cpmac_not_broken.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- a/drivers/net/Kconfig
-+++ b/drivers/net/Kconfig
-@@ -1823,7 +1823,7 @@ config SC92031
- 
- config CPMAC
- 	tristate "TI AR7 CPMAC Ethernet support (EXPERIMENTAL)"
--	depends on NET_ETHERNET && EXPERIMENTAL && AR7 && BROKEN
-+	depends on NET_ETHERNET && EXPERIMENTAL && AR7
- 	select PHYLIB
- 	help
- 	  TI AR7 CPMAC Ethernet support
diff --git a/target/linux/ar7/patches-2.6.27/160-cpmac_up_and_running.patch b/target/linux/ar7/patches-2.6.27/160-cpmac_up_and_running.patch
deleted file mode 100644
index d11bbf2e58f3..000000000000
--- a/target/linux/ar7/patches-2.6.27/160-cpmac_up_and_running.patch
+++ /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.27/500-serial_kludge.patch b/target/linux/ar7/patches-2.6.27/500-serial_kludge.patch
deleted file mode 100644
index e7a4b24472f1..000000000000
--- a/target/linux/ar7/patches-2.6.27/500-serial_kludge.patch
+++ /dev/null
@@ -1,40 +0,0 @@
---- a/drivers/serial/8250.c
-+++ b/drivers/serial/8250.c
-@@ -264,6 +264,13 @@ static const struct serial8250_config ua
- 		.fcr		= UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_10,
- 		.flags		= UART_CAP_FIFO,
- 	},
-+	[PORT_AR7] = {
-+		.name		= "TI-AR7",
-+		.fifo_size	= 16,
-+		.tx_loadsz	= 16,
-+		.fcr		= UART_FCR_ENABLE_FIFO | UART_FCR_R_TRIG_00,
-+		.flags		= UART_CAP_FIFO | UART_CAP_AFE,
-+	},
- };
- 
- #if defined (CONFIG_SERIAL_8250_AU1X00)
-@@ -2552,7 +2559,11 @@ static void serial8250_console_putchar(s
- {
- 	struct uart_8250_port *up = (struct uart_8250_port *)port;
- 
-+#ifdef CONFIG_AR7
-+	wait_for_xmitr(up, BOTH_EMPTY);
-+#else
- 	wait_for_xmitr(up, UART_LSR_THRE);
-+#endif
- 	serial_out(up, UART_TX, ch);
- }
- 
---- a/include/linux/serial_core.h
-+++ b/include/linux/serial_core.h
-@@ -40,7 +40,8 @@
- #define PORT_NS16550A	14
- #define PORT_XSCALE	15
- #define PORT_RM9000	16	/* PMC-Sierra RM9xxx internal UART */
--#define PORT_MAX_8250	16	/* max port ID */
-+#define PORT_AR7	17
-+#define PORT_MAX_8250	17	/* max port ID */
- 
- /*
-  * ARM specific type numbers.  These are not currently guaranteed
diff --git a/target/linux/ar7/patches-2.6.27/900-cpmac_multiqueue.patch b/target/linux/ar7/patches-2.6.27/900-cpmac_multiqueue.patch
deleted file mode 100644
index c604aa4c3f56..000000000000
--- a/target/linux/ar7/patches-2.6.27/900-cpmac_multiqueue.patch
+++ /dev/null
@@ -1,70 +0,0 @@
-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
-+++ b/drivers/net/cpmac.c
-@@ -621,13 +621,13 @@ static void cpmac_end_xmit(struct net_de
- 
- 		dev_kfree_skb_irq(desc->skb);
- 		desc->skb = NULL;
--		if (netif_subqueue_stopped(dev, queue))
-+		if (__netif_subqueue_stopped(dev, queue))
- 			netif_wake_subqueue(dev, queue);
- 	} else {
- 		if (netif_msg_tx_err(priv) && net_ratelimit())
- 			printk(KERN_WARNING
- 			       "%s: end_xmit: spurious interrupt\n", dev->name);
--		if (netif_subqueue_stopped(dev, queue))
-+		if (__netif_subqueue_stopped(dev, queue))
- 			netif_wake_subqueue(dev, queue);
- 	}
- }
-@@ -737,7 +737,6 @@ static void cpmac_clear_tx(struct net_de
- 
- static void cpmac_hw_error(struct work_struct *work)
- {
--	int i;
- 	struct cpmac_priv *priv =
- 		container_of(work, struct cpmac_priv, reset_work);
- 
-@@ -824,7 +823,6 @@ static irqreturn_t cpmac_irq(int irq, vo
- 
- static void cpmac_tx_timeout(struct net_device *dev)
- {
--	int i;
- 	struct cpmac_priv *priv = netdev_priv(dev);
- 
- 	spin_lock(&priv->lock);
-@@ -1103,7 +1101,7 @@ static int external_switch;
- 
- 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;
-@@ -1132,6 +1130,7 @@ static int __devinit cpmac_probe(struct 
- 	}
- 
- 	dev = alloc_etherdev_mq(sizeof(*priv), CPMAC_QUEUES);
-+	//~ dev = alloc_etherdev(sizeof(*priv));
- 
- 	if (!dev) {
- 		printk(KERN_ERR "cpmac: Unable to allocate net_device\n");
diff --git a/target/linux/ar7/patches-2.6.27/910-cpmac_fixed_phy.patch b/target/linux/ar7/patches-2.6.27/910-cpmac_fixed_phy.patch
deleted file mode 100644
index dd4bb76a35e9..000000000000
--- a/target/linux/ar7/patches-2.6.27/910-cpmac_fixed_phy.patch
+++ /dev/null
@@ -1,92 +0,0 @@
-This is a hack to make cpmac work with the external switch on a DG834 v3; it
-should also work on other similar routers. It has not been tested on hardware
-with multiple cpmac devices or with no external switch. It may be safer to
-move external_switch to pdata rather than trying to detect it, and to set
-phy_mask correctly rather than moving the phy search loop.
-
---- a/drivers/net/cpmac.c	2008-11-11 06:18:24.000000000 +1100
-+++ b/drivers/net/cpmac.c	2009-04-11 10:58:58.000000000 +1000
-@@ -1124,8 +1124,8 @@
- 
- static int __devinit cpmac_probe(struct platform_device *pdev)
- {
-	int rc, phy_id;
--	char *mdio_bus_id = "0";
-+	char mdio_bus_id[BUS_ID_SIZE];
- 	struct resource *mem;
- 	struct cpmac_priv *priv;
- 	struct net_device *dev;
-@@ -1134,22 +1134,23 @@
- 
- 	pdata = pdev->dev.platform_data;
- 
--	for (phy_id = 0; phy_id < PHY_MAX_ADDR; phy_id++) {
--		if (!(pdata->phy_mask & (1 << phy_id)))
--			continue;
--		if (!cpmac_mii.phy_map[phy_id])
--			continue;
--		break;
-+	if (external_switch || dumb_switch) {
-+		strncpy(mdio_bus_id, "0", BUS_ID_SIZE); /* fixed phys bus */
-+		phy_id = pdev->id;
-+	} else {
-+		for (phy_id = 0; phy_id < PHY_MAX_ADDR; phy_id++) {
-+			if (!(pdata->phy_mask & (1 << phy_id)))
-+				continue;
-+			if (!cpmac_mii.phy_map[phy_id])
-+				continue;
-+			strncpy(mdio_bus_id, cpmac_mii.id, BUS_ID_SIZE);
-+			break;
-+		}
- 	}
- 
- 	if (phy_id == PHY_MAX_ADDR) {
--		if (external_switch || dumb_switch) {
--			mdio_bus_id = 0; /* fixed phys bus */
--			phy_id = pdev->id;
--		} else {
--			dev_err(&pdev->dev, "no PHY present\n");
--			return -ENODEV;
--		}
-+		dev_err(&pdev->dev, "no PHY present\n");
-+		return -ENODEV;
- 	}
- 
- #ifdef CONFIG_NETDEVICES_MULTIQUEUE
-@@ -1189,9 +1190,11 @@
- 	priv->ring_size = 64;
- 	priv->msg_enable = netif_msg_init(debug_level, 0xff);
- 	memcpy(dev->dev_addr, pdata->dev_addr, sizeof(dev->dev_addr));
-+	
-+	snprintf(priv->phy_name, BUS_ID_SIZE, PHY_ID_FMT, mdio_bus_id, phy_id);
- 
--	priv->phy = phy_connect(dev, cpmac_mii.phy_map[phy_id]->dev.bus_id,
--				&cpmac_adjust_link, 0, PHY_INTERFACE_MODE_MII);
-+	priv->phy = phy_connect(dev, priv->phy_name, &cpmac_adjust_link, 0,
-+	 			PHY_INTERFACE_MODE_MII);
- 	if (IS_ERR(priv->phy)) {
- 		if (netif_msg_drv(priv))
- 			printk(KERN_ERR "%s: Could not attach to PHY\n",
-@@ -1250,11 +1253,11 @@
- 
- 	cpmac_mii.reset(&cpmac_mii);
- 
--	for (i = 0; i < 300000; i++)
-+	for (i = 0; i < 300; i++)
- 		if ((mask = cpmac_read(cpmac_mii.priv, CPMAC_MDIO_ALIVE)))
- 			break;
- 		else
--			cpu_relax();
-+			msleep(10);
- 
- 	mask &= 0x7fffffff;
- 	if (mask & (mask - 1)) {
-@@ -1267,7 +1270,7 @@
- 	}
- 
- 	cpmac_mii.phy_mask = ~(mask | 0x80000000);
--	snprintf(cpmac_mii.id, MII_BUS_ID_SIZE, "0");
-+	snprintf(cpmac_mii.id, MII_BUS_ID_SIZE, "1");
- 
- 	res = mdiobus_register(&cpmac_mii);
- 	if (res)
-- 
2.30.2