summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/rtlwifi
AgeCommit message (Collapse)AuthorFilesLines
2011-04-10treewide: remove extra semicolonsJustin P. Mattock3-4/+4
Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2011-03-11Merge branch 'master' of ↵John W. Linville1-3/+6
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davem
2011-03-04Merge branch 'master' of ↵John W. Linville40-233/+780
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davem
2011-03-04rtlwifi: usb parts should depend on CONFIG_USBJohn W. Linville1-3/+6
ERROR: "usb_unanchor_urb" [drivers/net/wireless/rtlwifi/rtlwifi.ko] undefined! ERROR: "usb_control_msg" [drivers/net/wireless/rtlwifi/rtlwifi.ko] undefined! ERROR: "usb_submit_urb" [drivers/net/wireless/rtlwifi/rtlwifi.ko] undefined! ERROR: "usb_get_dev" [drivers/net/wireless/rtlwifi/rtlwifi.ko] undefined! ERROR: "usb_kill_anchored_urbs" [drivers/net/wireless/rtlwifi/rtlwifi.ko] undefined! ERROR: "usb_put_dev" [drivers/net/wireless/rtlwifi/rtlwifi.ko] undefined! ERROR: "usb_free_urb" [drivers/net/wireless/rtlwifi/rtlwifi.ko] undefined! ERROR: "usb_anchor_urb" [drivers/net/wireless/rtlwifi/rtlwifi.ko] undefined! ERROR: "usb_alloc_urb" [drivers/net/wireless/rtlwifi/rtlwifi.ko] undefined! make[2]: *** [__modpost] Error 1 make[1]: *** [modules] Error 2 make: *** [sub-make] Error 2 The USB-part of rtlwifi should depend on CONFIG_USB. This also corrects the existing check for CONFIG_PCI to build pci.o. Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-03-01rtlwifi: Fix error registering rate-controlChaoming Li1-9/+6
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>
2011-02-28net: use pci_dev->revision, againSergei Shtylyov1-3/+1
Several more network drivers that read the device's revision ID from the PCI configuration register were merged after the commit 44c10138fd4bbc4b6d6bff0873c24902f2a9da65 (PCI: Change all drivers to use pci_device->revision), so it's time to do another pass of conversion to using the 'revision' field of 'struct pci_dev'... Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com> Acked-by: "John W. Linville" <linville@tuxdriver.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2011-02-28rtlwifi: fix places where uninitialized data is usedAlessio Igor Bogani1-3/+3
drivers/net/wireless/rtlwifi/rtl8192ce/trx.c: In function ‘rtl92ce_rx_query_desc’: drivers/net/wireless/rtlwifi/rtl8192ce/trx.c:255:5: warning: ‘rf_rx_num’ may be used uninitialized in this function drivers/net/wireless/rtlwifi/rtl8192ce/trx.c:257:12: warning: ‘total_rssi’ may be used uninitialized in this function drivers/net/wireless/rtlwifi/rtl8192ce/trx.c:466:6: warning: ‘weighting’ may be used uninitialized in this function This work was supported by a hardware donation from the CE Linux Forum. Signed-off-by: Alessio Igor Bogani <abogani@kernel.org> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-28rtlwifi: Add the missing rcu_read_lock/unlockAlessio Igor Bogani3-2/+12
=================================================== [ INFO: suspicious rcu_dereference_check() usage. ] --------------------------------------------------- net/mac80211/sta_info.c:125 invoked rcu_dereference_check() without protection! other info that might help us debug this: rcu_scheduler_active = 1, debug_locks = 0 5 locks held by wpa_supplicant/468: #0: (rtnl_mutex){+.+.+.}, at: [<c1465d84>] rtnl_lock+0x14/0x20 #1: (&rdev->mtx){+.+.+.}, at: [<f84b8c2b>] cfg80211_mgd_wext_siwfreq+0x6b/0x170 [cfg80211] #2: (&rdev->devlist_mtx){+.+.+.}, at: [<f84b8c37>] cfg80211_mgd_wext_siwfreq+0x77/0x170 [cfg80211] #3: (&wdev->mtx){+.+.+.}, at: [<f84b8c44>] cfg80211_mgd_wext_siwfreq+0x84/0x170 [cfg80211] #4: (&rtlpriv->locks.conf_mutex){+.+.+.}, at: [<f8506476>] rtl_op_bss_info_changed+0x26/0xc10 [rtlwifi] stack backtrace: Pid: 468, comm: wpa_supplicant Not tainted 2.6.38-rc6+ #79 Call Trace: [<c108806a>] ? lockdep_rcu_dereference+0xaa/0xb0 [<f8523d2c>] ? sta_info_get_bss+0x19c/0x1b0 [mac80211] [<f8523d62>] ? ieee80211_find_sta+0x22/0x40 [mac80211] [<f850661c>] ? rtl_op_bss_info_changed+0x1cc/0xc10 [rtlwifi] [<c153671c>] ? __mutex_unlock_slowpath+0x14c/0x160 [<c153673d>] ? mutex_unlock+0xd/0x10 [<f8507180>] ? rtl_op_config+0x120/0x310 [rtlwifi] [<c10896db>] ? trace_hardirqs_on+0xb/0x10 [<f8522169>] ? ieee80211_bss_info_change_notify+0xf9/0x1f0 [mac80211] [<f8506450>] ? rtl_op_bss_info_changed+0x0/0xc10 [rtlwifi] [<f853646f>] ? ieee80211_set_channel+0xbf/0xd0 [mac80211] [<f84b5f41>] ? cfg80211_set_freq+0x121/0x180 [cfg80211] [<f85363b0>] ? ieee80211_set_channel+0x0/0xd0 [mac80211] [<f84b8ceb>] ? cfg80211_mgd_wext_siwfreq+0x12b/0x170 [cfg80211] [<f84b87eb>] ? cfg80211_wext_siwfreq+0x9b/0x100 [cfg80211] [<c153b98b>] ? sub_preempt_count+0x7b/0xb0 [<c150f874>] ? ioctl_standard_call+0x74/0x3b0 [<c1465d84>] ? rtnl_lock+0x14/0x20 [<f84b8750>] ? cfg80211_wext_siwfreq+0x0/0x100 [cfg80211] [<c14568bd>] ? __dev_get_by_name+0x8d/0xb0 [<c150fddb>] ? wext_handle_ioctl+0x16b/0x180 [<f84b8750>] ? cfg80211_wext_siwfreq+0x0/0x100 [cfg80211] [<c145bc7a>] ? dev_ioctl+0x5ba/0x720 [<c108a947>] ? __lock_acquire+0x3e7/0x19b0 [<c1443b0b>] ? sock_ioctl+0x1eb/0x290 [<c108bfa5>] ? lock_release_non_nested+0x95/0x2f0 [<c1443920>] ? sock_ioctl+0x0/0x290 [<c114d74d>] ? do_vfs_ioctl+0x7d/0x5c0 [<c1112232>] ? might_fault+0x62/0xb0 [<c113e3c6>] ? fget_light+0x226/0x390 [<c1112278>] ? might_fault+0xa8/0xb0 [<c114dd17>] ? sys_ioctl+0x87/0x90 [<c1002f9f>] ? sysenter_do_call+0x12/0x38 This work was supported by a hardware donation from the CE Linux Forum. Signed-off-by: Alessio Igor Bogani <abogani@kernel.org> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-25mac80211: make tx() operation return voidJohannes Berg1-3/+2
The return value of the tx operation is commonly misused by drivers, leading to errors. All drivers will drop frames if they fail to TX the frame, and they must also properly manage the queues (if they didn't, mac80211 would already warn). Removing the ability for drivers to return a BUSY value also allows significant cleanups of the TX TX handling code in mac80211. Note that this also fixes a bug in ath9k_htc, the old "return -1" there was wrong. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Tested-by: Sedat Dilek <sedat.dilek@googlemail.com> [ath5k] Acked-by: Gertjan van Wingerde <gwingerde@gmail.com> [rt2x00] Acked-by: Larry Finger <Larry.Finger@lwfinger.net> [b43, rtl8187, rtlwifi] Acked-by: Luciano Coelho <coelho@ti.com> [wl12xx] Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-24rtlwifi: Need to include vmalloc.hDavid S. Miller1-0/+1
Signed-off-by: David S. Miller <davem@davemloft.net>
2011-02-24rtl8192c: fix compilation errorsJohannes Berg2-12/+12
On my G5 this fails to compile with drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c:701: error: __ksymtab__rtl92c_phy_txpwr_idx_to_dbm causes a section type conflict drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c:701: error: __ksymtab__rtl92c_phy_txpwr_idx_to_dbm causes a section type conflict drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c:677: error: __ksymtab__rtl92c_phy_dbm_to_txpwr_Idx causes a section type conflict drivers/net/wireless/rtlwifi/rtl8192c/phy_common.c:677: error: __ksymtab__rtl92c_phy_dbm_to_txpwr_Idx causes a section type conflict since you can't export static functions. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-23rtlwifi: rtl8192ce: rtl8192cu: Fix multiple def errors for allyesconfig buildLarry Finger34-185/+744
As noted by Stephan Rothwell, an allyesconfig build fails since rtl8192cu was merged with failures such as: drivers/net/wireless/rtlwifi/rtl8192cu/built-in.o: In function `rtl92c_phy_sw_chnl': (.opd+0xf30): multiple definition of `rtl92c_phy_sw_chnl' drivers/net/wireless/rtlwifi/rtl8192ce/built-in.o:(.opd+0xb70): first defined here drivers/net/wireless/rtlwifi/rtl8192cu/built-in.o: In function `rtl92c_fill_h2c_cmd': (.opd+0x288): multiple definition of `rtl92c_fill_h2c_cmd' drivers/net/wireless/rtlwifi/rtl8192ce/built-in.o:(.opd+0x288): first defined here These are caused because the code shared between rtl8192ce and rtl8192cu is included in both drivers. This has been fixed by creating a new modue that contains the shared code. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-23rtlwifi: Eliminate udelay calls with too large valuesWilly Tarreau2-21/+0
On ARM, compilation of rtlwifi/efuse.c fails with the message: ERROR: "__bad_udelay" [drivers/net/wireless/rtlwifi/rtlwifi.ko] undefined! On inspection, the faulty calls are in routine efuse_reset_loader(), a routine that is never used, and the faulty routine is deleted. Signed-off-by: Willy Tarreau <w@1wt.eu> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-23rtlwifi: Let rtlwifi build when PCI is not enabledWilly Tarreau1-1/+4
On systems where PCI does not exist, a build of rtlwifi will fail. Apply the same fix in case there are systems with PCI but not USB. Signed-off-by: Willy Tarreau <w@1wt.eu> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-23rtl8192cu: fix build error (vmalloc/vfree undefined)Willy Tarreau1-1/+1
On the ARM system, a build fails due to missing include. Signed-off-by: Willy Tarreau <w@1wt.eu> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-23mac80211: rename RX_FLAG_TSFTJohannes Berg2-2/+2
The flag isn't very descriptive -- the intention is that the driver provides a TSF timestamp at the beginning of the MPDU -- make that clearer by renaming the flag to RX_FLAG_MACTIME_MPDU. Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: Remove obsolete/unused macrosLarry Finger2-102/+33
The original code has many macros that are no longer needed. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: rtl8192ce: Fix endian warningsLarry Finger10-291/+313
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>
2011-02-21rtlwifi: Modify build system for rtl8192cuLarry Finger5-3/+35
Modify Kconfig and Makefile to build rtl8192cu. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: rtl8192cu: Add routine trxGeorge1-0/+684
Add routine rtlwifi/rtl8192cu/trx.c. This routine differs from the rtl8192ce file of the same name. Signed-off-by: George <george0505@realtek.com> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: rtl8192cu: Add routine tableGeorge1-0/+1888
Add rtlwifi/rtl8192cu/table.c. These tables are different than the ones used in rtl8192ce. Signed-off-by: George <george0505@realtek.com> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: rtl8192cu: Add routine rfGeorge1-0/+493
Add rtlwifi/rtl8192cu/rf.c. This routine is distinct from the one in rtl8192ce with the same name. Signed-off-by: George <george0505@realtek.com> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: rtl8192cu: Add routine phyGeorge1-0/+611
Add the routine rtlwifi/rtl8192cu/phy.c. Most of the code is included from rtlwifi/rtl8192c/phy_common.c. Signed-off-by: George <george0505@realtek.com> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: rtl8192cu: Add routine macGeorge1-0/+1144
Add the routine rtlwifi/rtl8192cu/hw.c. Signed-off-by: George <george0505@realtek.com> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: rtl8192cu: Add routine hwGeorge1-0/+2505
Add the routine rtlwifi/rtl8192cu/hw.c. This one is distinct from the routine of the same name in rtl8192ce. Signed-off-by: George <george0505@realtek.com> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: rtl8192cu: Add routines dm, fw, led and swGeorge4-0/+615
Add the rtlwifi/rtl8192cu routines for dm.c, fw.c, led.c and sw.c. Where possible, these routines use the corresponding code in rtl8192ce. Signed-off-by: George <george0505@realtek.com> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: Move common parts of rtl8192ce/phy.cLarry Finger2-2018/+2050
Move common routines from rtlwifi/rtl8192ce/phy.c and .../rtl8192cu/phy.c into rtlwifi/rtl8192c/phy_common.c. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: Modify wifi.h for rtl8192cuLarry Finger2-50/+239
Further merge of parameters needed for rtl8192cu. In addition, some changes needed for rtl8192se and rtl8192de are included and additional Hungarian notation is removed. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: Add headers for rtl8187cuGeorge13-4/+1212
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: George <george0505@realtek.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: Modify some rtl8192ce routines for merging rtl8192cuLarry Finger15-321/+321
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>
2011-02-21rtlwifi: Make changes in rtlwifi/rtl8192ce/def.h to support rtl8192cuLarry Finger2-13/+144
This change modifies rtlwifi/rtl8192ce/def.h to handle rtl8192cu. In addition, a couple of routines needed for both drivers are converted to be inline. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-21rtlwifi: Make changes in rtlwifi/rtl8192ce/reg.h to support rtl8192cuLarry Finger2-4/+69
This change modifies rtlwifi/rtl8192ce/reg.h to support rtl8192cu. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-11rtlwifi: rtl8192ce: Rework rtl8192ce/phy.cLarry Finger1-64/+35
Make the phy.c codes for rtl8192ce and rtl8192cu be as alike as possible. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-11rtlwifi: rtl8192ce: Refactor rtl8192ce/fwLarry Finger5-42/+45
Make rtlwifi/rtl8192ce/fw.{h,c} match what will be needed for rtlwifi/rtl8192cu.{h,c}. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-11rtlwifi: rtl8192ce: Refactor rtl8192ce/dmLarry Finger4-1358/+1392
To reuse as much code as possible when adding additional drivers to the rtlwifi tree, the common parts of various routines are moved to drivers/net/wireless/rtlwifi. This patch does that for the version of dm.{h,c} used by rtl8192ce. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-11rtlwifi: Add usb driverGeorge3-1/+1201
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: George <george0505@realtek.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-02-11rtlwifi: Modify core routinesLarry Finger5-88/+56
The rtlwifi core needs some changes before inclusion of a driver for the RTL8192CU USB device. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: <chaoming_li@realsil.com.cn> Signed-off-by: <george0505@realtek.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-01-28Merge branch 'master' of ↵John W. Linville2-22/+29
git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6 Conflicts: drivers/net/wireless/ath/ath9k/init.c
2011-01-27rtlwifi: Fix firmware upload errorsChaoming Li1-20/+20
When the source code from Realtek was prepared for kernel inclusion, some routines were refactored to reduce the level of indentation. This patch repairs errors introduced in that process. 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>
2011-01-21rtlwifi: Fix possible NULL dereferenceJesper Juhl1-2/+9
In drivers/net/wireless/rtlwifi/pci.c::_rtl_pci_rx_interrupt() we call dev_alloc_skb(), which may fail and return NULL, but we do not check the returned value against NULL before dereferencing the returned pointer. This may lead to a NULL pointer dereference which means we'll crash - not good. In a separate call to dev_alloc_skb(), the debug level is changed so that the failure message will always be logged. Signed-off-by: Jesper Juhl <jj@chaosbits.net> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2011-01-19mac80211: track receiver's aggregation reorder buffer sizeJohannes Berg1-1/+2
The aggregation code currently doesn't implement the buffer size negotiation. It will always request a max buffer size (which is fine, if a little pointless, as the mac80211 code doesn't know and might just use 0 instead), but if the peer requests a smaller size it isn't possible to honour this request. In order to fix this, look at the buffer size in the addBA response frame, keep track of it and pass it to the driver in the ampdu_action callback when called with the IEEE80211_AMPDU_TX_OPERATIONAL action. That way the driver can limit the number of subframes in aggregates appropriately. Note that this doesn't fix any drivers apart from the addition of the new argument -- they all need to be updated separately to use this variable! Signed-off-by: Johannes Berg <johannes.berg@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-12-22rtlwifi: Fix large packet issueChaoming Li1-3/+15
An RX buffer is set to 9100 bytes to receive 8K AMSDU; however, an skb of this size fails in the kernel. 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>
2010-12-22rtlwifi: rtl8192ce: Fix driver problem when radio switch off at module loadLarry Finger2-18/+5
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>
2010-12-22rtlwifi: Use pci_pcie_cap()Hauke Mehrtens1-1/+1
Use function pci_pcie_cap() instead of accessing struct member directly. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> Tested-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-12-20rtlwifi: use alloc_workqueueJohn W. Linville1-1/+1
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>
2010-12-20rtlwifi: Fix use of mutex in interrupt codeLarry Finger3-5/+6
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>
2010-12-20rtl8192ce: Fix typo in Kconfig descriptionAnisse Astier1-1/+1
Signed-off-by: Anisse Astier <anisse@astier.eu> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-12-20rtl8192ce: drop 'rtl8192c-' prefix from filesJohn W. Linville21-52/+52
Signed-off-by: John W. Linville <linville@tuxdriver.com> Tested-by: Larry Finger <Larry.Finger@lwfinger.net>
2010-12-16rtlwifi: Switch locking from semaphores to mutexesLarry Finger4-22/+22
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>
2010-12-16rtl8192ce: Fix build on powerpcLarry Finger1-0/+2
After merge of the rtl8192ce driver, a powerpc build fails with: drivers/net/wireless/rtlwifi/rtl8192ce/rtl8192c-sw.c: In function 'rtl92c_init_sw_vars': drivers/net/wireless/rtlwifi/rtl8192ce/rtl8192c-sw.c:76: error: implicit declaration of function 'vmalloc' drivers/net/wireless/rtlwifi/rtl8192ce/rtl8192c-sw.c:76: warning: cast to pointer from integer of different size drivers/net/wireless/rtlwifi/rtl8192ce/rtl8192c-sw.c: In function 'rtl92c_deinit_sw_vars': drivers/net/wireless/rtlwifi/rtl8192ce/rtl8192c-sw.c:91: error: implicit declaration of function 'vfree' The problem is fixed by explicitly including the appropriate header. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: John W. Linville <linville@tuxdriver.com>