[go: nahoru, domu]

History log of /drivers/net/wireless/rtlwifi/base.c
Revision Date Author Comments
598a0df07fc6c4642f9b0497cef1233e41d4c987 20-Oct-2014 Kees Cook <keescook@chromium.org> rtlwifi: prevent format string usage from leaking

Use "%s" in the workqueue allocation to make sure the rtl_hal_cfg name
can never accidentally leak information via a format string.

Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
9afa2e44f4d8f9d031f815c32bb8f225f0f6746b 22-Sep-2014 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Modify base.{c,h} for new drivers

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
f7953b2ad66cc5fc66e13d5c0a40e61b45cdfca8 22-Sep-2014 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Modify core.c for new drivers

Each of the routines in the rtlwifi common driver needs to be modified
for the coming changes. This patch prepares core.c, but also touches other
files.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
fd09ff958777cf583d7541f180991c0fc50bd2f7 22-Sep-2014 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Remove extra workqueue for enter/leave power state

When the rtlwifi family of drivers was converted to use a workqueue when
entering or leaving power save mode (commits a269913c52, a5ffbe0a19,
41affd5286, b9116b9a2b, and 6539306b2c), the code began scheduling work from
the callback routine of a different workqueue with a resulting increase in
overhead.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
685328b296acc810541d2532957912690273c64a 06-Jan-2014 Johannes Berg <johannes.berg@intel.com> mac80211: remove channel_change_time

This value is no longer used by mac80211, and practically no
driver ever set it to a correct value anyway, so remove it.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
90908e1cd14716f1b989b97003007bfcc7be3d13 30-Dec-2013 Julia Lawall <Julia.Lawall@lip6.fr> rtlwifi: use ether_addr_equal_64bits

Ether_addr_equal_64bits is more efficient than ether_addr_equal, and can be
used when each argument is an array within a structure that contains at
least two bytes of data beyond the array.

The structures involved are:
ieee80211_hdr defined in include/linux/ieee80211.h and
rtl_mac defined in drivers/net/wireless/rtlwifi/wifi.h

