kernel: refresh patches
[openwrt/openwrt.git] / target / linux / brcm2708 / patches-3.14 / 0021-wifi-add-patches-from-3.6.y-tree-to-make-rtl8192cu-w.patch
1 From eaaa194153e61ed6f9fec8dda18f3e462187d327 Mon Sep 17 00:00:00 2001
2 From: popcornmix <popcornmix@gmail.com>
3 Date: Sat, 9 Nov 2013 13:32:03 +0000
4 Subject: [PATCH 21/54] wifi: add patches from 3.6.y tree to make rtl8192cu
5 work
6
7 wifi: add missing patch from 3.6.y tree to disable debug
8 ---
9 drivers/net/wireless/rtl8192cu/Kconfig | 4 +++-
10 drivers/net/wireless/rtl8192cu/Makefile | 6 +++++-
11 drivers/net/wireless/rtl8192cu/include/autoconf.h | 2 +-
12 drivers/net/wireless/rtl8192cu/os_dep/linux/os_intfs.c | 13 +++++++++++++
13 drivers/net/wireless/rtl8192cu/os_dep/linux/usb_intf.c | 1 +
14 5 files changed, 23 insertions(+), 3 deletions(-)
15
16 --- a/drivers/net/wireless/rtl8192cu/Kconfig
17 +++ b/drivers/net/wireless/rtl8192cu/Kconfig
18 @@ -1,6 +1,8 @@
19 config RTL8192CU
20 tristate "Realtek 8192C USB WiFi"
21 depends on USB
22 + select WIRELESS_EXT
23 + select WEXT_PRIV
24 ---help---
25 - Help message of RTL8192CU
26 + Enable wireless network adapters based on Realtek RTL8192C chipset family, such as EDUP nano series
27
28 --- a/drivers/net/wireless/rtl8192cu/Makefile
29 +++ b/drivers/net/wireless/rtl8192cu/Makefile
30 @@ -38,7 +38,7 @@ CONFIG_RTL8192CU_REDEFINE_1X1 = n
31 CONFIG_INTEL_WIDI = n
32 CONFIG_WAKE_ON_WLAN = n
33
34 -CONFIG_PLATFORM_I386_PC = y
35 +CONFIG_PLATFORM_I386_PC = n
36 CONFIG_PLATFORM_TI_AM3517 = n
37 CONFIG_PLATFORM_ANDROID_X86 = n
38 CONFIG_PLATFORM_JB_X86 = n
39 @@ -524,6 +524,10 @@ KVER := 3.3.0
40 #KSRC:= ../lichee/linux-3.3/
41 endif
42
43 +ifeq ($(CONFIG_ARCH_BCM2708), y)
44 +EXTRA_CFLAGS += -DCONFIG_LITTLE_ENDIAN
45 +endif
46 +
47 ifneq ($(USER_MODULE_NAME),)
48 MODULE_NAME := $(USER_MODULE_NAME)
49 endif
50 --- a/drivers/net/wireless/rtl8192cu/include/autoconf.h
51 +++ b/drivers/net/wireless/rtl8192cu/include/autoconf.h
52 @@ -296,7 +296,7 @@
53 //#define CONFIG_DEBUG_RTL871X
54
55 #define DBG 0
56 -#define CONFIG_DEBUG_RTL819X
57 +//#define CONFIG_DEBUG_RTL819X
58
59 #define CONFIG_PROC_DEBUG 1
60
61 --- a/drivers/net/wireless/rtl8192cu/os_dep/linux/os_intfs.c
62 +++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/os_intfs.c
63 @@ -277,6 +277,18 @@ static int rtw_proc_cnt = 0;
64
65 #define RTW_PROC_NAME DRV_NAME
66
67 +#ifndef create_proc_entry
68 +/* dummy routines */
69 +void rtw_proc_remove_one(struct net_device *dev)
70 +{
71 +}
72 +
73 +void rtw_proc_init_one(struct net_device *dev)
74 +{
75 +}
76 +
77 +#else /* create_proc_entry not defined */
78 +
79 void rtw_proc_init_one(struct net_device *dev)
80 {
81 struct proc_dir_entry *dir_dev = NULL;
82 @@ -751,6 +763,7 @@ void rtw_proc_remove_one(struct net_devi
83 }
84 }
85 }
86 +#endif /* create_proc_entry not defined */
87 #endif
88
89 uint loadparam( _adapter *padapter, _nic_hdl pnetdev);
90 --- a/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_intf.c
91 +++ b/drivers/net/wireless/rtl8192cu/os_dep/linux/usb_intf.c
92 @@ -138,6 +138,7 @@ static void rtw_dev_remove(struct usb_in
93 {USB_DEVICE(0x2001, 0x3307)},/* D-Link - Cameo */ \
94 {USB_DEVICE(0x2001, 0x330A)},/* D-Link - Alpha */ \
95 {USB_DEVICE(0x2001, 0x3309)},/* D-Link - Alpha */ \
96 + {USB_DEVICE(0x2001, 0x330D)},/* D-Link - Alpha(?) */ \
97 {USB_DEVICE(0x0586, 0x341F)},/* Zyxel - Abocom */ \
98 {USB_DEVICE(0x7392, 0x7822)},/* Edimax - Edimax */ \
99 {USB_DEVICE(0x2019, 0xAB2B)},/* Planex - Abocom */ \