summaryrefslogtreecommitdiffstats
path: root/drivers/staging/rtl8192u/r8192U_wx.c
Commit message (Collapse)AuthorAgeFilesLines
* staging: rtl8192u: Fix indentationFu Yong Quah2017-02-091-3/+3
| | | | | | | | Fix number of indentaions for block scopes as suggested by Documentation/CodingStyle. Signed-off-by: Fu Yong Quah <quah.fy95@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* rtl8192u: r8192_priv: Replace semaphore wx_sem with mutexBinoy Jayan2016-06-181-40/+40
| | | | | | | | The semaphore 'wx_sem' in r8192_priv is a simple mutex, so it should be written as one. Semaphores are going away in the future. Signed-off-by: Binoy Jayan <binoy.jayan@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: remove extra blank lines.Ben Marsh2016-03-281-22/+0
| | | | | | | | This patch removes blank lines in r8192U_wx.c that were flagged by checkpatch.pl Signed-off-by: Ben Marsh <bmarsh94@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8192u: Fix block comments use * on subsequent lines in r8192U_wx.cByeoungwook Kim2016-02-071-18/+20
| | | | | | | | clean up checkpatch warning: WARNING: Block comments use * on subsequent lines Signed-off-by: Byeoungwook Kim <quddnr145@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8192u: r8192U_wx: fix negative noise and level valuesLuis de Bethencourt2015-10-121-2/+2
| | | | | | | | | | range->max_qual.noise and level are of type uint8, so they shouldn't be assigned a negative number. Assigning them 0x100 - 98, and 0x100 - 78 which are the equivalent to -98 dBm and -78 dBm, respectively, when IW_QUAL_DBM is set. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: Simplify if conditionKsenija Stanojevic2015-03-161-1/+1
| | | | | | | | This patch removes macro true from if condition since variable priv->ieee80211->LinkDetectInfo.bBusyTraffic is already of type bool. Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: Replace printk() with netdev_dbg()Ksenija Stanojevic2015-03-011-1/+1
| | | | | | | | | For dynamic debugging netdev_dbg (if there is a ponterto a device net structure) is preferred over printk(), which is the raw way to print something. Issue found by checkpatch.pl. Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8192u: Remove unnecessary ifTapasweni Pathak2014-10-271-6/+0
| | | | | | | | Remove the if condition, as the code inside the if condition is commented and does not have any FIXME or TODO comment. Signed-off-by: Tapasweni Pathak <tapaswenipathak@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8192u: Add blank line after variable declarationsGeorgiana Chelu2014-09-281-0/+2
| | | | | | | | Fix the following checkpatch.pl warning: WARNING: Missing a blank line after declarations Signed-off-by: Georgiana Chelu <georgiana.chelu93@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* drivers/staging/rtl8192u/r8192U_wx.c: fix warnings issued by sparseOvidiu Toader2014-08-161-1/+2
| | | | | | | | | | | This minor patch motivated by eudyptula challenge fixes the following warnings issued by `sparse' in drivers/staging/rtl8192u/r8192U_wx.c: .../r8192U_wx.c:27:5: warning: symbol 'rtl8180_rates' was not declared. Should it be static? .../r8192U_wx.c:961:22: warning: symbol 'r8192_get_wireless_stats' was not declared. Should it be static? .../r8192U_wx.c:990:24: warning: symbol 'r8192_wx_handlers_def' was not declared. Should it be static? Signed-off-by: Ovidiu Toader <ovi@phas.ubc.ca> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: r8192U_wx.c Fixed a code-style error about trailing ↵Chaitanya Hazarey2014-06-261-1/+1
| | | | | | | | | | | whitespace Fixed the following error reported by running checkpatch.pl ERROR: trailing whitespace Signed-off-by: Chaitanya Hazarey <c@24.io> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: r8192U_wx.c Fixed some more code-style warnings about spacesChaitanya Hazarey2014-06-261-2/+2
| | | | | | | | | Fixed the following warnings issued by checkpatch.pl WARNING: please, no space before tabs Signed-off-by: Chaitanya Hazarey <c@24.io> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: r8192U_wx.c Fixed code-style warningsChaitanya Hazarey2014-06-261-1/+12
| | | | | | | | | Fixed some of the following warning generated by checkpatch.pl: WARNING: Missing a blank line after declarations Signed-off-by: Chaitanya Hazarey <c@24.io> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: r8192U_wx.c Removed some more commented out dead codeChaitanya Hazarey2014-06-191-17/+1
| | | | | | | Removed dead code from the file. Signed-off-by: Chaitanya Hazarey <c@24.io> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: r8192U_wx.c Added a single space for code-style issueChaitanya Hazarey2014-06-191-1/+1
| | | | | | | | | Added a space around '|' to address: ERROR: need consistent spacing around '|' (ctx:VxW) Signed-off-by: Chaitanya Hazarey <c@24.io> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: r8192U_wx.c Removed all C99 commentsChaitanya Hazarey2014-06-191-65/+65
| | | | | | | | | | | To address the error - ERROR: do not use C99 // comments Removed all C99 comments. Signed-off-by: Chaitanya Hazarey <c@24.io> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: r8192U_wx.c removed commented dead codeChaitanya Hazarey2014-06-191-10/+0
| | | | | | | Removed dead code, commented out printks and DMESG. Signed-off-by: Chaitanya Hazarey <c@24.io> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: r8192U_wx.c Fixed a misplaced braceChaitanya Hazarey2014-05-291-1/+2
| | | | | | | Fixed a misplaced brace in a function Signed-off-by: Chaitanya Hazarey <c@24.io> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: r8192U_wx.c Added {} braces and newlinesChaitanya Hazarey2014-05-281-38/+46
| | | | | | | | | | | | | Added {} braces and newlines to address the following: ERROR: else should follow close brace '}' ERROR: space required before the open brace '{' ERROR: trailing statements should be on next line ERROR: space required before the open parenthesis '(' ERROR: that open brace { should be on the previous line Signed-off-by: Chaitanya Hazarey <c@24.io> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: r8192U_wx.c Added missing spacesChaitanya Hazarey2014-05-281-73/+73
| | | | | | | | | | | | | | | | | | | | | | | | | Added spaces needed in the proper places to address: WARNING: please, no spaces at the start of a line WARNING: missing space after struct definition ERROR: spaces required around that '!=' (ctx:WxV) ERROR: spaces required around that '=' (ctx:WxV) ERROR: spaces required around that '=' (ctx:VxW) ERROR: spaces required around that '&&' (ctx:VxV) ERROR: spaces required around that '!=' (ctx:VxV) ERROR: spaces required around that '=' (ctx:VxV) ERROR: spaces required around that '==' (ctx:VxV) ERROR: spaces required around that '<' (ctx:VxV) ERROR: space required before the open parenthesis '(' ERROR: space required before the open brace '{' ERROR: space required after that ',' (ctx:VxV) ERROR: space required after that close brace '}' ERROR: space prohibited before that '--' (ctx:WxO) ERROR: space prohibited before that close parenthesis ')' ERROR: space prohibited after that open parenthesis '(' Signed-off-by: Chaitanya Hazarey <c@24.io> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: Convert __FUNCTION__ to __func__Joe Perches2014-05-251-6/+6
| | | | | | | Use the normal mechanism for emitting a function name. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: Remove old WIRELESS_EXT supportJoel Pelaez Jorge2014-05-241-19/+1
| | | | | | | | Remove support for building against ancient WIRELESS_EXT versions, only leaving support for the current version: 22 Signed-off-by: Joel Pelaez Jorge <joelpelaez@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8192u: fix checkpatch braces warningRui Miguel Silva2014-05-031-2/+1
| | | | | | | fix some code style related to the use of braces in a one statement block Signed-off-by: Rui Miguel Silva <rmfrfs@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8192u: remove #ifdef JOHN_Xenia Ragiadakou2013-10-111-199/+1
| | | | | | | | | This patch removes the guards #ifdef JOHN_HWSEC, #ifdef JOHN_DUMP_TXDESC and because the code inside them calls some undefined functions (e.g read_rtl8225, rtl8187_read_phy etc). Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: Update e-mail address for Andrea MerelloAndrea Merello2013-08-271-1/+1
| | | | | | | | | A lot of files contain reference to my old e-mail address. Now I'm going not to read mail from it anymore, so update it with my current address everywhere. Signed-off-by: Andrea Merello <andrea.merello@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8192u: fix read_nic_* functionsXenia Ragiadakou2013-06-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | read_nic_*() functions are defined in r8192U_core.c. They call internally usb_control_msg() to read the nic registers and return the value read. Following a remark made by Dan Carpenter, if usb_control_msg() fails, the value returned will be invalid. To accommodate for this, this patch changes the functions to take a pointer as argument to set the value read and return 0 on success and the error status on failure, so that callers of read_nic_*() can check the return status. Some other fixes introduced in read_nic_*() functions are: The expressions (1<<EPROM_*_SHIFT) used to address and set the individual bits of the eeprom register were replaced with EPROM_*_BIT bitmasks to make the code more intuitive. EPROM_*_BIT bitmasks were defined in r8192U_hw.h and EPROM_*_SHIFT were removed. In netdev_err(), which is called in case of failure, the hardcoded function name in the error log message was replaced with __func__ to reduce line size. Also, from the error log message, it was omitted the word "Timeout" and it is just reported the error code since the failure can not only be due to timeout expiration but also due to a memory allocation failure. In case of timeout expiration, usb_start_wait_urb() prints an appropriate log message when debug is enabled. Finally, some minor fixes to the coding style were applied in lines affected by the above changes, including the removal of ifdef DEBUG_RX (the debugging of reads and writes of the nic registers shall be done with explicit check on their return status which will be added in a follow on patch). Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* STAGING: rtl8192u: fix checkpatch error by adding space after switchXenia Ragiadakou2013-05-131-1/+1
| | | | | | | | This patch fixes the following checkpatch error: ERROR: space required before the open parenthesis '(' Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* STAGING: rtl8192u: fix checkpatch error about pointer position in r8192U_wx.cXenia Ragiadakou2013-05-131-16/+16
| | | | | | | | This patch fixes the pointer position in r8192U_wx.c to meet the kernel coding style conventions. Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging/rtl8192u: use same indent for switch and caseSebastian Hahn2013-01-071-6/+6
| | | | | | | Fix the checkpatch error "switch and case should be at the same indent" Signed-off-by: Sebastian Hahn <snsehahn@cip.cs.fau.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging/rtl8192u: put { on same line as structJennifer Naumann2013-01-071-2/+1
| | | | | | | | This fixes the checkpatch error "open brace '{' following struct go on the same line" in staging/rtl8192u Signed-off-by: Jennifer Naumann <Jennifer.Naumann@informatik.stud.uni-erlangen.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging/rtl8192u: cleanfile runSebastian Hahn2013-01-071-11/+11
| | | | | | | | Run cleanfile on all files inside drivers/staging/rtl819u Signed-off-by: Sebastian Hahn <snsehahn@cip.cs.fau.de> Signed-off-by: Jennifer Naumann <Jennifer.Naumann@informatik.stud.uni-erlangen.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8192u Fix a typo.Justin P. Mattock2012-05-011-1/+1
| | | | | Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8192u Fix typos.Justin P. Mattock2012-04-301-4/+4
| | | | | | Signed-off-by: Justin P. Mattock <justinmattock@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: replace open-coded ARRAY_SIZEsJim Cromie2012-04-101-2/+2
| | | | | | | spatch http://coccinelle.lip6.fr/rules/array.cocci did these. Signed-off-by: Jim Cromie <jim.cromie@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8192u: remove dead code to disable dot11dDavid Chosrova2010-12-011-6/+0
| | | | | | | | | | | | | | | | | | | This patch removes all the ENABLE_DOT11D ifdefs. It is always defined for driver. DOT11D has to do with regulatory domains. What prompted this patch was a warning message in Sparse. drivers/staging/rtl8192u/r8192U_core.c:247:1: warning: "eqMacAddr" redefined in file included from drivers/staging/rtl8192u/:81:81: drivers/staging/rtl8192u/dot11d.h:35:1: warning: this is the location of the previous definition Now there are no ifdefs around dot11d.h it made no sense to have this second definition, so I removed that macro as well. ( Thanks Dan ;-) ). Acked-by. Dan Carpenter <error27@gmail.com> Signed-off-by: David Chosrova <dada2372@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* Staging: rtl8192u: remove dead codeMauro Carvalho Chehab2009-12-111-82/+0
| | | | | | | | | | Remove #ifse against older kernel versions; Remove codes marked with #if 0; Remove #if 1 Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* Staging: rtl8192u: remove bad whitespacesMauro Carvalho Chehab2009-12-111-160/+160
| | | | | | Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* Staging: Added Realtek rtl8192u driver to stagingJerry Chuang2009-12-111-0/+1310
Add Realtek linux driver for rtl8192u as provided by Realtek rtl8192u_linux_2.6.0006.1031.2008.tar.gz, send to me C/C staging ML. This version won't compile against upstream, doesn't follow Linux CodingStyle and has their own ieee80211 stack. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
OpenPOWER on IntegriCloud