This was done using Coccinelle (http://coccinelle.lip6.fr/).

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
8fd77aec1a9d6f4328fc0244f21932114e066df3 18-Nov-2013 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: rtl8192c: Prevent reconnect attempts if not connected

This driver has a watchdog timer that attempts to reconnect when beacon frames
are not seen for 6 seconds. This patch disables that reconnect whenever the
device has never been connected.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
0c5d63f0ab6728f05ddefa25aff55e31297f95e6 02-Nov-2013 Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> rtlwifi: Fix endian error in extracting packet type

All of the rtlwifi drivers have an error in the routine that tests if
the data is "special". If it is, the subsequant transmission will be
at the lowest rate to enhance reliability. The 16-bit quantity is
big-endian, but was being extracted in native CPU mode. One of the
effects of this bug is to inhibit association under some conditions
as the TX rate is too high.

Based on suggestions by Joe Perches, the entire routine is rewritten.

One of the local headers contained duplicates of some of the ETH_P_XXX
definitions. These are deleted.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk>
Cc: Stable <stable@vger.kernel.org> [2.6.38+]
Signed-off-by: John W. Linville <linville@tuxdriver.com>
4f4826da8cae59c167fc730b5db6f0659c2d37ce 26-Sep-2013 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Implement a common rtl_phy_scan_operation_backup() routine

Several of the drivers supported by rtlwifi individually implement the same
routine that supports scans. As a first step, create this routine in
driver rtlwifi.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
7367d0b573d149550d2ae25c402984b98f8f422e 01-Sep-2013 Joe Perches <joe@perches.com> drivers/net: Convert uses of compare_ether_addr to ether_addr_equal

Use the new bool function ether_addr_equal to add
some clarity and reduce the likelihood for misuse
of compare_ether_addr for sorting.

Done via cocci script: (and a little typing)

$ cat compare_ether_addr.cocci
@@
expression a,b;
@@
- !compare_ether_addr(a, b)
+ ether_addr_equal(a, b)

@@
expression a,b;
@@
- compare_ether_addr(a, b)
+ !ether_addr_equal(a, b)

@@
expression a,b;
@@
- !ether_addr_equal(a, b) == 0
+ ether_addr_equal(a, b)

@@
expression a,b;
@@
- !ether_addr_equal(a, b) != 0
+ !ether_addr_equal(a, b)

@@
expression a,b;
@@
- ether_addr_equal(a, b) == 0
+ !ether_addr_equal(a, b)

@@
expression a,b;
@@
- ether_addr_equal(a, b) != 0
+ ether_addr_equal(a, b)

@@
expression a,b;
@@
- !!ether_addr_equal(a, b)
+ ether_addr_equal(a, b)

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
6f334c2b3966f10cbd089bb124ec0e114d8d8c77 12-Jul-2013 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Fix build errors for unusual cases

The present build configuration for the rtlwifi family of drivers will
fail under two known conditions:

(1) If rtlwifi is selected without selecting any of the dependent drivers,
there are errors in the build.
(2) If the PCI drivers are built into the kernel and the USB drivers are modules,
or vice versa, there are missing globals.

The first condition is fixed by never building rtlwifi unless at least one
of the device drivers is selected. The second failure is fixed by splitting
the PCI and USB codes out of rtlwifi, and creating their own mini drivers.
If the drivers that use them are modules, they will also be modules.

Although a number of files are touched by this patch, only Makefile and Kconfig
have undergone significant changes. The only modifications to the other files
were to export entry points needed by the new rtl_pci and rtl_usb units, or to
rename two variables that had names that were likely to cause namespace collisions.

Reported-by: Fengguang Wu <fengguang.wu@intel.com> [Condition 1]
Reported-by: Ben Hutchings <bhutchings@solarflare.com> [Condition 2]
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Ben Hutchings <bhutchings@solarflare.com>
Cc: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
d8537548c924db3c44afde7646b6e220c7beb79d 04-Jul-2013 Kees Cook <keescook@chromium.org> drivers: avoid format strings in names passed to alloc_workqueue()

For the workqueue creation interfaces that do not expect format strings,
make sure they cannot accidently be parsed that way. Additionally, clean
up calls made with a single parameter that would be handled as a format
string. Many callers are passing potentially dynamic string content, so
use "%s" in those cases to avoid any potential accidents.

Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
27d7f47756f40fb1bc3159e09217f740f5c5b5b1 31-May-2013 Jingoo Han <jg1.han@samsung.com> net: wireless: replace strict_strtoul() with kstrtoul()

The usage of strict_strtoul() is not preferred, because
strict_strtoul() is obsolete. Thus, kstrtoul() should be
used.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
e6deaf810cc4b6437d55179660776e131ac059df 25-Mar-2013 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: rtl8192c: rtl8192ce: rtl8192cu: rtl8192de: rtl8723ae: Add changes required by adding rtl81988ee

This patch combines the remaining changes in the rtlwifi family to handle
the addition of rtl8188ee. A number of these changes eliminate some CamelCase
variable names, and other shorten common variable names so that long lines
in the new driver could be shortened.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: jcheung@suse.com
Cc: machen@suse.com
Cc: mmarek@suse.cz
Cc: zhiyuan_yang@realsil.com.cn
Signed-off-by: John W. Linville <linville@tuxdriver.com>
a269913c52ad37952a4d9953bb6d748f7299c304 25-Mar-2013 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Rework rtl_lps_leave() and rtl_lps_enter() to use work queue

In commit a5ffbe0, some of the calls to rtl_lps_leave() were switched
to be called from a work queue to avoid a scheduling while atomic bug.
This patch converts the remaining calls to use the work queue. In
addition, the call to rtl_lps_enter() is also switched to the work
queue. None of these newly converted calls had triggered the bug (yet),
but this change make all of them fit a single pattern.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: jcheung@suse.com
Cc: machen@suse.com
Cc: mmarek@suse.cz
Cc: zhiyuan_yang@realsil.com.cn
Cc: page_he@realsil.com.cn
Signed-off-by: John W. Linville <linville@tuxdriver.com>
26634c4b1868323f49f8cd24c3493b57819867fd 25-Mar-2013 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi Modify existing bits to match vendor version 2013.02.07

These changes add the new variables for P2P and modify the various struct
definitions for other new features.

This patch updates files base.{c,h} for the changes in the newest vendor
driver.

This patch updates files ps.{c,h} for the changes in the newest vendor
driver.

This patch updates files debug.{c,h}, efuse.c, pci.{c,h}, and wifi.h for
the changes in the newest vendor driver.

This patch updates files core.c, ps.c, rc.c, and wifi.h for
the changes in the newest vendor driver.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: jcheung@suse.com
Cc: machen@suse.com
Cc: mmarek@suse.cz
Cc: zhiyuan_yang@realsil.com.cn
Cc: page_he@realsil.com.cn
Signed-off-by: John W. Linville <linville@tuxdriver.com>
675a0b049abf6edf30f8dd84c5610b6edc2296c8 25-Mar-2013 Karl Beldan <karl.beldan@rivierawaves.com> mac80211: Use a cfg80211_chan_def in ieee80211_hw_conf_chan

Drivers that don't use chanctxes cannot perform VHT association because
they still use a "backward compatibility" pair of {ieee80211_channel,
nl80211_channel_type} in ieee80211_conf and ieee80211_local.

Signed-off-by: Karl Beldan <karl.beldan@rivierawaves.com>
[fix kernel-doc]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
e1a0c6b3a4b27ed5f21291d0bbee2167ec201ef5 07-Feb-2013 Johannes Berg <johannes.berg@intel.com> mac80211: stop toggling IEEE80211_HT_CAP_SUP_WIDTH_20_40

For VHT, many more bandwidth changes are possible. As a first
step, stop toggling the IEEE80211_HT_CAP_SUP_WIDTH_20_40 flag
in the HT capabilities and instead introduce a bandwidth field
indicating the currently usable bandwidth to transmit to the
station. Of course, make all drivers use it.

To achieve this, make ieee80211_ht_cap_ie_to_sta_ht_cap() get
the station as an argument, rather than the new capabilities,
so it can set up the new bandwidth field.

If the station is a VHT station and VHT bandwidth is in use,
also set the bandwidth accordingly.

Doing this allows us to get rid of the supports_40mhz flag as
the HT capabilities now reflect the true capability instead of
the current setting.

While at it, also fix ieee80211_ht_cap_ie_to_sta_ht_cap() to not
ignore HT cap overrides when MCS TX isn't supported (not that it
really happens...)

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
a5ffbe0a1993a27072742ef7db6cf9839956fce9 02-Feb-2013 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Fix scheduling while atomic bug

