Commit Graph

546555 Commits

Author SHA1 Message Date
Raphaël Beamonte b31c101350 staging: rtl8192u: r8192U_core: remove forward declarations in .c file
Checkpatch was giving a "externs should be avoided in .c files" because
of these forward declarations. As these were not useful in this case,
they have been removed.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:34 -07:00
Raphaël Beamonte cf47ca0225 staging: rtl8192u: r8192U_core: fix unecessary braces code style issue
braces {} are not necessary for any arm of a statement containing
one statement on each side.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:34 -07:00
Raphaël Beamonte 4c21f566c7 staging: rtl8192u: r8192U_core: remove return statement of void function
void function return statement was not useful in this case.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:34 -07:00
Raphaël Beamonte 8f94967a4b staging: rtl8192u: r8192U_core: include linux/uaccess.h instead of asm/uaccess.h
Use #include <linux/uaccess.h> instead of <asm/uaccess.h>

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:33 -07:00
Raphaël Beamonte 14285c1f97 staging: rtl8192u: r8192U_core: clean C99 // comments
Replace C99 // comments by /* comments */ to follow the
kernel code style. Remove some unuseful comments.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:33 -07:00
Raphaël Beamonte 74a0266c07 staging: rtl8192u: r8192U_core: whitespace neatening to fix consistent spacing code style errors
Clean-up the file by using a cleaner spacing around symbols and
words. Mostly use the automatic checkpatch whitespacing fixes.
This takes care of the consistent spacing errors reported by
checkpatch.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:33 -07:00
Raphaël Beamonte b54cc8d8e8 staging: rtl8192u: r8192U_core: fix missing struct leading to consistent spacing code style error
A missing struct keyword in variable declaration triggered a
need consistent spacing around '*' code style error. The struct
keyword thus has been added everywhere for the rtl8192_rx_info
struct, and therefore its typedef removed as not needed anymore.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:33 -07:00
Raphaël Beamonte 70cdcac563 staging: rtl8192u: r8192U_core: fix else following close brace code style error
Fix "else should follow close brace" checkpatch error.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:33 -07:00
Raphaël Beamonte c745f26770 staging: rtl8192u: r8192U_core: fix code indent using spaces code style error
Fix "code indent should use tabs where possible" checkpatch error

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:33 -07:00
Raphaël Beamonte 28071d3400 staging: rtl8192u: r8192U_core: fix space before close parenthesis code style error
A space existed before the close parenthesis of an if statement. This patch
removes it to follow the kernel code style.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:32 -07:00
Raphaël Beamonte a7be027984 staging: rtl8192u: r8192U_core: fix switch and case indent code style error
Some switch and case were not be at the same indent level.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:32 -07:00
Ronit Halder 1865e4ea0b Staging: most: Use NULL instead of zero
This patch fixes the warning generated by sparse
"Using plain integer as NULL pointer" by using NULL
instead of zero.

Signed-off-by: Ronit halder <ronit.crj@gmail.com>
Acked-by: Christian Gromm <christian.gromm@microchip.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:32 -07:00
Sudip Mukherjee 858e1a27c1 staging: most: NULL comparison style
checkpatch complains when a variable comparison to NULL is written as:
variable == NULL or variable != NULL.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:32 -07:00
Sudip Mukherjee a9c2520818 staging: most: fix Makefile
The Makefile is including "drivers/media/video". But there is no such
directory in kernel tree. Since it is aim-v4l2 this might have been
"drivers/media/v4l2-core", but the Kconfig already mentions that it
depends on VIDEO_V4L2. So no need to mention that again in the Makefile.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:32 -07:00
Sudip Mukherjee 9153b5b128 staging: most: remove unused variable
The variable conf was only assigned the value but was never used.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:31 -07:00
Sudip Mukherjee 96d3064b46 staging: most: use NULL pointer
sparse was complaining that an integer is used as NULL pointer. Fix it
by using NULL.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:31 -07:00
Sudip Mukherjee 809da8a5f1 staging: most: make functions static
split_arg_list() and audio_set_pcm_format() are being called from the
same file and is not referenced from outside, so make them as static.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:31 -07:00
Sudip Mukherjee 11f7edb598 staging: most: remove unused functions
These functions were only defined but not used anywhere.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:31 -07:00
Sudip Mukherjee c704dfbe45 staging: most: out of memory error
If kzalloc fails it will print lots of debugging information in the log,
no need to have another in the code.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:31 -07:00
Sudip Mukherjee ba857e0ff0 staging: most: remove multiple blank line
Multiple blank lines are not recommended in the kernel coding style.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:30 -07:00
Sudip Mukherjee 51d6859f23 staging: most: bool comparison style
Mentioning true or false in the if comparison is error prone and also
not according to the coding style.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:30 -07:00
Alexander Kuleshov 0c74210509 staging/rtl8723au: Use %pM format specifier to print mac address
printk() supports %pM format specifier for printing 6-byte MAC/FDDI
addresses in hex notation small buffers, let's use it intead of %x:%x...

