History log of /drivers/staging/rtl8192u/r819xU_cmdpkt.c
Revision Date Author Comments
4764ca981b040048766e4f39a45a4b9c5cecff9c 26-May-2014 Peter Senna Tschudin <peter.senna@gmail.com> drivers/staging: Remove useless return variables

This patch remove variables that are initialized with a constant,
are never updated, and are only used as parameter of return.
Return the constant instead of using a variable.

Verified by compilation only.

The coccinelle script that find and fixes this issue is:
// <smpl>
@@
type T;
constant C;
identifier ret;
@@
- T ret = C;
... when != ret
when strict
return
- ret
+ C
;
// </smpl>

Signed-off-by: Peter Senna Tschudin <peter.senna@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9e93d7adb25b0ce36dc594d83a9de62a70ea049b 19-Mar-2014 Ana Rey <anarey@gmail.com> staging: rtl8192u: make in r819xU_cmdpkt.c some local functions static

Make some local functions static.

Fix sparse warnings in r819xU_cmdpkt.c

drivers/staging/rtl8192u/r819xU_cmdpkt.c:185:6: warning: symbol 'cmdpkt_beacontimerinterrupt_819xusb' was not declared. Should it be static?

Signed-off-by: Ana Rey <anarey@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
a115ee4175c3eb33f75d5ca62d417e853702c0f3 16-Oct-2013 Teodora Baluta <teobaluta@gmail.com> Staging: rtl8192u: fix functions that should not be declared extern

These functions are already marked extern in the header file

drivers/staging/rtl8192u/r819xU_phy.c:1716:13: warning: function 'InitialGainOperateWorkItemCallBack' with external linkage has definition
drivers/staging/rtl8192u/r819xU_cmdpkt.c:497:12: warning: function 'cmpk_message_handle_rx' with external linkage has definition

Signed-off-by: Teodora Baluta <teobaluta@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
c3aed2312fd3c74e77e049b795e092689d414474 20-Sep-2013 Iker Pedrosa <ikerpedrosam@gmail.com> Staging: rtl8192u: r819xU_cmdpkt: checking NULL value after doing dev_alloc_skb

Checking the return of dev_alloc_skb as stated in the following bug: https://bugzilla.kernel.org/show_bug.cgi?id=60411

Signed-off-by: Iker Pedrosa <ikerpedrosam@gmail.com>
Reported-by: RUC_Soft_Sec rucsoftsec@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
f6150b40e9a4426aaa819ca0736f8db8af3c4a75 21-Sep-2013 Xenia Ragiadakou <burzalodowa@gmail.com> staging: rtl8192u: remove cmpk_message_handle_tx()

The function cmpk_message_handle_tx() is called only in r8192U_dm.c in two
places. The first call resides outside an #ifdef RTL8192U guard, and since
RTL8192U is defined this call can be removed. At the other site this function
is called, there is no check on its return value. Since cmpk_message_handle_tx()
does not do anything else other than returning true, it can be safely removed.

Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
f7e9fbc017b7f8e23c35d2f0be0f4842236b5a2c 21-Sep-2013 Xenia Ragiadakou <burzalodowa@gmail.com> staging: rtl8192u: remove unused code from cmpk_message_handle_tx()

The file r819xU_cmdpkt.c includes header r8192U.h which defines RTL8192U.
This patch removes from cmpk_message_handle_tx() the part of the code that
is never used because it resides outside the header guard #ifdef RTL8192U.

Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
bdc7cb1994d5df7f14e42cd61b332e8eb12cac3e 26-Jun-2013 Xenia Ragiadakou <burzalodowa@gmail.com> staging: rtl8192u: remove unused macros r819xU_cmdpkt.c

This patch removes CMPK_DEBOUNCE_CNT and CMPK_PRINT()
because they are not used anywhere in the driver.

Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
f70edb9f1c62e4367068f263bfb596767675477b 26-Jun-2013 Xenia Ragiadakou <burzalodowa@gmail.com> staging: rtl8192u: fix line size and identation in r819xU_cmdpkt.c

This patch limits the line size below 80 characters, when
possible, and fixes identation to meet kernel coding style
convetions.

Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
bdcd57fa210646738c7fd6ecc927fc87065b5bbd 26-Jun-2013 Xenia Ragiadakou <burzalodowa@gmail.com> staging: rtl8192u: remove unnecessary line continuations in r819xU_cmdpkt.c

This patch fixes the following checkpatch warning:
WARNING: Avoid unnecessary line continuations

Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
6df9f669de3da57e661e27e6f55799ae587fb2c9 26-Jun-2013 Xenia Ragiadakou <burzalodowa@gmail.com> staging: rtl8192u: fix comments in r819xU_cmdpkt.c