Kernel commits 41affd5 and 6539306 changed the locking in rtl_lps_leave()
from a spinlock to a mutex by doing the calls indirectly from a work queue
to reduce the time that interrupts were disabled. This change was fine for
most systems; however a scheduling while atomic bug was reported in
https://bugzilla.redhat.com/show_bug.cgi?id=903881. The backtrace indicates
that routine rtl_is_special(), which calls rtl_lps_leave() in three places
was entered in atomic context. These direct calls are replaced by putting a
request on the appropriate work queue.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Reported-and-tested-by: Nathaniel Doherty <ntdoherty@gmail.com>
Cc: Nathaniel Doherty <ntdoherty@gmail.com>
Cc: Stanislaw Gruszka <sgruszka@redhat.com>
Cc: Stable <stable@vger.kernel.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
0f01545346cd97f823fc0aaf0c02d4fc7bec6d46 25-Oct-2012 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: rtl8192ce: rtl8192cu: rtl8192se: rtl81723ae: Turn on building of the new driver

This patch completes the addition of the new driver for the Realtek
RTL8723AE devices by adding the make file and by modifying Kconfig
and Makefile of rtlwifi. Some variable names were shortened to ease
the problem of limiting all lines to 80 characters, thus changes were
made to wifi.h and rtl8192{ce,cu,sw}/hw.c.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: <chaoming_li@realsil.com.cn>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
36323f817af0376c78612cfdab714b0feb05fea5 23-Jul-2012 Thomas Huehn <thomas@net.t-labs.tu-berlin.de> mac80211: move TX station pointer and restructure TX

Remove the control.sta pointer from ieee80211_tx_info to free up
sufficient space in the TX skb control buffer for the upcoming
Transmit Power Control (TPC).
Instead, the pointer is now on the stack in a new control struct
that is passed as a function parameter to the drivers' tx method.

Signed-off-by: Thomas Huehn <thomas@net.t-labs.tu-berlin.de>
Signed-off-by: Alina Friedrichsen <x-alina@gmx.net>
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
[reworded commit message]
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
2a00def4d6e50cbfa7588887fdbe2a97042e42bb 11-Jul-2012 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Remove extra argument from queue setup routine

Remove unused argument hw from call to rtl_tid_to_ac().

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
2c208890c6d4e16076c6664137703ec813e8fa6c 04-Jun-2012 Joe Perches <joe@perches.com> wireless: Remove casts to same type

Adding casts of objects to the same type is unnecessary
and confusing for a human reader.

For example, this cast:

int y;
int *p = (int *)&y;

I used the coccinelle script below to find and remove these
unnecessary casts. I manually removed the conversions this
script produces of casts with __force, __iomem and __user.

@@
type T;
T *p;
@@

- (T *)p
+ p

Neatened the mwifiex_deauthenticate_infra function which
was doing odd things with array pointers and not using
is_zero_ether_addr.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2e42e4747ea72943c21551d8a206b51a9893b1e0 09-May-2012 Joe Perches <joe@perches.com> drivers/net: Convert compare_ether_addr to ether_addr_equal