Signed-off-by: Alexander Kuleshov <kuleshovmail@gmail.com>
Acked-by: Jes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:30 -07:00
Alexander Kuleshov fec85e0afa staging/rtl8188eu: Use %pM format specifier to print mac address
printk() supports %pM format specifier for printing 6-byte MAC/FDDI
addresses in hex notation small buffers, let's use it intead of %x:%x...

Signed-off-by: Alexander Kuleshov <kuleshovmail@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:30 -07:00
Hari Prasath Gujulan Elango 3a79a7f713 staging: wilc1000: simplify 'memset' of 2D array
This patch simplifies the 'memset' done on a static 2D array.

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:30 -07:00
Johnny Kim e5d57e917a staging: wilc1000: change address to fixed value
The linux_wlan_init_test_config() is called once when net driver is loaded.
And because the pointer type of the pstrWFIDrv is changed with the interger
type, this patch replaces it with designated value instead of pointer.

Signed-off-by: Johnny Kim <johnny.kim@atmel.com>
Signed-off-by: Tony Cho <tony.cho@atmel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:30 -07:00
Johnny Kim 53a8440188 staging: wilc1000: add an argument for Handle_SetWfiDrvHandler
Similar to functions of same layer, this patch add an argument for
Handle_SetWfiDrvHandler function. As a result, the redundant typecasting is
removed.

Signed-off-by: Johnny Kim <johnny.kim@atmel.com>
Signed-off-by: Tony Cho <tony.cho@atmel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:30 -07:00
Johnny Kim 8a625cade3 staging: wilc1000: use the real data type
This patch changes the type of gu8FlushedJoinReqDrvHandler with his real
data type becasue typecasting is not necessary. In result, typecasting
which is not necessary and some building warnings is removed.

