Commit Graph

535511 Commits

Author SHA1 Message Date
Yash Shah cc6c16df80 Staging: sm750fb: Fix "foo* bar" should be "foo *bar" errors
Fix "foo* bar" should be "foo *bar" errors as detected by
checkpatch.pl

Signed-off-by: Yash Shah <yshah1@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 19:20:42 -07:00
Sudip Mukherjee f1126b1d0d staging: rtl8188eu: fix possible NULL dereference
dm_odm was being checked for NULL after dereferencing it. Lets check for
NULL first before derefenrencing it.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 19:20:39 -07:00
Johnny Kim 2b05df556e staging: wilc1000: clarify the argument type
This patch replaces the void pointer type in the host interface
functions which process the message from host thread by the real data
type, tstrWILC_WFIDrv because the void pointer type as the arguments
is not clear and concise. In addition, typecasting to the void pointer
type is removed becasue it is not necessary.

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-08-14 19:02:52 -07:00
Johnny Kim 11f58c88dd staging: wilc1000: change void pointer type to real type
This patch changes the void pointer member of the tstrHostIFmsg to the
real data type because the void pointer type is ambiguous and not
readable.

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-08-14 19:02:01 -07:00
Johnny Kim 218dc407d4 staging: wilc1000: replace WILC_WFIDrvHandle by tstrWILC_WFIDrv
The structure, WILC_WFIDrvHandle is used to save the pointer address
for the driver handler which is used throughout the driver but it's
not easy to understand what it means. In addition, it doesn't support
the 64 bit machine and also causes the warnings for the 64 bit build.

This patch replaces the WILC_WFIDrvHandle by the tstrWILC_WFIDrv
because the tstrWILC_WFIDrv is real structure to represent the driver
handler and reduces the 64 bit compile warnings. Also, typecasting to
WILC_WFIDrvHandle is not needed by using tstrWILC_WFIDrv as is.

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-08-14 19:00:49 -07:00
Chaehyun Lim 598f85bfae staging: wilc1000: remove WILC_FREE
Remove WILC_FREE that is replaced by kfree.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:59:47 -07:00
Chaehyun Lim 49188af272 staging: wilc1000: use kfree instead of WILC_FREE
Use kfree instead of WILC_FREE.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:59:47 -07:00
Chaehyun Lim 9b45891aef staging: wilc1000: remove unused memory functions
This patch remove unused memory functions because some macros with this
memory function are deleted.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:59:10 -07:00
Chaehyun Lim 96ac283d64 staging: wilc1000: wilc_memory.h: remove unused define
Remove unused define macro that is never used.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:59:09 -07:00
Raphaël Beamonte 5a447f4c73 Staging: gdm72xx: usb_ids: fix a macro coding style error
Fix a macro with complex value coding style error.

Signed-off-by: Raphaël Beamonte <raphael.beamonte@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:56:55 -07:00
Mateusz Kulikowski 435009bba4 staging: rtl8192e: Fix log spamming in rtl8192_hard_data_xmit
This patch fixes issue generated by commit ca93dcba3a
("staging: rtl8192e: Remove assert() macro")

One negation was missed in conversion, therefore
asserted message was always printed.
For 1MB file downloaded via http, ~500 messages
were generated.

Signed-off-by: Mateusz Kulikowski <mateusz.kulikowski@gmail.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:56:55 -07:00
Junsu Shin bda9e24909 staging: vme: devices: add spaces around '-'
This is a patch to the vme_pio2_core.c that adds spaces around '-'.

Signed-off-by: Junsu Shin <jjunes0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:56:54 -07:00
Junsu Shin a8f401f9e7 staging: vme: devices: fix NULL comparison style
This is a patch to vme_pio2_core.c that fixes up the NULL comparison style.

Signed-off-by: Junsu Shin <jjunes0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:56:54 -07:00
Junsu Shin 6c37e74457 staging: vme: devices: remove blank line after open brace
This is a patch to the vme_pio2_core.c that removes blank line after open brace '{'.

Signed-off-by: Junsu Shin <jjunes0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:56:54 -07:00
Junsu Shin d5f0a90e60 staging: vme: devices: remove multiple blank lines
This is a patch to vm2_pio2_core.c that removes multiple blanks lines.

Signed-off-by: Junsu Shin <jjunes0@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:56:54 -07:00
Michał Kępień cf7281c9ae staging: unisys: make visorbus_dev_groups static
visorbus_dev_groups is not referenced outside visorbus_main.c, so it can
be declared static.

Found using sparse.

