summaryrefslogtreecommitdiffstats
path: root/drivers/staging/rtl8712/rtl871x_security.c
Commit message (Collapse)AuthorAgeFilesLines
* staging: rtl8712: spaces preferred around operandsLuis de Bethencourt2015-10-241-51/+57
| | | | | | | | | Clean up all instances of checkpatch.pl checks: CHECK: spaces preferred around that '+' (and other operands) Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8712: braces should be used on all armsLuis de Bethencourt2015-10-241-7/+14
| | | | | | | | Fix all instances of the following checkpatch.pl check: CHECK: braces {} should be used on all arms of this statement Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8712: Remove boolean comparisonsLuis de Bethencourt2015-10-241-2/+2
| | | | | | | Boolean tests do not need explicit comparison to true or false. Signed-off-by: Luis de Bethencourt <luisbg@osg.samsung.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8712: rtl871x_security.c: remove unnecessary variable initializationSunil Shahu2015-07-141-1/+1
| | | | | | | | | | Variable "u32 c" always re-initialize in for loop. Initialized value of "u32 c" is not used in function and is redundant, hence removed. Suggested-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Sunil Shahu <shshahu@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* drivers: staging: rtl8712: remove unnecessary else statementSunil Shahu2015-07-141-19/+16
| | | | | | | "else" statement after "if" is unnecessary, hence removed. Signed-off-by: Sunil Shahu <shshahu@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8712: Remove zero-testing pointer typed valueAmitoj Kaur Chawla2015-04-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Removes variable comparison with 0 by using !. Done using following coccinelle script. @ disable is_zero,isnt_zero @ expression *E; expression E1,f; @@ E = f(...) <... ( - E == 0 + !E | - E != 0 + E | - 0 == E + !E | - 0 != E + E ) ...> ?E = E1 @ disable is_zero,isnt_zero @ expression *E; @@ ( E == - 0 + NULL | E != - 0 + NULL | - 0 + NULL == E | - 0 + NULL != E ) Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* drivers: staging: rtl8712: Removed unnecessary parenthesesTina Johnson2015-03-091-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Parentheses around the right side of an assignment statement are unnecessary and hence removed. Coccinelle was used to produce the patch: @rule1@ identifier x,y; constant c; @@ ( x = -( y << c -) ; | x = -( y >> c -) ; | x = -( y + c -) ; | x = -( y - c -) ; ) Signed-off-by: Tina Johnson <tinajohnson.1234@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8712: Eliminate use of _init_timerVaishali Thakkar2015-03-061-2/+2
| | | | | | | | | | | | | | | | | | | | | This patch introduces the use of API function setup_timer instead of driver specific function _init_timer as it is the preferred and standard way to setup and set the timer. To be compatible with the change, argument types of referenced functions are changed. Also, definition of function _init_timer is removed as it is no longer needed after this change. This is done using Coccinelle and semantic patch used for this is as follows: @@ expression x, y; identifier a, b;@@ - _init_timer (&x, y, a, b); + setup_timer (&x, a, (unsigned long)b); Signed-off-by: Vaishali Thakkar <vthakkar1994@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8712: rewrite the right hand side of an assignmentAya Mahfouz2015-02-261-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch rewrites the right hand side of an assignment for expressions of the form: a = (a <op> b); to be: a <op>= b; where <op> = << | >>. This issue was detected and resolved using the following coccinelle script: @@ identifier i; expression e; @@ -i = (i >> e); +i >>= e; @@ identifier i; expression e; @@ -i = (i << e); +i <<= e; Signed-off-by: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8712: remove unused variablesSudip Mukherjee2014-10-291-8/+2
| | | | | | | | | | | | | | | | | | unused variables are removed. These variables were only assigned some values and after that they were never being used. So they are safe to be removed , and it has been build tested. I left a call to r8712_read32(padapter, TCR) and r8712_read8(padapter, SDIO_HCPWM) . r8712_read32() and r8712_read8() is ultimately calling usb_read32() and usb_read8() respectively. and they are again calling r8712_usbctrl_vendorreq(). this r8712_usbctrl_vendorreq() is communicating through the usb bus and is sending and receiving the control msg. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8712: remove void function return; statementTapasweni Pathak2014-09-231-1/+0
| | | | | | | | This patch fixes checkpatch.pl warning in files of rtl8712 WARNING : void function return statement are not generally useful Signed-off-by: Tapasweni Pathak <tapaswenipathak@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8712: fix unnecessary line continuationsMarcus Farkas2014-05-241-1/+1
| | | | | | | | | | This commit fixes the following checkpatch warning: rtl8712/rtl871x_security.c - 1178: WARNING: Avoid unnecessary line continuations Signed-off-by: Marcus Farkas <marcus.farkas@finitebox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8712: fix unnecessary parenthesesMarcus Farkas2014-05-241-2/+2
| | | | | | | | | | | This commit fixes the following checkpatch warnings: rtl8712/rtl871x_security.c - 1167: WARNING: Unnecessary parentheses - maybe == should be = ? - 1374: WARNING: Unnecessary parentheses - maybe == should be = ? Signed-off-by: Marcus Farkas <marcus.farkas@finitebox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8712: fix missing blank lines after declarationsMarcus Farkas2014-05-241-0/+3
| | | | | | | | | | | | This commit fixes the following checkpatch warnings: rtl8712/rtl871x_security.c - 275: WARNING: Missing a blank line after declarations - 768: WARNING: Missing a blank line after declarations - 801: WARNING: Missing a blank line after declarations Signed-off-by: Marcus Farkas <marcus.farkas@finitebox.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8712: fix some confusing indentingDan Carpenter2014-03-061-6/+7
| | | | | | | | | These set off a static checker warning about "warn: add curly braces?", but actually the code it correct, it's just the indenting which is wrong. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: delete non-required instances of include <linux/init.h>Paul Gortmaker2013-12-171-1/+0
| | | | | | | | | | None of these files are actually using any __init type directives and hence don't need to include <linux/init.h>. Most are just a left over from __devinit and __cpuinit removal, or simply due to code getting copied from one driver to the next. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* Staging: rtl8712: fix spaces before semicolonsThomas Cort2013-10-031-3/+3
| | | | | | | | Resolve all of the 'WARNING: space prohibited before semicolon' checkpatch warnings for rtl8712. Signed-off-by: Thomas Cort <linuxgeek@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: rtl8712: fix foo* bar (foo*) errors reported by checkpatchDevendra Naga2012-09-261-4/+4
| | | | | | | | | | | | | | | | fixes the following errors: drivers/staging/rtl8712/rtl871x_security.c:61: ERROR: "foo * bar" should be "foo *bar" drivers/staging/rtl8712/rtl871x_security.c:291: ERROR: "foo * bar" should be "foo *bar" drivers/staging/rtl8712/rtl871x_security.c:323: ERROR: "foo * bar" should be "foo *bar" drivers/staging/rtl8712/rtl871x_security.c:1371: ERROR: "(foo*)" should be "(foo *)" Signed-off-by: Devendra Naga <devendra.aaru@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
* staging: r8712u: Merging Realtek's latest (v2.6.6). Updated include directives.Ali Bahar2011-09-061-0/+15
| | | | | | | | | | | | These are the new include directives for header files. The following were (somehow!) not explicity in Realtek's, but proved necessary: "linux/usb.h" is needed for usb_alloc_urb(); "linux/interrupt.h" is needed for tasklet_struct. It was often a nested include. Signed-off-by: Ali Bahar <ali@internetDog.org> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: r8712u: Add the new driver to the mainline kernelLarry Finger2010-08-201-0/+1389
This code is for a completely new version of the Realtek 8192 USB devices such as the D-Link DWA-130. The Realtek code, which was originally for Linux, Windows XP and Windows CE, has been stripped of all code not needed for Linux. In addition, only one additional configuration variable, which enables AP mode, remains. Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net> Signed-off-by: Florian Schilhabel <florian.c.schilhabel@googlemail.com> Tested-by: Frederic Leroy <fredo@starox.org>