Use the new bool function ether_addr_equal to add
some clarity and reduce the likelihood for misuse
of compare_ether_addr for sorting.

Done via cocci script:

$ cat compare_ether_addr.cocci
@@
expression a,b;
@@
- !compare_ether_addr(a, b)
+ ether_addr_equal(a, b)

@@
expression a,b;
@@
- compare_ether_addr(a, b)
+ !ether_addr_equal(a, b)

@@
expression a,b;
@@
- !ether_addr_equal(a, b) == 0
+ ether_addr_equal(a, b)

@@
expression a,b;
@@
- !ether_addr_equal(a, b) != 0
+ !ether_addr_equal(a, b)

@@
expression a,b;
@@
- ether_addr_equal(a, b) == 0
+ !ether_addr_equal(a, b)

@@
expression a,b;
@@
- ether_addr_equal(a, b) != 0
+ ether_addr_equal(a, b)

@@
expression a,b;
@@
- !!ether_addr_equal(a, b)
+ ether_addr_equal(a, b)

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
e89f7690a3adbde0af7c294f83c242ba6a367ef0 06-Apr-2012 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Fix oops on rate-control failure

When the rate-control indexing is incorrectly set up, mac80211 issues
a warning and returns NULL from the call to ieee80211_get_tx_rate().
When this happens, avoid a NULL pointer dereference.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
e1fa746029252c85b18b3d6ee5b0e066ce14383f 09-Feb-2012 Tristan Pourcelot <tristan.pourcelot@gmail.com> Correcting typos in rtlwifi/base.c

This patch correct some typos in a comment.

Signed-off-by: Tristan Pourcelot <tristan.pourcelot@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
b0302aba812bcc39291cdab9ad7e37008f352a91 30-Jan-2012 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Convert to asynchronous firmware load

This patch addresses a kernel bugzilla report and two recent mail threads.

The kernel bugzilla report is https://bugzilla.kernel.org/show_bug.cgi?id=42632,
which reports a udev timeout on boot.

The first mail thread, which was on LKML (http://lkml.indiana.edu/hypermail/
linux/kernel/1112.3/00965.html) was for a WARNING that occurs after a
suspend/resume cycle for rtl8192cu.