Signed-off-by: Johnny Kim <johnny.kim@atmel.com>
Signed-off-by: Tony Cho <tony.cho@atmel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:30 -07:00
Chaehyun Lim 1b128f632d staging: wilc1000: rename WILC_MsgQueueDestroy to wilc_mq_destroy
This patch replaces WILC_MsgQueueDestroy to wilc_mq_destroy to
shorten function name and avoid CamelCase.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:29 -07:00
Chaehyun Lim b986e33e1e staging: wilc1000: rename WILC_MsgQueueRecv to wilc_mq_recv
This patch replaces WILC_MsgQueueRecv with wilc_mq_recv
to shorten function name and avoid CamelCase.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:29 -07:00
Chaehyun Lim 79198138a8 staging: wilc1000: rename WILC_MsgQueueSend to wilc_mq_send
This patch replaces WILC_MsgQueueSend with wilc_mq_send to
shorten function name and avoid CamelCase.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:29 -07:00
Chaehyun Lim cd08fc7813 staging: wilc1000: rename WILC_MsgQueueCreate to wilc_mq_create
This patch replaces WILC_MsgQueueCreate with wilc_mq_create to
shorten function name and avoid CamelCase.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:29 -07:00
Chaehyun Lim bd56018a87 staging: wilc1000: replace WILC_ErrNo by int type
This patch replaces WILC_ErrNo with int type.
WILC_ErrNo typedef is also removed.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:29 -07:00
Chaehyun Lim bb9c2e7a9d staging: wilc1000: wilc_msgqueue.c: fix bool comparison style
This patch changes bool comparison style found by checkpatch.pl
CHECK: Using comparison to true is error prone

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:29 -07:00
Chaehyun Lim ce118546d4 staging: wilc1000: wilc_msgqueue.c: remove kfree NULL check
This patch removes kfree NULL check.
WARNING: kfree(NULL) is safe and this check is probably not required.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:29 -07:00
Chaehyun Lim ae177a2afc staging: wilc1000: wilc_msgqueue.c: use ! operator instead of NULL comparison
This patch uses ! operator instead of NULL comparison.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:29 -07:00
Chaehyun Lim 96cab4cdc6 staging: wilc1000: wilc_msgqueue.c: remove unnecessary parentheses
This patch remove unnecessary parentheses found by checkpatch.pl
CHECK: Unnecessary parentheses around pHandle->hSem

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:28 -07:00
Chaehyun Lim b6583f7415 staging: wilc1000: wilc_msgqueue.c: remove blank line before a close brace
This patch removes blank line before a close brace "}"
CHECK: Blank lines aren't necessary before a close brace '}'

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:28 -07:00
Chaehyun Lim df1890a674 staging: wilc1000: wilc_msgqueue.c: remove multiple blank lines
This patch removes multiple blank lines.
CHECK: Please don't use multiple blank lines

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:28 -07:00
Chaehyun Lim 32728da029 staging: wilc1000: wilc_msgqueue.c: remove blank line after open brace
This patch removes a blank line for open brace "{"
CHECK: Blank lines aren't necessary after an open brace '{'

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:28 -07:00
Chaehyun Lim 6fffc6213d staging: wilc1000: wilc_msgqueue.c: remove braces for single statement
This patch removes braces for single statement blocks.
WARNING: braces {} are not necessary for single statement blocks

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:28 -07:00
Chaehyun Lim 8dfaafd639 staging: wilc1000: add a blank line after declaration
This patch adds a blank line after declaration found by checkpatch.pl
WARNING: Missing a blank line after declarations.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:28 -07:00
Raphaël Beamonte 297a1c34da staging: wilc1000: replace MALLOC_WILC_BUFFER() macro to avoid possible memory leak
The MALLOC_WILC_BUFFER() macro was using a return statement, and didn't
take care of possible memory leaks and subsequent bugs when it was failing
after succeeding some allocations. This patch corrects this behavior.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:28 -07:00
Raphaël Beamonte 7a669e5861 staging: wilc1000: remove FREE_WILC_BUFFER()
It was just a wrapper around kfree(), so call that instead.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:28 -07:00
Trung Thanh Le b8797affa1 staging: android: fix coding style checks in sw_sync.c
replace comparison "obj" to NULL with "!obj"

Signed-off-by: Trung Thanh Le <trungthanh1608@yahoo.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:27 -07:00
Peng Sun 7048c1fc37 staging: android: ashmem.c: 'Alignment' style issue
fix two CHECK issues by checkpatch.pl with --strict:
	Alignment should match open parenthesis

Signed-off-by: Peng Sun <sironhide0null@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:27 -07:00
Peng Sun b8d3bfa780 staging: android: ashmem.c: 'No space necessary after' style issue
fix two CHECK issues by checkpatch.pl with --strict:
	No space is necessary after a cast

Signed-off-by: Peng Sun <sironhide0null@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:27 -07:00
Peng Sun d2e4f687c4 staging: android: ashmem.c: 'spaces preferred around that -' style issue
fix a CHECK style issue by checkpatch.pl with --strict:
	spaces preferred around that '-'

Signed-off-by: Peng Sun <sironhide0null@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:27 -07:00
Malcolm Priestley 9cb693f6f3 staging: vt6655: replace typedef struct tagSRxDesc
with struct vnt_rx_desc and all members the same.

volatile is removed from pointers as this generates warning
message.

Only the first four members of vnt_rx_desc need to be volatile.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:26 -07:00
Malcolm Priestley 88defe2b35 staging: vt6655: replace typedef struct tagDEVICE_RD_INFO
with struct vnt_rd_info

volatile is removed because it will generate a warning
(in any case this member is not) and renaming rd_info.

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:26 -07:00
Malcolm Priestley 9fc7091cc2 staging: vt6655: replace typedef struct tagRDES1
with struct vnt_rdes1 and members
wReqCount -> req_count
wReserved -> reserved

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-09-12 18:24:26 -07:00