--- trunk.orig/target/linux/ar71xx/patches-3.3/612-MIPS-ath79-TL-WR841-USB-support.patch	(revision 0)
+++ trunk/target/linux/ar71xx/patches-3.3/612-MIPS-ath79-TL-WR841-USB-support.patch	(working copy)
@@ -0,0 +1,11 @@
+diff -ruN a/arch/mips/ath79/Kconfig b/arch/mips/ath79/Kconfig
+--- a/arch/mips/ath79/Kconfig	2012-02-11 01:32:59.240396329 +0100
++++ b/arch/mips/ath79/Kconfig	2012-02-11 01:34:21.692805190 +0100
+@@ -450,6 +450,7 @@
+ 	select ATH79_DEV_GPIO_BUTTONS
+ 	select ATH79_DEV_LEDS_GPIO
+ 	select ATH79_DEV_M25P80
++	select ATH79_DEV_USB
+ 
+ config ATH79_MACH_TL_WR941ND
+ 	bool "TP-LINK TL-WR941ND support"
--- trunk.orig/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-mr3x20.c	(revision 32461)
+++ trunk/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-mr3x20.c	(working copy)
@@ -140,6 +140,7 @@
 	ath79_register_leds_gpio(-1, ARRAY_SIZE(tl_mr3x20_leds_gpio) - 1,
 				 tl_mr3x20_leds_gpio);
 	ap9x_pci_setup_wmac_led_pin(0, 0);
+	tl_mr3x20_usb_setup();
 }
 
 MIPS_MACHINE(ATH79_MACH_TL_WR841N_V7, "TL-WR841N-v7",
--- trunk.orig/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr841n.c	(revision 32461)
+++ trunk/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr841n.c	(working copy)
@@ -12,6 +12,8 @@
 #include <linux/mtd/partitions.h>
 #include <linux/platform_device.h>
 
+#include <linux/gpio.h>
+
 #include <asm/mach-ath79/ath79.h>
 
 #include "dev-dsa.h"
@@ -22,6 +24,8 @@
 #include "machtypes.h"
 #include "pci.h"
 
+#include "dev-usb.h"
+
 #define TL_WR841ND_V1_GPIO_LED_SYSTEM		2
 #define TL_WR841ND_V1_GPIO_LED_QSS_GREEN	4
 #define TL_WR841ND_V1_GPIO_LED_QSS_RED		5
@@ -29,6 +33,8 @@
 #define TL_WR841ND_V1_GPIO_BTN_RESET		3
 #define TL_WR841ND_V1_GPIO_BTN_QSS		7
 
+#define TL_WR841ND_V1_GPIO_USB_POWER		6
+
 #define TL_WR841ND_V1_KEYS_POLL_INTERVAL	20	/* msecs */
 #define TL_WR841ND_V1_KEYS_DEBOUNCE_INTERVAL \
 				(3 * TL_WR841ND_V1_KEYS_POLL_INTERVAL)
@@ -110,10 +116,22 @@
 	.chip		= &tl_wr841n_v1_dsa_chip,
 };
 
+static void __init tl_wr841_usb_setup(void)
+{
+	/* enable power for the USB port */
+	gpio_request(TL_WR841ND_V1_GPIO_USB_POWER, "USB power");
+	gpio_direction_output(TL_WR841ND_V1_GPIO_USB_POWER, 1);
+
+	ath79_register_usb();
+}
+
 static void __init tl_wr841n_v1_setup(void)
 {
 	u8 *mac = (u8 *) KSEG1ADDR(0x1f01fc00);
 
+
+	tl_wr841_usb_setup();
+
 	ath79_register_mdio(0, 0x0);
 
 	ath79_init_mac(ath79_eth0_data.mac_addr, mac, 0);