The scond mail thread (http://marc.info/?l=linux-wireless&m=132655490826766&w=2)
concerned changes in udev that break drivers that delay while firmware is loaded
on modprobe.

This patch converts all rtlwifi-based drivers to use the asynchronous firmware
loading mechanism. Drivers rtl8192ce, rtl8192cu and rtl8192de share a common
callback routine. Driver rtl8192se needs different handling of the firmware,
thus it has its own code.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stable <stable@vger.kernel.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
d273bb20c00340748e3ca9730f87524ec5abbd64 27-Jan-2012 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Move pr_fmt macros to a single location

Although the rtlwifi family of devices contains 11 copies of the pr_fmt
macro, the macro is not defined for all routines that need it. By moving
the macro to wifi.h, a single copy is available for all routines.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
c1288b1278d00169e12495eb53ad128e09560b69 19-Jan-2012 Johannes Berg <johannes.berg@intel.com> mac80211: make beacon filtering per virtual interface

Due to firmware limitations, we may not be able to
support beacon filtering on all virtual interfaces.
To allow this in mac80211, introduce per-interface
driver capability flags that the driver sets when
an interface is added.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Acked-by: Luciano Coelho <coelho@ti.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
a8d760668eebc98915383481cb3d9eaf74c2a615 08-Jan-2012 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Update copyright dates

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
f30d7507a8116e2099a9135c873411db8c0a3dc6 05-Jan-2012 Joe Perches <joe@perches.com> rtlwifi: Convert RT_TRACE macro to use ##__VA_ARGS__

Consolidate printks to avoid possible message interleaving
and reduce the object size.

Remove unnecessary RT_TRACE parentheses.

Miscellaneous typo and grammar fixes.
Add missing newlines to formats.
Remove duplicate KERN_DEBUG prefixes.
Coalesce formats.
Align arguments.

$ size drivers/net/wireless/rtlwifi/built-in.o*
text data bss dec hex filename
594841 55333 129680 779854 be64e drivers/net/wireless/rtlwifi/built-in.o.new
607022 55333 138720 801075 c3933 drivers/net/wireless/rtlwifi/built-in.o.old

Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
3db1cd5c05f35fb43eb134df6f321de4e63141f2 19-Dec-2011 Rusty Russell <rusty@rustcorp.com.au> net: fix assignment of 0/1 to bool variables.

DaveM said:
Please, this kind of stuff rots forever and not using bool properly
drives me crazy.

Joe Perches <joe@perches.com> gave me the spatch script:

@@
bool b;
@@
-b = 0
+b = false
@@
bool b;
@@
-b = 1
+b = true

I merely installed coccinelle, read the documentation and took credit.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
b9116b9a2b5db63187d28f99e038f473fad036dc 17-Dec-2011 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Fix locking problem introduces with commit 6539306b

When I tested commit 6539306, I did not notice that loading an out-of-tree
module turns off lockdep testing in kernel 3.2. For that reason, I missed
the kernel WARNING shown below:

The solution fixes the warning by partially reverting commit 6539306.

[ 84.168146] ------------[ cut here ]------------
[ 84.168155] WARNING: at kernel/mutex.c:198 mutex_lock_nested+0x309/0x310()
[ 84.168158] Hardware name: HP Pavilion dv2700 Notebook PC
[ 84.168161] Modules linked in: nfs lockd auth_rpcgss nfs_acl sunrpc af_packet cpufreq_conservative cpufreq_userspace cpufreq_powersave powernow_k8 mperf e
xt3 jbd ide_cd_mod cdrom snd_hda_codec_conexant arc4 rtl8192ce ide_pci_generic rtl8192c_common rtlwifi snd_hda_intel mac80211 snd_hda_codec snd_pcm snd_timer
amd74xx ide_core cfg80211 k8temp snd joydev soundcore hwmon battery forcedeth i2c_nforce2 sg rfkill ac serio_raw snd_page_alloc button video i2c_core ipv6 a
utofs4 ext4 mbcache jbd2 crc16 sd_mod ahci ohci_hcd libahci libata scsi_mod ehci_hcd usbcore usb_common fan processor thermal
[ 84.168231] Pid: 1218, comm: kworker/u:2 Not tainted 3.2.0-rc5-wl+ #155
[ 84.168234] Call Trace:
[ 84.168240] [<ffffffff81048aaa>] warn_slowpath_common+0x7a/0xb0
[ 84.168245] [<ffffffff81048af5>] warn_slowpath_null+0x15/0x20
[ 84.168249] [<ffffffff813811f9>] mutex_lock_nested+0x309/0x310
[ 84.168269] [<ffffffffa00793f9>] ? rtl_ips_nic_on+0x49/0xb0 [rtlwifi]
[ 84.168277] [<ffffffffa00793f9>] rtl_ips_nic_on+0x49/0xb0 [rtlwifi]
[ 84.168284] [<ffffffffa007ab85>] rtl_pci_tx+0x1b5/0x560 [rtlwifi]
[ 84.168291] [<ffffffffa007635a>] rtl_op_tx+0x9a/0xa0 [rtlwifi]
[ 84.168359] [<ffffffffa043cf51>] __ieee80211_tx+0x181/0x2b0 [mac80211]
[ 84.168375] [<ffffffffa043ef06>] ieee80211_tx+0xf6/0x120 [mac80211]
[ 84.168391] [<ffffffffa043ee49>] ? ieee80211_tx+0x39/0x120 [mac80211]
[ 84.168408] [<ffffffffa043f80b>] ieee80211_xmit+0xdb/0x100 [mac80211]
[ 84.168425] [<ffffffffa043f730>] ? ieee80211_skb_resize.isra.26+0xb0/0xb0 [mac80211]
[ 84.168441] [<ffffffffa0440b2a>] ieee80211_tx_skb_tid+0x5a/0x70 [mac80211]
[ 84.168458] [<ffffffffa0443da2>] ieee80211_send_auth+0x152/0x1b0 [mac80211]
[ 84.168474] [<ffffffffa042e169>] ieee80211_work_work+0x1049/0x1860 [mac80211]
[ 84.168489] [<ffffffffa042d120>] ? free_work+0x20/0x20 [mac80211]
[ 84.168504] [<ffffffffa042d120>] ? free_work+0x20/0x20 [mac80211]
[ 84.168510] [<ffffffff81065ffc>] process_one_work+0x17c/0x530
[ 84.168514] [<ffffffff81065f92>] ? process_one_work+0x112/0x530
[ 84.168519] [<ffffffff81066994>] worker_thread+0x164/0x350
[ 84.168524] [<ffffffff8108420d>] ? trace_hardirqs_on+0xd/0x10
[ 84.168528] [<ffffffff81066830>] ? manage_workers.isra.28+0x220/0x220
[ 84.168533] [<ffffffff8106bc17>] kthread+0x87/0x90
[ 84.168539] [<ffffffff813854b4>] kernel_thread_helper+0x4/0x10
[ 84.168543] [<ffffffff81382bdd>] ? retint_restore_args+0xe/0xe
[ 84.168547] [<ffffffff8106bb90>] ? __init_kthread_worker+0x70/0x70
[ 84.168552] [<ffffffff813854b0>] ? gs_change+0xb/0xb
[ 84.168554] ---[ end trace f25a4fdc768c028f ]---

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Stanislaw Gruska <sgruszka@redhat.com>
Cc: Chaoming Li <chaoming_li@realsil.com.cn>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
6539306b2c3ceafbc4094cf68c58094c282da053 12-Dec-2011 Stanislaw Gruszka <sgruszka@redhat.com> rtlwifi: merge ips,lps spinlocks into one mutex

With previous patch "rtlwifi: use work for lps" we can now use mutex for
protecting ps mode changing critical sections. This fixes running system
with interrupts disabled for long time.

Merge ips_lock and lps_lock as they seems to protect the same data
structures (accessed in rtl_ps_set_rf_state() function).

Reported-by: Philipp Dreimann <philipp@dreimann.net>
Tested-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Mike McCormack <mikem@ring3k.org>
Cc: Chaoming Li <chaoming_li@realsil.com.cn>
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Tested-by: Tim Gardner <tim.gardner@canonical.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
abfabc9b48f6943dbb707fcfc2ef2a04c329e3e8 17-Nov-2011 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: rtl8192cu: Fix endianian issues

Driver rtlwifi fails on a big-endian host.

These changes have been tested on a Mac PowerBook G4, which has
a PPC processor.

Although this patch touches some of the code that will affect endian
issues on PCI hardware through drivers rtl8192ce, rtl8192se, and
rtl8192de, these have not been tested due to lack of suitable hardware.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
9d9779e723a5d23b94abbe5bb7d1197921f6f3dd 03-Jul-2011 Paul Gortmaker <paul.gortmaker@windriver.com> drivers/net: Add module.h to drivers who were implicitly using it

The device.h header was including module.h, making it present for
most of these drivers. But we want to clean that up. Call out the
include of module.h in the modular network drivers.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
09e92f0be2cc14dc808de0c0f12b57981b8c027d 12-Oct-2011 Chaoming Li <chaoming_li@realsil.com.cn> rtlwifi: Update to new Realtek version - Part I

This patch incorporate the differences between the 06/20/2011 and
08/16/2011 Realtek releases of the rtlwifi driver.

The changes include:

1. Handling of IEEE80211_HW_CONNECTION_MONITOR.
2. Fix typo to get proper response to nullfunc frames.

Signed-off-by: Chaoming Li <chaoming_li@realsil.com.cn>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
7ad0ce3576edb2ea65bd5c93a83c4a6afaa1dd76 22-Aug-2011 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Install updated rate-mapping routine

In preparation for fixing the rate-mapping situation, place a driver-agnostic
version in rtlwifi. This one contains the updated rate incormation.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Chaoming Li <chaoming_li@realsil.com.cn>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
292b11926fec139c0ff103bc229bc6c079d0862f 20-Jul-2011 Joe Perches <joe@perches.com> rtlwifi: Convert printks to pr_<level>

Use the current logging styles.
Add pr_fmt where appropriate.
Remove now unnecessary prefixes from printks.
Convert hard coded prefix to __func__.
Add a missing "\n" to a format.

Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
1d15b5f2d380186761d49588de27b2a6538afacb 20-Jul-2011 Andy Shevchenko <andriy.shevchenko@linux.intel.com> wireless: rtlwifi: throw away MAC_FMT and use %pM instead

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
e10542c447abf7c840931ff12f7d0dee976ca2ea 20-Jun-2011 Mike McCormack <mikem@ring3k.org> rtlwifi: rtl8192{c,ce,cu,se}: Remove comparisons of booleans with true

These are a potential source of confusion, as most C code treats all
non-zero values as true.

Signed-off-by: Mike McCormack <mikem@ring3k.org>
Acked-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
19086fcef1de1fa7350d8122910a506481acf94b 23-May-2011 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Fix warnings from gcc 4.6.0

gcc 4.6.0 warnings for rtlwifi:

CC [M] drivers/net/wireless/rtlwifi/base.o
drivers/net/wireless/rtlwifi/base.c: In function ‘rtl_tx_agg_stop’:
drivers/net/wireless/rtlwifi/base.c:891:23: warning: variable ‘tid_data’ set but not used [-Wunused-but-set-variable]
drivers/net/wireless/rtlwifi/base.c: In function ‘rtl_tx_agg_oper’:
drivers/net/wireless/rtlwifi/base.c:921:23: warning: variable ‘tid_data’ set but not used [-Wunused-but-set-variable]
CC [M] drivers/net/wireless/rtlwifi/efuse.o
drivers/net/wireless/rtlwifi/efuse.c: In function ‘efuse_pg_packet_write’:
drivers/net/wireless/rtlwifi/efuse.c:928:24: warning: variable ‘dataempty’ set but not used [-Wunused-but-set-variable]
drivers/net/wireless/rtlwifi/efuse.c: In function ‘efuse_get_current_size’:
drivers/net/wireless/rtlwifi/efuse.c:1179:5: warning: variable ‘hoffset’ set but not used [-Wunused-but-set-variable]
CC [M] drivers/net/wireless/rtlwifi/ps.o
drivers/net/wireless/rtlwifi/ps.c: In function ‘rtl_ps_set_rf_state’:
drivers/net/wireless/rtlwifi/ps.c:85:19: warning: variable ‘rtstate’ set but not used [-Wunused-but-set-variable]
CC [M] drivers/net/wireless/rtlwifi/regd.o
drivers/net/wireless/rtlwifi/regd.c: In function ‘_rtl_dump_channel_map’:
drivers/net/wireless/rtlwifi/regd.c:310:28: warning: variable ‘ch’ set but not used [-Wunused-but-set-variable]
CC [M] drivers/net/wireless/rtlwifi/usb.o
drivers/net/wireless/rtlwifi/usb.c: In function ‘_rtl_usb_transmit’:
drivers/net/wireless/rtlwifi/usb.c:826:21: warning: variable ‘urb_list’ set but not used [-Wunused-but-set-variable]
drivers/net/wireless/rtlwifi/usb.c:825:23: warning: variable ‘skb_list’ set but not used [-Wunused-but-set-variable]

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
d3bb1429a2c1470d1f84646c00e34dc6784ee06e 25-Apr-2011 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: rtl8192ce: rtl8192cu: Fix most sparse warnings

Fix most sparse warnings in rtlwifi, rtl8192ce and rtl8192cu drivers.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
0baa0fd76f3f5a134461d6cf30294f6bb1bb824c 25-Apr-2011 Chaoming_Li <chaoming_li@realsil.com.cn> rtlwifi: Convert core routines for addition of rtl8192se and rtl8192de

Convert core routines for addition of RTL8192SE and RTL8192DE code.

Additional files are changed to allow compilation.

Signed-off-by: Chaoming_Li <chaoming_li@realsil.com.cn>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
acd48572c396364bb480175d7de83944eefa2563 25-Apr-2011 Chaoming_Li <chaoming_li@realsil.com.cn> rtlwifi: Change base routines for addition of rtl8192se and rtl8192de

Change base routines for addition of RTL8192SE and RTL8192DE code.

Additional files are modified to allow compilation.

Signed-off-by: Chaoming_Li <chaoming_li@realsil.com.cn>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
228bdfca9a09c1263c24509b4bc23a67be168e1a 11-Apr-2011 Chaoming Li <chaoming_li@realsil.com.cn> rtlwifi: rtl8192ce: Fix LED initialization

Driver rtl8192ce does not initialize the LED correctly.

Signed-off-by: Chaoming Li <chaoming_li@realsil.com.cn>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
324732848c42bf79988479ee1b4359e15f08154b 27-Mar-2011 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Remove unused/unneeded variables

Remove some unused variables and correct spelling errors.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
25985edcedea6396277003854657b5f3cb31a628 31-Mar-2011 Lucas De Marchi <lucas.demarchi@profusion.mobi> Fix common misspellings

Fixes generated by 'codespell' and manually reviewed.

Signed-off-by: Lucas De Marchi <lucas.demarchi@profusion.mobi>
375ff4c7780e88bc4e0de4145099a7ed9aa57995 28-Feb-2011 Chaoming Li <chaoming_li@realsil.com.cn> rtlwifi: Fix error registering rate-control

When a second module such as rtl8192ce or rtl8192cu links to rtlwifi, the attempt
to register a rate-control mechanism fails with the warning shown below. The fix is to
select the RC mechanism when rtlwifi is initialized.

WARNING: at net/mac80211/rate.c:42 ieee80211_rate_control_register+0xc9/0x100 [mac80211]()
Hardware name: HP Pavilion dv2700 Notebook PC
Modules linked in: arc4 ecb rtl8192ce rtl8192cu(+) rtl8192c_common rtlwifi snd_hda_codec_conexant amd74xx(+) ide_core sg mac80211 snd_hda_intel snd_hda_codec i2c_nforce2 snd_pcm snd_timer cfg80211 snd k8temp hwmon serio_raw joydev i2c_core soundcore snd_page_alloc rfkill forcedeth video ac battery button ext3 jbd mbcache sd_mod ohci_hcd ahci libahci libata scsi_mod ehci_hcd usbcore fan processor thermal
Pid: 2227, comm: modprobe Not tainted 2.6.38-rc6-wl+ #468
Call Trace:
[<ffffffff8104a3da>] ? warn_slowpath_common+0x7a/0xb0
[<ffffffff8104a425>] ? warn_slowpath_null+0x15/0x20
[<ffffffffa02de409>] ? ieee80211_rate_control_register+0xc9/0x100 [mac80211]
[<ffffffffa03b3790>] ? rtl_rate_control_register+0x10/0x20 [rtlwifi]
[<ffffffffa03ab9c9>] ? rtl_init_core+0x189/0x620 [rtlwifi]
[<ffffffff811cfff8>] ? __raw_spin_lock_init+0x38/0x70
[<ffffffffa03b9dea>] ? rtl_usb_probe+0x709/0x82e [rtlwifi]
[<ffffffffa002a7fd>] ? usb_match_one_id+0x3d/0xc0 [usbcore]
[<ffffffffa002aae9>] ? usb_probe_interface+0xb9/0x160 [usbcore]
[<ffffffff8126ed19>] ? driver_probe_device+0x89/0x1a0
[<ffffffff8126eed3>] ? __driver_attach+0xa3/0xb0
[<ffffffff8126ee30>] ? __driver_attach+0x0/0xb0
[<ffffffff8126dd4e>] ? bus_for_each_dev+0x5e/0x90
[<ffffffff8126e9d9>] ? driver_attach+0x19/0x20
[<ffffffff8126e5e8>] ? bus_add_driver+0x158/0x290
[<ffffffff8126f151>] ? driver_register+0x71/0x140
[<ffffffff811cfff8>] ? __raw_spin_lock_init+0x38/0x70
[<ffffffffa002a2cc>] ? usb_register_driver+0xdc/0x190 [usbcore]
[<ffffffffa0013000>] ? rtl8192cu_init+0x0/0x20 [rtl8192cu]
[<ffffffffa001301e>] ? rtl8192cu_init+0x1e/0x20 [rtl8192cu]
[<ffffffff810002cf>] ? do_one_initcall+0x3f/0x180
[<ffffffff8108fd4b>] ? sys_init_module+0xbb/0x200
[<ffffffff81002c7b>] ? system_call_fastpath+0x16/0x1b
---[ end trace 726271c07a47439e ]---
rtlwifi:rtl_init_core():<0-0> rtl: Unable to register rtl_rc,use default RC !!
ieee80211 phy0: Selected rate control algorithm 'minstrel_ht'

Signed-off-by: Chaoming Li <chaoming_li@realsil.com.cn>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
17c9ac62812b58aacefc7336215aecbb522f6547 19-Feb-2011 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: rtl8192ce: Fix endian warnings

Drivers rtlwifi, and rtl8192ce generate a large number of
sparse warnings. This patch fixes most of them.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
7ea4724036ed17ec811cb8082af7760f04484ef7 19-Feb-2011 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Modify some rtl8192ce routines for merging rtl8192cu

Modify some rtl8192ce routines for merging with rtl8192cu. In addition,
remove some usage of Hungarian notation.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
e6d8a817d00793eecd063b1548bbc954ab62b124 22-Dec-2010 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: rtl8192ce: Fix driver problem when radio switch off at module load

If the radio enable switch is off when the driver is loaded, it is not
possible to get radio output until the driver is unloaded and reloaded
with the switch on.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
3d986b25b5faa50ba6afd94f60f270b6c3061e5e 16-Dec-2010 John W. Linville <linville@tuxdriver.com> rtlwifi: use alloc_workqueue

create_workqueue is deprecated. The workqueue usage does not seem to
demand any special treatment, so do not set any flags either.

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Tested-by: Larry Finger <Larry.Finger@lwfinger.net>
Acked-by: Tejun Heo <tj@kernel.org>
d704300fa546a613ec3821b908528b20685cb92a 18-Dec-2010 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Fix use of mutex in interrupt code

A previous conversion from semaphoreto mutexes missed the fact that one
of the semaphores was used in interrupt code. Fixed by changing to
a spinlock.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
8a09d6d80c90c02f2f8c89f69c702cab0c8d9b42 16-Dec-2010 Larry Finger <Larry.Finger@lwfinger.net> rtlwifi: Switch locking from semaphores to mutexes

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
0c8173385e549f95cd80c3fff5aab87b4f881d8d 08-Dec-2010 Larry Finger <Larry.Finger@lwfinger.net> rtl8192ce: Add new driver

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>