Signed-off-by: Michał Kępień <kernel@kempniu.pl>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:56:54 -07:00
Prarit Bhargava 110a66be3a drivers: staging: unisys: add MODULE_DEVICE_TABLE and temporary MODULE_ALIAS lines to visornic
This patch adds an module alias and a MODULE_DEVICE_TABLE to autoload the
visornic driver when an appropriate device is created by the visorbus.

Note, the correct way of fixing this is adding functionality to
scripts/mod/file2alias.c for the visorbus bus type.

Signed-off-by: Prarit Bhargava <prarit@redhat.com>
Signed-off-by: Benjamin Romer <benjamin.romer@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:56:54 -07:00
Joe Perches beb1216708 staging: rtl8192u: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Miscellanea:

o Reflow alignments

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:57 -07:00
Joe Perches ec9a0ffa49 staging: mt29f_spinand: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:57 -07:00
Joe Perches 35bb99bf65 staging: dgnc: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:57 -07:00
Joe Perches fd8c5cb5ac staging: ft1000: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Miscellanea:

o Reflow alignment

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:57 -07:00
Joe Perches b3ff291009 staging: wilc1000: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Miscellanea:

o Reflow alignments

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:56 -07:00
Joe Perches ee233d3e19 staging: rtl8192e: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Miscellanea:

o Reflow alignments

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:56 -07:00
Joe Perches ebea63f663 staging: rtl8188eu: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:56 -07:00
Joe Perches ddc9bceb4c staging: nvec: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Miscellanea:

o Reflow alignments

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:56 -07:00
Joe Perches cd951ddc2d staging: fbtft: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Miscellanea:

o Reflow alignments

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:56 -07:00
Joe Perches b239904d8f staging: octeon: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Signed-off-by: Joe Perches <joe@perches.com>
Acked-by: David Daney <david.daney@cavium.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:56 -07:00
Joe Perches a5ee4695ec staging: rtl8712: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:56 -07:00
Joe Perches e075de6109 staging: xgifb: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Miscellanea:

o Reflow alignments

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:56 -07:00
Ioan-Adrian Ratiu f157d807b9 staging: lustre: ptlrpc: add missing include directive
Without including ptlrpc_internal.h, GCC gives prototype warnings
"pack_generic.c:642:5: warning: no previous prototype for ..."
and sparse also complains "pack_generic.c:642:5: warning: symbol
'lustre_unpack_req_ptlrpc_body' was not declared. ..."

Signed-off-by: Ioan-Adrian Ratiu <adi@adirat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:51:18 -07:00
Swee Hua Law 94a99b4611 staging: lustre: Do not init global to NULL
Remove "= NULL" in global variable

Signed-off-by: Swee Hua Law <sweehua81@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:48:34 -07:00
Joe Perches 8150a97fdd staging: lustre: Remove unnecessary externs
Using 'extern' is not necessary for function prototypes.

Miscellanea:

o Reflow alignments

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:48:34 -07:00
Swee Hua Law 049fbd9fcc staging: lustre: checkpatch: argument alignment for readability
Fix checkpatch problem: move last argument of the hlist..() back to same line

Signed-off-by: Swee Hua Law <sweehua81@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:47:41 -07:00
Swee Hua Law aa62a8415e staging: lustre: checkpatch: move */ block comment to next line
Fix checkpatch problem: move */ from end of line to new line

Signed-off-by: Swee Hua Law <sweehua81@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:47:41 -07:00
Swee Hua Law bcffa060c1 staging: lustre: checkpatch: symbol == NULL should be !symbol
Fix checkpatch problem: change == NULL comparison to !symbol

Signed-off-by: Swee Hua Law <sweehua81@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:47:41 -07:00
Swee Hua Law 1b680a8181 staging: lustre: checkpatch: do not init global to NULL
Fix checkpatch problem: remove NULL assignment fro global variable

Signed-off-by: Swee Hua Law <sweehua81@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:47:41 -07:00
Patrick Boettcher a836582655 staging: lustre-libcfs: make static-variable constant
This static can be made constant as it is never modified.

Found during sparse-cleanup.

Signed-off-by: Patrick Boettcher <patrick.boettcher@posteo.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:46:02 -07:00
Patrick Boettcher 25bbe418f8 staging: lustre-libcfs: fix sparse warning
Fix sparse warnings of the following type:

warning: symbol '....' was not declared. Should it be static?

Signed-off-by: Patrick Boettcher <patrick.boettcher@posteo.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:46:02 -07:00
Shraddha Barke 0df4e3e9bb Staging: unisys: Remove useless cast on void pointer
void pointers do not need to be cast to other pointer types.

The semantic patch used to find this:

@r@
expression x;
void* e;
type T;
identifier f;
@@
(
  *((T *)e)
|
  ((T *)x)[...]
|
  ((T *)x)->f
|
- (T *)
  e
)

Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:44:45 -07:00
Shraddha Barke 94858fecca Staging: lustre: libcfs: Remove unnecessary cast on void*
This patch does away with the cast on void * as it is unnecessary.

Semantic patch used is as follows:

@r@
expression x;
void* e;
type T;
identifier f;
@@
(
  *((T *)e)
|
  ((T *)x)[...]
|
  ((T *)x)->f
|
- (void *)
  e
)

Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:44:45 -07:00
Shraddha Barke 642ac6c0dc Staging: wilc1000: Remove null check before kfree
kfree on NULL pointer is a no-op.

This patch uses the following semantic patch to find such an instance
where NULL check is present before kfree.

// <smpl>
@@ expression E; @@
- if (E != NULL) { kfree(E); }
+ kfree(E);
@@ expression E; @@
- if (E != NULL) { kfree(E); E = NULL; }
+ kfree(E);
+ E = NULL;
// </smpl>smpl>

Signed-off-by: Shraddha Barke <shraddha.6596@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:44:45 -07:00
Jacob Kiefer 772a6e1fff staging: rtl8723au: Fix Sparse errors in rtw_security.c
This patch fixes the following sparse errors:

  CHECK   drivers/staging/rtl8723au/core/rtw_security.c
drivers/staging/rtl8723au/core/rtw_security.c:189:39: \
  warning: incorrect type in assignment (different base types)
drivers/staging/rtl8723au/core/rtw_security.c:189:39:    \
  expected unsigned int [unsigned] [usertype] <noident>
drivers/staging/rtl8723au/core/rtw_security.c:189:39:    \
  got restricted __le32 [usertype] <noident>
drivers/staging/rtl8723au/core/rtw_security.c:197:39: \
  warning: incorrect type in assignment (different base types)
drivers/staging/rtl8723au/core/rtw_security.c:197:39:    \
  expected unsigned int [unsigned] [usertype] <noident>
drivers/staging/rtl8723au/core/rtw_security.c:197:39:    \
  got restricted __le32 [usertype] <noident>
drivers/staging/rtl8723au/core/rtw_security.c:682:39: \
  warning: incorrect type in assignment (different base types)
drivers/staging/rtl8723au/core/rtw_security.c:682:39:    \
  expected unsigned int [unsigned] [usertype] <noident>
drivers/staging/rtl8723au/core/rtw_security.c:682:39:    \
  got restricted __le32 [usertype] <noident>
drivers/staging/rtl8723au/core/rtw_security.c:694:39: \
  warning: incorrect type in assignment (different base types)
drivers/staging/rtl8723au/core/rtw_security.c:694:39:    \
  expected unsigned int [unsigned] [usertype] <noident>
drivers/staging/rtl8723au/core/rtw_security.c:694:39:    \
  got restricted __le32 [usertype] <noident>

Signed-off-by: Jacob Kiefer <jtk54@cornell.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:44:45 -07:00
Chaehyun Lim 071c19e73b staging: wilc1000: remove wilc_strutils.c and wilc_strutils.h
Remove wilc_strutils.c and wilc_strutils.h that are not needed.
wilc_strutils.o is also removed in Makefile.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:42:08 -07:00
Chaehyun Lim 9504f96492 staging: wilc1000: remove WILC_memcpy_INTERNAL
Remove WILC_memcpy_INTERNAL that is used in the WILC_memcpy
because WILC_memcpy is replaced by memcpy.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:42:08 -07:00
Chaehyun Lim f78d5f809e staging: wilc1000: remove WILC_memcpy function
Remove WILC_memcpy function that is changed to memcpy.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:42:08 -07:00
Chaehyun Lim d00d2ba333 staging: wilc1000: use memcpy instead of WILC_memcpy
Use memcpy instead of WILC_memcpy that is a custom function.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:42:08 -07:00
Chaehyun Lim 31126a478f staging: wilc1000: remove WILC_strncmp function
Remove WILC_strncmp function that is changed to strncmp.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:39:52 -07:00
Chaehyun Lim 3f882895c7 staging: wilc1000: use strncmp instead of WILC_strncmp
Use strncmp instead of WILC_strncmp.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:39:52 -07:00
Chaehyun Lim 24e326ea29 staging: wilc1000: remove WILC_strncpy function
Remove WILC_strncpy function that is changed to strncpy.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:39:52 -07:00
Chaehyun Lim 85b509f18a staging: wilc1000: Use strncpy instead of WILC_strncpy
Use strncpy instead of WILC_strncpy that is a custom function

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2015-08-14 18:39:52 -07:00