This patches fixes comments by:
- replacing // comments with /**/ comments
- removing unnecessary comments (trailing comments
with the function name, comments stating date/author
when they are placed inside the function definition)
- fixing internal alignment

Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fa6b108bb17558d721c5adfa48fc309388cd0230 26-Jun-2013 Xenia Ragiadakou <burzalodowa@gmail.com> staging: rtl8192u: fix whitespace in r819xU_cmdpkt.c

This patch fixes whitespaces in r819xU_cmdpkt.c to
follow the kernel coding style and to improve code
readability.

It fixes the spaces around <,=||&&();} and adds or
removes tabs to better align variables.

Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
05cdf47ac3374f91a2ac438be58f216562aa9b72 26-Jun-2013 Xenia Ragiadakou <burzalodowa@gmail.com> staging: rtl8192u: fix braces in r819xU_cmdpkt.c

This patch fixes the brace position according to the
linux kernel coding style and removes unnecessary braces.

Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
f2a04351edea25eb9b380ea183ed223e4f445791 26-Jun-2013 Xenia Ragiadakou <burzalodowa@gmail.com> staging: rtl8192u: remove commented-out code in r819xU_cmdpkt.c

This patch removes commented-out code and the comments
that refer to it to facilitate code review.

Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
c2ac90b9b4c178936396deb67451e3850c0e5204 06-Jun-2013 Dan Carpenter <dan.carpenter@oracle.com> Staging: rtl8192u: fix a reversed test

Sean MacLennan fixed this in the rtl8192e driver and we should fix
it here as well.

It's pretty harmless. This information comes from the firmware, if
we were to hit this bug we would read beyond the end of the array
once or twice before returning and update our statistics with bogus
data.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
a71d7679d747c5e4afa5f25f990af47aaadd8edf 13-May-2013 Xenia Ragiadakou <burzalodowa@gmail.com> rtl8192u: fix whitespace around if statements in r819xU_cmdpkt.c

This patch fixes a part of the following checkpatch error:
ERROR: space required before the open parenthesis '('
by adding space after if

Signed-off-by: Xenia Ragiadakou <burzalodowa@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
ad6384591f449026d93b136a6b5cb8b8bce6c743 12-May-2013 Xenia Ragiadakou <burzalodowa@gmail.com> STAGING: rtl8192u: fix checkpatch error by adding space after switch

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>
9772acad08bc6204936e76b6b8af8f44a0683d94 11-May-2013 Xenia Ragiadakou <burzalodowa@gmail.com> STAGING: rtl8192u: fix checkpatch error about pointer position in r819xU_cmdpkt

This patch fixes the pointer position in r819xU_cmdpkt.h and r819xU_cmdpkt.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>
35997ff0cadda701711416abf6676b77358b0008 05-Dec-2012 Sebastian Hahn <snsehahn@cip.cs.fau.de> staging/rtl8192u: cleanfile run

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>
8ef3a7ed35a09431336faf2f3ce53d4d0959cea1 30-Apr-2012 Justin P. Mattock <justinmattock@gmail.com> staging:rtl8192u Fix typos and comments

Signed-off-by: Justin P. Mattock <justinmattock@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
589b3d06fd159774f9f5c3639d8d5d938670c019 30-Apr-2012 Justin P. Mattock <justinmattock@gmail.com> staging: rtl8192u Fix typos.

Signed-off-by: Justin P. Mattock <justinmattock@gmail.com>

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
f7738eda211091d8caf612b2bc1bac2fb52e48c6 17-Apr-2012 Dan Carpenter <dan.carpenter@oracle.com> Staging: rtl8192u: fix some memory corruption

When we received a command we incremented a stat counter depending on
the type of message. The problem is there were 8 types of commands but
there were only 4 counters allocated so it corrupted memory past the
end of the rxcmdpkt[] array.

The fix is just to remove the counters because they aren't used.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
ACKed-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
8f18604e6f0975fa852f43f90d5556efd67efadc 09-Mar-2010 Julia Lawall <julia@diku.dk> Staging: drop redundant memset

The region set by the call to memset is immediately overwritten by the
subsequent call to memcpy.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@
expression e1,e2,e3,e4;
@@

- memset(e1,e2,e3);
memcpy(e1,e4,e3);
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
50a09b3b099ebc8326b85b4f508fb47655e1fed3 03-Nov-2009 Mauro Carvalho Chehab <mchehab@infradead.org> Staging: rtl8192u: remove dead code

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>
e406322b4b963e622f41d76193d8ca9e5435adb8 03-Nov-2009 Mauro Carvalho Chehab <mchehab@infradead.org> Staging: rtl8192u: remove bad whitespaces

Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
8fc8598e61f6f384f3eaf1d9b09500c12af47b37 03-Nov-2009 Jerry Chuang <jerry-chuang@realtek.com> Staging: Added Realtek rtl8192u driver to staging

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>