GitHub/exynos8895/android_kernel_samsung_universal8895.git
9 years agoStaging: comedi: s626: Simplify a trivial if-return sequence
Abdul Hussain [Mon, 22 Jun 2015 06:11:13 +0000 (06:11 +0000)]
Staging: comedi: s626: Simplify a trivial if-return sequence

This patch simplify a trivial if-return sequence. Possibly combine with
a preceding function call.

Signed-off-by: Abdul Hussain <habdul@visteon.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoStaging: comedi: ni_daq_dio24: Simplify a trivial if-return sequence
Abdul Hussain [Mon, 22 Jun 2015 06:11:09 +0000 (06:11 +0000)]
Staging: comedi: ni_daq_dio24: Simplify a trivial if-return sequence

This patch simplify a trivial if-return sequence. Possibly combine with
a preceding function call.

Signed-off-by: Abdul Hussain <habdul@visteon.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoStaging: comedi: dac02: Simplify a trivial if-return sequence
Abdul Hussain [Mon, 22 Jun 2015 06:11:06 +0000 (06:11 +0000)]
Staging: comedi: dac02: Simplify a trivial if-return sequence

This patch simplify a trivial if-return sequence. Possibly combine with
a preceding function call.

Signed-off-by: Abdul Hussain <habdul@visteon.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoStaging: comedi: fl512: Simplify a trivial if-return sequence
Abdul Hussain [Mon, 22 Jun 2015 06:10:59 +0000 (06:10 +0000)]
Staging: comedi: fl512: Simplify a trivial if-return sequence

This patch simplify a trivial if-return sequence. Possibly combine with
a preceding function call.

Signed-off-by: Abdul Hussain <habdul@visteon.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoStaging: comedi: dmm32at: Simplify a trivial if-return sequence
Abdul Hussain [Mon, 22 Jun 2015 06:10:56 +0000 (06:10 +0000)]
Staging: comedi: dmm32at: Simplify a trivial if-return sequence

This patch simplify a trivial if-return sequence. Possibly combine with
a preceding function call.

Signed-off-by: Abdul Hussain <habdul@visteon.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: comedi: das08_cs: don't split Author string
Luis de Bethencourt [Mon, 22 Jun 2015 12:14:35 +0000 (14:14 +0200)]
staging: comedi: das08_cs: don't split Author string

fixes checkpatch.pl WARNING: quoted string split across lines

+MODULE_AUTHOR("David A. Schleef <ds@schleef.org>, "
+             "Frank Mori Hess <fmhess@users.sourceforge.net>");

Modules with multiple authors have a MODULE_AUTHOR line for each one.

Signed-off-by: Luis de Bethencourt <luis@debethencourt.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: android: ion_chunk_heap.c: Fixed line over 80 characters
Guillermo O. Freschi [Sun, 21 Jun 2015 08:28:55 +0000 (05:28 -0300)]
staging: android: ion_chunk_heap.c: Fixed line over 80 characters

Simple style fix.

Signed-off-by: Guillermo O. Freschi <kedrot@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: android: ion: reorder variable definitions
Dmitry Kalinkin [Mon, 13 Jul 2015 12:50:30 +0000 (15:50 +0300)]
staging: android: ion: reorder variable definitions

Prevents false positive "missing empty line after a definition"
checkpatch warning.

Signed-off-by: Dmitry Kalinkin <dmitry.kalinkin@gmail.com>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: Deletion of unnecessary checks before three function calls
Markus Elfring [Tue, 14 Jul 2015 07:35:42 +0000 (09:35 +0200)]
staging: lustre: Deletion of unnecessary checks before three function calls

The following functions test whether their argument is NULL and then
return immediately.
* kfree
* ll_file_data_put
* ptlrpc_connection_put

Thus the test around such calls is not needed.

This issue was detected by using the Coccinelle software.

See also a previous update suggestion:
"remove unneeded null test before free" by Julia Lawall
https://lkml.org/lkml/2015/5/1/498
https://www.mail-archive.com/linux-kernel@vger.kernel.org/msg878600.html

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: fix whitespace coding style issues in libcfs/module.c
Lukasz Janyst [Tue, 14 Jul 2015 15:22:21 +0000 (17:22 +0200)]
staging: lustre: fix whitespace coding style issues in libcfs/module.c

This is a patch to the libcfs/module.c file fixing whitespace warnings
found by checkpatch.pl.

Signed-off-by: Lukasz Janyst <lj@buggybrain.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/libcfs: Fix kstrtouint return value check fix
Oleg Drokin [Tue, 14 Jul 2015 03:17:57 +0000 (23:17 -0400)]
staging/lustre/libcfs: Fix kstrtouint return value check fix

Apparently kstrtouint could return not just -EINVAL, but also -ERANGE,
so make sure we just check the return value for something negative.

Noticed by Dan Carpenter <dan.carpenter@oracle.com>

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/libcfs: remove unused portal_enter_debugger variable
Dmitry Eremin [Tue, 14 Jul 2015 03:17:56 +0000 (23:17 -0400)]
staging/lustre/libcfs: remove unused portal_enter_debugger variable

Remove portal_enter_debugger because it's not used any more.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/libcfs: get rid of debugfs/lnet/console_{min, max}_delay_centisecs
Dmitry Eremin [Tue, 14 Jul 2015 03:17:55 +0000 (23:17 -0400)]
staging/lustre/libcfs: get rid of debugfs/lnet/console_{min, max}_delay_centisecs

They are just fancy module parameters wrappers,
so just the same functionality now would be accessible via
/sys/module/libcfs/parameters/libcfs_console_{min,max}_delay

Also install compatibility symlinks

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/libcfs: get rid of debugfs/lnet/debug_mb
Oleg Drokin [Tue, 14 Jul 2015 03:17:54 +0000 (23:17 -0400)]
staging/lustre/libcfs: get rid of debugfs/lnet/debug_mb

It's just a fancy libcfs_debug_mb module parameter wrapper,
so just add debug buffer size check and resizing and the same
functionality now would be accessible via
/sys/module/libcfs/parameters/libcfs_debug_mb

Also add a symlink for backwards compatibility.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: libcfs: move assignment out of conditional
Perry Hooker [Mon, 13 Jul 2015 23:33:47 +0000 (17:33 -0600)]
staging: lustre: libcfs: move assignment out of conditional

Found by checkpatch.pl

Signed-off-by: Perry Hooker <perry.hooker@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoStaging: lustre: fixed a blank line after declarations coding style issue
Ronit Halder [Fri, 10 Jul 2015 17:35:39 +0000 (23:05 +0530)]
Staging: lustre: fixed a blank line after declarations coding style issue

Fixed a blank line after declarations coding style issue

Signed-off-by: Ronit Halder <ronit.crj@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoStaging: lustre: lustre: obdclass: genops: fixed brace coding style issues
Kris Baumann [Thu, 9 Jul 2015 20:12:48 +0000 (22:12 +0200)]
Staging: lustre: lustre: obdclass: genops: fixed brace coding style issues

Fixed several brace coding style issues.

Signed-off-by: Kris Baumann <krisbaumann@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging:lustre: fix "space required after that ', '" error in cl_page.c
Anders Fridlund [Thu, 9 Jul 2015 09:02:09 +0000 (11:02 +0200)]
staging:lustre: fix "space required after that ', '" error in cl_page.c

This is a patch to the cl_page.c file that fixes a
"space required after that ','" error found by the checkpatch.pl tool.

Signed-off-by: Anders Fridlund <anders.fridlund@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: make ptlrpc_init static
Matt Mooney [Wed, 8 Jul 2015 16:21:11 +0000 (09:21 -0700)]
staging: lustre: make ptlrpc_init static

fix sparse warning in lustre/ptlrpc/ptlrpc_module.c:54:12:
     warning: symbol 'ptlrpc_init' was not declared. Should it be static?

The __init macro is moved before the function name to match standard usage.

Signed-off-by: Matt Mooney <mfm@muteddisk.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: remove dead code
Hari Prasath Gujulan Elango [Wed, 8 Jul 2015 13:34:36 +0000 (13:34 +0000)]
staging: lustre: remove dead code

This patch removes commented code.

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/libcfs: Remove unneeded lnet watchdog_ratelimit sysctl
Dmitry Eremin [Mon, 6 Jul 2015 16:48:55 +0000 (12:48 -0400)]
staging/lustre/libcfs: Remove unneeded lnet watchdog_ratelimit sysctl

It is no longer used anywhere.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/libcfs: Remove redundant enums and sysctl moduleparams
Dmitry Eremin [Mon, 6 Jul 2015 16:48:54 +0000 (12:48 -0400)]
staging/lustre/libcfs: Remove redundant enums and sysctl moduleparams

/proc/sys/lnet/lnet_memused
Remove memory tracking for LNet.
Remove redundant enums definition.

Signed-off-by: Dmitry Eremin <dmitry.eremin@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/libcfs: get rid of debugfs/lnet/console_backoff
Oleg Drokin [Mon, 6 Jul 2015 16:48:53 +0000 (12:48 -0400)]
staging/lustre/libcfs: get rid of debugfs/lnet/console_backoff

module parameter libcfs_console_backoff accessible through
/sys/module/libcfs/parameters/libcfs_console_backoff would
do the same thing, just add a special "uintpos" parameter
type to disallow 0 values too.
Also add a symlink to the module parameter variable for
backwards compatibility

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/libcfs: Remove redundant lnet debugfs variables
Oleg Drokin [Mon, 6 Jul 2015 16:48:52 +0000 (12:48 -0400)]
staging/lustre/libcfs: Remove redundant lnet debugfs variables

/proc/sys/lnet/console_ratelimit, debug_path and panic_on_lbug
are module parameters with no special magic accessible via
/sys/module/libcfs/parameters/libcfs_console_ratelimit,
/sys/module/libcfs/parameters/libcfs_debug_file_path and
/sys/module/libcfs/parameters/libcfs_panic_on_lbug respectively.

As such just replace them with corresponding symlinks

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/libcfs: move /proc/sys/lnet to debugfs
Oleg Drokin [Mon, 6 Jul 2015 16:48:51 +0000 (12:48 -0400)]
staging/lustre/libcfs: move /proc/sys/lnet to debugfs

Parameters in lnet sysctl are of debug quantity, so let's move them
to debugfs instead.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre: Get rid of remaining /proc/sys/lustre plumbing
Oleg Drokin [Mon, 6 Jul 2015 16:48:50 +0000 (12:48 -0400)]
staging/lustre: Get rid of remaining /proc/sys/lustre plumbing

Since all of the variables from /proc/sys/lustre were moved to
/sys/fs/lustre, get rid of the remaining infrastructure.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/obdclass: Move AT controls from sysctl to sysfs
Oleg Drokin [Mon, 6 Jul 2015 16:48:49 +0000 (12:48 -0400)]
staging/lustre/obdclass: Move AT controls from sysctl to sysfs

Adaptive Timeouts controls are being moved from /proc/sys/lustre
to /sys/fs/lustre

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/obdclass: move debug controls to sysfs
Oleg Drokin [Mon, 6 Jul 2015 16:48:48 +0000 (12:48 -0400)]
staging/lustre/obdclass: move debug controls to sysfs

debug_peer_on_timeout, dump_on_timeout and dump_on_eviction
controls from /proc/sys/lustre to /sys/fs/lustre

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/obdclass: move max_dirty_mb from sysctl to sysfs
Oleg Drokin [Mon, 6 Jul 2015 16:48:47 +0000 (12:48 -0400)]
staging/lustre/obdclass: move max_dirty_mb from sysctl to sysfs

max_dirty_mb is now a parameter in /sys/fs/lustre/

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/obdclass: move sysctl timeout to sysfs
Oleg Drokin [Mon, 6 Jul 2015 16:48:46 +0000 (12:48 -0400)]
staging/lustre/obdclass: move sysctl timeout to sysfs

This is the first step of moving lustre sysctls from
/proc/sys/lustre to /sys/fs/lustre

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre: Remove unneeded ldlm_timeout control
Oleg Drokin [Mon, 6 Jul 2015 16:48:45 +0000 (12:48 -0400)]
staging/lustre: Remove unneeded ldlm_timeout control

ldlm_timeout is used server-side to determine AST timeouts,
so it makes no sense on the client, esp. since it's not really used
anywhere.
Remove all traces of it except from the config where make
it a noop.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre: Remove now obsolete memory tracking sysctls
Oleg Drokin [Mon, 6 Jul 2015 16:48:44 +0000 (12:48 -0400)]
staging/lustre: Remove now obsolete memory tracking sysctls

In the past when Lustre did its own allocation amounts tracking
the results were shown in sysctl as current and overall max
number of bytes and pages allocated. Now that we don't
track these, remove the sysctls.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre: remove alloc_fail_rate sysctl
Oleg Drokin [Mon, 6 Jul 2015 16:48:43 +0000 (12:48 -0400)]
staging/lustre: remove alloc_fail_rate sysctl

It was used to control allocation failure rate, but there is
in-kernel way of doing that that's more versatile too.

This is going to remove just the sysctl, the underlying variable
will be removed once all OBD_ALLOC* macros removal patchseries land.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/obdclass: fix class_procfs_init error return value
Oleg Drokin [Mon, 6 Jul 2015 16:48:42 +0000 (12:48 -0400)]
staging/lustre/obdclass: fix class_procfs_init error return value

Dan Carpenter noticed that procfs conversion patches introduced
a bug where should kobject_create_and_add, an error is not returned
from class_procfs_init.

Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/ldlm: In ldlm_pools_fini make sure there was init first.
Oleg Drokin [Mon, 6 Jul 2015 16:48:41 +0000 (12:48 -0400)]
staging/lustre/ldlm: In ldlm_pools_fini make sure there was init first.

It turns out if you call ldlm_pools_fini without completing the
ldlm_pools_init, then attempt to unregister not yet registered
shrinkers makes the kernel very unhappy.
So make sure we have them registered first.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre: make ldebugfs_remove recursive
Oleg Drokin [Mon, 6 Jul 2015 16:48:40 +0000 (12:48 -0400)]
staging/lustre: make ldebugfs_remove recursive

ldebugfs_remove is usually called on directories with files passed in
as attributes, so simple debugfs_remove failes on them as not empty
Switch to debugfs_remove_recursive.

This fixes a number of problems where a new filesystem is mounted after
being unmounted first.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/lov: Move target sysfs symlink removal to LOV freeing
Oleg Drokin [Wed, 24 Jun 2015 14:09:24 +0000 (10:09 -0400)]
staging/lustre/lov: Move target sysfs symlink removal to LOV freeing

This helps to avoid use after free on unmount.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging/lustre/lnet: Move asm/irq.h include after linux includes
Oleg Drokin [Wed, 24 Jun 2015 14:07:45 +0000 (10:07 -0400)]
staging/lustre/lnet: Move asm/irq.h include after linux includes

Apparently m86k cannot build if you include asm/irq.h before
linux/* includes and fixing it there is hard.
So just move asm/irq.h include to where it does not cause any problems.

Thanks to Geert Uytterhoeven for getting to the root of it.

Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Compile-Tested-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: libcfs: drop trivially useless initialization
Julia Lawall [Sat, 20 Jun 2015 19:07:49 +0000 (21:07 +0200)]
staging: lustre: libcfs: drop trivially useless initialization

Remove initialization of a variable that is immediately reassigned.

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

// <smpl>
@@
type T;
identifier x;
constant C;
expression e;
@@

T x
- = C
 ;
x = e;
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: obdclass: llog: drop trivially useless initialization
Julia Lawall [Sat, 20 Jun 2015 19:07:52 +0000 (21:07 +0200)]
staging: lustre: obdclass: llog: drop trivially useless initialization

Remove initialization of a variable that is immediately reassigned.

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

// <smpl>
@@
type T;
identifier x;
constant C;
expression e;
@@

T x
- = C
 ;
x = e;
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: lmv: drop trivially useless initialization
Julia Lawall [Sat, 20 Jun 2015 19:07:51 +0000 (21:07 +0200)]
staging: lustre: lmv: drop trivially useless initialization

Remove initialization of a variable that is immediately reassigned.

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

// <smpl>
@@
type T;
identifier x;
constant C;
expression e;
@@

T x
- = C
 ;
x = e;
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: osc: drop trivially useless initialization
Julia Lawall [Sat, 20 Jun 2015 19:07:53 +0000 (21:07 +0200)]
staging: lustre: osc: drop trivially useless initialization

Remove initialization of a variable that is immediately reassigned.

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

// <smpl>
@@
type T;
identifier x;
constant C;
expression e;
@@

T x
- = C
 ;
x = e;
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: llite: drop trivially useless initialization
Julia Lawall [Sat, 20 Jun 2015 19:07:50 +0000 (21:07 +0200)]
staging: lustre: llite: drop trivially useless initialization

Remove initialization of a variable that is immediately reassigned.

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

// <smpl>
@@
type T;
identifier x;
constant C;
expression e;
@@

T x
- = C
 ;
x = e;
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: ptlrpc: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:59:10 +0000 (18:59 +0200)]
staging: lustre: ptlrpc: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: osc: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:59:09 +0000 (18:59 +0200)]
staging: lustre: osc: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: obdecho: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:59:08 +0000 (18:59 +0200)]
staging: lustre: obdecho: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: obdclass: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:59:07 +0000 (18:59 +0200)]
staging: lustre: obdclass: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: mgc: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:59:06 +0000 (18:59 +0200)]
staging: lustre: mgc: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: mdc: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:59:05 +0000 (18:59 +0200)]
staging: lustre: mdc: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: lov: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:59:04 +0000 (18:59 +0200)]
staging: lustre: lov: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: lmv: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:59:03 +0000 (18:59 +0200)]
staging: lustre: lmv: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: ldlm: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:59:02 +0000 (18:59 +0200)]
staging: lustre: ldlm: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: lclient: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:59:01 +0000 (18:59 +0200)]
staging: lustre: lclient: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: fld: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:59:00 +0000 (18:59 +0200)]
staging: lustre: fld: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: lustre: fid: Use !x to check for kzalloc failure
Julia Lawall [Sat, 20 Jun 2015 16:58:59 +0000 (18:58 +0200)]
staging: lustre: fid: Use !x to check for kzalloc failure

!x is more normal for kzalloc failure in the kernel.

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

// <smpl>
@@
expression x;
statement S1, S2;
@@

x = kzalloc(...);
if (
- x == NULL
+ !x
 ) S1 else S2
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agowilc1000: host_interface.c: global variables do not need to be explicitly initialized...
Daniel Machon [Mon, 6 Jul 2015 17:48:04 +0000 (19:48 +0200)]
wilc1000: host_interface.c: global variables do not need to be explicitly initialized to 0 or NULL.

Fixed explicit initialization of global pointer variable.

GCC takes care of this implicitly.

Signed-off-by: Daniel Machon <dmachon.dev@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging:wilc1000: code cleanup Fix reported by coccinelle
Prasanna Karthik [Mon, 29 Jun 2015 12:43:32 +0000 (12:43 +0000)]
staging:wilc1000: code cleanup Fix reported by coccinelle

Removed {} for single statement if block

Signed-off-by: Prasanna Karthik <mkarthi3@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: switch printks to vsprintf IPv4 extension
Luis de Bethencourt [Fri, 26 Jun 2015 15:40:25 +0000 (17:40 +0200)]
staging: wilc1000: switch printks to vsprintf IPv4 extension

Switch printks with IP addresses to use vsprintf extension %pI4.

Suggested-by: Joe Perches <joe@perches.com>
Signed-off-by: Luis de Bethencourt <luis@debethencourt.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: fix typos in PRINT_ERR()
Luis de Bethencourt [Fri, 26 Jun 2015 14:47:28 +0000 (16:47 +0200)]
staging: wilc1000: fix typos in PRINT_ERR()

Fix typo "packe" to "packet".

Signed-off-by: Luis de Bethencourt <luis@debethencourt.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove whitespaces before quoted newlines
Luis de Bethencourt [Fri, 26 Jun 2015 14:45:58 +0000 (16:45 +0200)]
staging: wilc1000: remove whitespaces before quoted newlines

Fix all checkpatch.pl warnings:
WARNING: unnecessary whitespace before a quoted newline

Signed-off-by: Luis de Bethencourt <luis@debethencourt.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: add blank lines after declarations
Luis de Bethencourt [Fri, 26 Jun 2015 14:45:14 +0000 (16:45 +0200)]
staging: wilc1000: add blank lines after declarations

Fix all checkpatch.pl warnings:
WARNING: Missing a blank line after declarations

Signed-off-by: Luis de Bethencourt <luis@debethencourt.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove unnecessary braces
Luis de Bethencourt [Fri, 26 Jun 2015 14:44:24 +0000 (16:44 +0200)]
staging: wilc1000: remove unnecessary braces

Removing all checkpatch.pl warnings:
WARNING: braces {} are not necessary for single statement blocks

Signed-off-by: Luis de Bethencourt <luis@debethencourt.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove the warnings on the line over 80 characters
Sunghoon Cho [Fri, 26 Jun 2015 06:48:16 +0000 (15:48 +0900)]
staging: wilc1000: remove the warnings on the line over 80 characters

This patch removes the warnings reported by checkpatch.pl on the line
over 80 characters.

Signed-off-by: Sunghoon Cho <ywhsbliss@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: add a blank line after struct declaration
Sunghoon Cho [Fri, 26 Jun 2015 06:48:15 +0000 (15:48 +0900)]
staging: wilc1000: add a blank line after struct declaration

This patch adds a blank line right after a struct declaration.

Signed-off-by: Sunghoon Cho <ywhsbliss@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove the warnings on the prohibited spaces
Sunghoon Cho [Fri, 26 Jun 2015 06:48:14 +0000 (15:48 +0900)]
staging: wilc1000: remove the warnings on the prohibited spaces

This patch removes the warnings reported by checkpatch.pl regarding
prohibited spaces between function name and open parenthesis.

Signed-off-by: Sunghoon Cho <ywhsbliss@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: wilc_wfi_netdevice.c: remove blank lines
Chaehyun Lim [Tue, 23 Jun 2015 00:17:47 +0000 (09:17 +0900)]
staging: wilc1000: wilc_wfi_netdevice.c: remove blank lines

Remove multiple blank lines.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: wilc_wfi_netdevice.c: remove unused variable
Chaehyun Lim [Tue, 23 Jun 2015 00:17:46 +0000 (09:17 +0900)]
staging: wilc1000: wilc_wfi_netdevice.c: remove unused variable

Remove variable that is defined but never used.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: wilc_wfi_netdevice.c: remove unused codes
Chaehyun Lim [Tue, 23 Jun 2015 00:17:45 +0000 (09:17 +0900)]
staging: wilc1000: wilc_wfi_netdevice.c: remove unused codes

Remove if statement that has no any codes.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: wilc_wfi_netdevice.c: remove commented codes
Chaehyun Lim [Tue, 23 Jun 2015 00:17:44 +0000 (09:17 +0900)]
staging: wilc1000: wilc_wfi_netdevice.c: remove commented codes

Remove commented codes.

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: host_interface: add spaces around '='
Sunil Shahu [Mon, 22 Jun 2015 13:53:01 +0000 (19:23 +0530)]
staging: wilc1000: host_interface: add spaces around '='

Fix coding style error by placing spaces around '=' as suggested by
checkpatch.pl script.

Signed-off-by: Sunil Shahu <shshahu@gmail.com>
Reviewed-by: Luis de Bethencourt <luis@debethencourt.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: use BIT macro
Hari Prasath Gujulan Elango [Mon, 22 Jun 2015 07:06:01 +0000 (07:06 +0000)]
staging: wilc1000: use BIT macro

This patch addresses the checkpatch warning advising the usage of the
BIT macro for Bit shift operation.

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove unused variable msg_len
Hari Prasath Gujulan Elango [Mon, 22 Jun 2015 07:05:42 +0000 (07:05 +0000)]
staging: wilc1000: remove unused variable msg_len

This patch removes a ununsed variable msg_len and its associated code.

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove ununsed variable & associated code
Hari Prasath Gujulan Elango [Mon, 22 Jun 2015 07:05:22 +0000 (07:05 +0000)]
staging: wilc1000: remove ununsed variable & associated code

This patch removes the ununsed variable 'priv' at multiple instances and
all its associated code where its assigned a value.

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove ununsed variable
Hari Prasath Gujulan Elango [Mon, 22 Jun 2015 13:13:58 +0000 (13:13 +0000)]
staging: wilc1000: remove ununsed variable

This patch removes ununsed variable 'len'

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove redundant assignment of variable
Hari Prasath Gujulan Elango [Mon, 22 Jun 2015 07:04:39 +0000 (07:04 +0000)]
staging: wilc1000: remove redundant assignment of variable

This patch the removes the redundant assignement of the variable ret as
its being overwritren before being used anywhere.

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove unused variable
Hari Prasath Gujulan Elango [Mon, 22 Jun 2015 07:04:20 +0000 (07:04 +0000)]
staging: wilc1000: remove unused variable

This patch removes a unused variable timeout and the associated code.

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove ununsed variable & corresponding lines
Hari Prasath Gujulan Elango [Mon, 22 Jun 2015 07:03:53 +0000 (07:03 +0000)]
staging: wilc1000: remove ununsed variable & corresponding lines

This patch removes a couple of ununsed variable.The lines in which these
variables are assigned are also removed as they are not necessary.

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove ununsed if..else.. code blocks
Hari Prasath Gujulan Elango [Mon, 22 Jun 2015 07:03:27 +0000 (07:03 +0000)]
staging: wilc1000: remove ununsed if..else.. code blocks

This patch removes ununsed if..else... code blocks. Its actually some
dead code.

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove redundant initialization of variable
Hari Prasath Gujulan Elango [Mon, 22 Jun 2015 07:03:06 +0000 (07:03 +0000)]
staging: wilc1000: remove redundant initialization of variable

This patch removes the redundant initialization of the variable 'st' as
it is reassigned a new value before its being used anywhere else.

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: remove ununsed variable and associated line
Hari Prasath Gujulan Elango [Mon, 22 Jun 2015 07:02:46 +0000 (07:02 +0000)]
staging: wilc1000: remove ununsed variable and associated line

This patch removes a unused variable 'u16RespLen' that is assigned a
value that is never used. The line that does the assignment is also
removed.

Signed-off-by: Hari Prasath Gujulan Elango <hgujulan@visteon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: wilc_wfi_netdevice.c: move statement after declarations
Chaehyun Lim [Mon, 22 Jun 2015 04:08:15 +0000 (13:08 +0900)]
staging: wilc1000: wilc_wfi_netdevice.c: move statement after declarations

Fix checkpatch warning 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>
9 years agostaging: wilc1000: wilc_wfi_netdevice.c: Insert blank line after declarations
Chaehyun Lim [Mon, 22 Jun 2015 04:08:14 +0000 (13:08 +0900)]
staging: wilc1000: wilc_wfi_netdevice.c: Insert blank line after declarations

Fix checkpatch warning 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>
9 years agostaging: wilc1000: wilc_wfi_netdevice.c: remove braces for single statement block
Chaehyun Lim [Mon, 22 Jun 2015 04:08:13 +0000 (13:08 +0900)]
staging: wilc1000: wilc_wfi_netdevice.c: remove braces for single statement block

Fix checkpatch warning found by checkpatch.pl
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>
9 years agostaging: wilc1000: wilc_wfi_netdevice.c: remove prohibited space
Chaehyun Lim [Mon, 22 Jun 2015 04:08:12 +0000 (13:08 +0900)]
staging: wilc1000: wilc_wfi_netdevice.c: remove prohibited space

Fix checkpatch warning found by checkpatch.pl
WARNING: space prohibited between function name and open parenthesis '('

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: wilc_wfi_netdevice.c: remove prohibited space before semicolon
Chaehyun Lim [Mon, 22 Jun 2015 04:08:11 +0000 (13:08 +0900)]
staging: wilc1000: wilc_wfi_netdevice.c: remove prohibited space before semicolon

Fix checkpatch warning found by checkpatch.pl
WARNING: space prohibited before semicolon

Signed-off-by: Chaehyun Lim <chaehyun.lim@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoStaging: wilc1000: Replace memset with eth_zero_addr
Vaishali Thakkar [Sun, 21 Jun 2015 05:26:21 +0000 (10:56 +0530)]
Staging: wilc1000: Replace memset with eth_zero_addr

Use eth_zero_addr to assign the zero address to the given address
array instead of memset when second argument is address of zero.

The Coccinelle semantic patch that makes this change is as follows:

// <smpl>
@eth_zero_addr@
expression e;
@@

-memset(e,0x00,ETH_ALEN);
+eth_zero_addr(e);
// </smpl>

Signed-off-by: Vaishali Thakkar <vthakkar1994@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agostaging: wilc1000: fix build failure
Sudip Mukherjee [Tue, 30 Jun 2015 08:21:51 +0000 (13:51 +0530)]
staging: wilc1000: fix build failure

commit 80279fb7ba5b ("cfg80211: properly send
NL80211_ATTR_DISCONNECTED_BY_AP in disconnect") has changed the api of
cfg80211_disconnected() and caused a build failure.
Add the extra argument as false since it appears from the code that the
disconnection is not locally generated.
And incase of doubt we can use false as that is the default behaviour.

Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
9 years agoLinux 4.2-rc1
Linus Torvalds [Sun, 5 Jul 2015 18:01:52 +0000 (11:01 -0700)]
Linux 4.2-rc1

9 years agoMerge tag 'platform-drivers-x86-v4.2-2' of git://git.infradead.org/users/dvhart/linux...
Linus Torvalds [Sun, 5 Jul 2015 17:54:09 +0000 (10:54 -0700)]
Merge tag 'platform-drivers-x86-v4.2-2' of git://git.infradead.org/users/dvhart/linux-platform-drivers-x86

Pull late x86 platform driver updates from Darren Hart:
 "The following came in a bit later and I wanted them to bake in next a
  few more days before submitting, thus the second pull.

  A new intel_pmc_ipc driver, a symmetrical allocation and free fix in
  dell-laptop, a couple minor fixes, and some updated documentation in
  the dell-laptop comments.

  intel_pmc_ipc:
   - Add Intel Apollo Lake PMC IPC driver

  tc1100-wmi:
   - Delete an unnecessary check before the function call "kfree"

  dell-laptop:
   - Fix allocating & freeing SMI buffer page
   - Show info about WiGig and UWB in debugfs
   - Update information about wireless control"

* tag 'platform-drivers-x86-v4.2-2' of git://git.infradead.org/users/dvhart/linux-platform-drivers-x86:
  intel_pmc_ipc: Add Intel Apollo Lake PMC IPC driver
  tc1100-wmi: Delete an unnecessary check before the function call "kfree"
  dell-laptop: Fix allocating & freeing SMI buffer page
  dell-laptop: Show info about WiGig and UWB in debugfs
  dell-laptop: Update information about wireless control

9 years agoMerge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
Linus Torvalds [Sun, 5 Jul 2015 02:36:06 +0000 (19:36 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/viro/vfs

Pull more vfs updates from Al Viro:
 "Assorted VFS fixes and related cleanups (IMO the most interesting in
  that part are f_path-related things and Eric's descriptor-related
  stuff).  UFS regression fixes (it got broken last cycle).  9P fixes.
  fs-cache series, DAX patches, Jan's file_remove_suid() work"

[ I'd say this is much more than "fixes and related cleanups".  The
  file_table locking rule change by Eric Dumazet is a rather big and
  fundamental update even if the patch isn't huge.   - Linus ]

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs: (49 commits)
  9p: cope with bogus responses from server in p9_client_{read,write}
  p9_client_write(): avoid double p9_free_req()
  9p: forgetting to cancel request on interrupted zero-copy RPC
  dax: bdev_direct_access() may sleep
  block: Add support for DAX reads/writes to block devices
  dax: Use copy_from_iter_nocache
  dax: Add block size note to documentation
  fs/file.c: __fget() and dup2() atomicity rules
  fs/file.c: don't acquire files->file_lock in fd_install()
  fs:super:get_anon_bdev: fix race condition could cause dev exceed its upper limitation
  vfs: avoid creation of inode number 0 in get_next_ino
  namei: make set_root_rcu() return void
  make simple_positive() public
  ufs: use dir_pages instead of ufs_dir_pages()
  pagemap.h: move dir_pages() over there
  remove the pointless include of lglock.h
  fs: cleanup slight list_entry abuse
  xfs: Correctly lock inode when removing suid and file capabilities
  fs: Call security_ops->inode_killpriv on truncate
  fs: Provide function telling whether file_remove_privs() will do anything
  ...

9 years agobluetooth: fix list handling
Linus Torvalds [Sun, 5 Jul 2015 02:11:33 +0000 (19:11 -0700)]
bluetooth: fix list handling

Commit 835a6a2f8603 ("Bluetooth: Stop sabotaging list poisoning")
thought that the code was sabotaging the list poisoning when NULL'ing
out the list pointers and removed it.

But what was going on was that the bluetooth code was using NULL
pointers for the list as a way to mark it empty, and that commit just
broke it (and replaced the test with NULL with a "list_empty()" test on
a uninitialized list instead, breaking things even further).

So fix it all up to use the regular and real list_empty() handling
(which does not use NULL, but a pointer to itself), also making sure to
initialize the list properly (the previous NULL case was initialized
implicitly by the session being allocated with kzalloc())

This is a combination of patches by Marcel Holtmann and Tedd Ho-Jeong
An.

[ I would normally expect to get this through the bt tree, but I'm going
  to release -rc1, so I'm just committing this directly   - Linus ]

Reported-and-tested-by: Jörg Otte <jrg.otte@gmail.com>
Cc: Alexey Dobriyan <adobriyan@gmail.com>
Original-by: Tedd Ho-Jeong An <tedd.an@intel.com>
Original-by: Marcel Holtmann <marcel@holtmann.org>:
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
9 years agoMerge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target...
Linus Torvalds [Sat, 4 Jul 2015 21:13:43 +0000 (14:13 -0700)]
Merge branch 'for-next' of git://git./linux/kernel/git/nab/target-pending

Pull SCSI target updates from Nicholas Bellinger:
 "It's been a busy development cycle for target-core in a number of
  different areas.

  The fabric API usage for se_node_acl allocation is now within
  target-core code, dropping the external API callers for all fabric
  drivers tree-wide.

  There is a new conversion to RCU hlists for se_node_acl and
  se_portal_group LUN mappings, that turns fast-past LUN lookup into a
  completely lockless code-path.  It also removes the original
  hard-coded limitation of 256 LUNs per fabric endpoint.

  The configfs attributes for backends can now be shared between core
  and driver code, allowing existing drivers to use common code while
  still allowing flexibility for new backend provided attributes.

  The highlights include:

   - Merge sbc_verify_dif_* into common code (sagi)
   - Remove iscsi-target support for obsolete IFMarker/OFMarker
     (Christophe Vu-Brugier)
   - Add bidi support in target/user backend (ilias + vangelis + agover)
   - Move se_node_acl allocation into target-core code (hch)
   - Add crc_t10dif_update common helper (akinobu + mkp)
   - Handle target-core odd SGL mapping for data transfer memory
     (akinobu)
   - Move transport ID handling into target-core (hch)
   - Move task tag into struct se_cmd + support 64-bit tags (bart)
   - Convert se_node_acl->device_list[] to RCU hlist (nab + hch +
     paulmck)
   - Convert se_portal_group->tpg_lun_list[] to RCU hlist (nab + hch +
     paulmck)
   - Simplify target backend driver registration (hch)
   - Consolidate + simplify target backend attribute implementations
     (hch + nab)
   - Subsume se_port + t10_alua_tg_pt_gp_member into se_lun (hch)
   - Drop lun_sep_lock for se_lun->lun_se_dev RCU usage (hch + nab)
   - Drop unnecessary core_tpg_register TFO parameter (nab)
   - Use 64-bit LUNs tree-wide (hannes)
   - Drop left-over TARGET_MAX_LUNS_PER_TRANSPORT limit (hannes)"

* 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending: (76 commits)
  target: Bump core version to v5.0
  target: remove target_core_configfs.h
  target: remove unused TARGET_CORE_CONFIG_ROOT define
  target: consolidate version defines
  target: implement WRITE_SAME with UNMAP bit using ->execute_unmap
  target: simplify UNMAP handling
  target: replace se_cmd->execute_rw with a protocol_data field
  target/user: Fix inconsistent kmap_atomic/kunmap_atomic
  target: Send UA when changing LUN inventory
  target: Send UA upon LUN RESET tmr completion
  target: Send UA on ALUA target port group change
  target: Convert se_lun->lun_deve_lock to normal spinlock
  target: use 'se_dev_entry' when allocating UAs
  target: Remove 'ua_nacl' pointer from se_ua structure
  target_core_alua: Correct UA handling when switching states
  xen-scsiback: Fix compile warning for 64-bit LUN
  target: Remove TARGET_MAX_LUNS_PER_TRANSPORT
  target: use 64-bit LUNs
  target: Drop duplicate + unused se_dev_check_wce
  target: Drop unnecessary core_tpg_register TFO parameter
  ...

9 years agoMerge tag 'ntb-4.2' of git://github.com/jonmason/ntb
Linus Torvalds [Sat, 4 Jul 2015 21:07:47 +0000 (14:07 -0700)]
Merge tag 'ntb-4.2' of git://github.com/jonmason/ntb

Pull NTB updates from Jon Mason:
 "This includes a pretty significant reworking of the NTB core code, but
  has already produced some significant performance improvements.

  An abstraction layer was added to allow the hardware and clients to be
  easily added.  This required rewriting the NTB transport layer for
  this abstraction layer.  This modification will allow future "high
  performance" NTB clients.

  In addition to this change, a number of performance modifications were
  added.  These changes include NUMA enablement, using CPU memcpy
  instead of asyncdma, and modification of NTB layer MTU size"

* tag 'ntb-4.2' of git://github.com/jonmason/ntb: (22 commits)
  NTB: Add split BAR output for debugfs stats
  NTB: Change WARN_ON_ONCE to pr_warn_once on unsafe
  NTB: Print driver name and version in module init
  NTB: Increase transport MTU to 64k from 16k
  NTB: Rename Intel code names to platform names
  NTB: Default to CPU memcpy for performance
  NTB: Improve performance with write combining
  NTB: Use NUMA memory in Intel driver
  NTB: Use NUMA memory and DMA chan in transport
  NTB: Rate limit ntb_qp_link_work
  NTB: Add tool test client
  NTB: Add ping pong test client
  NTB: Add parameters for Intel SNB B2B addresses
  NTB: Reset transport QP link stats on down
  NTB: Do not advance transport RX on link down
  NTB: Differentiate transport link down messages
  NTB: Check the device ID to set errata flags
  NTB: Enable link for Intel root port mode in probe
  NTB: Read peer info from local SPAD in transport
  NTB: Split ntb_hw_intel and ntb_transport drivers
  ...

9 years ago9p: cope with bogus responses from server in p9_client_{read,write}
Al Viro [Sat, 4 Jul 2015 20:17:39 +0000 (16:17 -0400)]
9p: cope with bogus responses from server in p9_client_{read,write}

if server claims to have written/read more than we'd told it to,
warn and cap the claimed byte count to avoid advancing more than
we are ready to.

9 years agop9_client_write(): avoid double p9_free_req()
Al Viro [Sat, 4 Jul 2015 20:11:05 +0000 (16:11 -0400)]
p9_client_write(): avoid double p9_free_req()

Braino in "9p: switch p9_client_write() to passing it struct iov_iter *";
if response is impossible to parse and we discard the request, get the
out of the loop right there.

Cc: stable@vger.kernel.org
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
9 years ago9p: forgetting to cancel request on interrupted zero-copy RPC
Al Viro [Sat, 4 Jul 2015 20:04:19 +0000 (16:04 -0400)]
9p: forgetting to cancel request on interrupted zero-copy RPC

If we'd already sent a request and decide to abort it, we *must*
issue TFLUSH properly and not just blindly reuse the tag, or
we'll get seriously screwed when response eventually arrives
and we confuse it for response to later request that had reused
the same tag.

Cc: stable@vger.kernel.org # v3.2 and later
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
9 years agodax: bdev_direct_access() may sleep
Matthew Wilcox [Fri, 3 Jul 2015 14:40:43 +0000 (10:40 -0400)]
dax: bdev_direct_access() may sleep

The brd driver is the only in-tree driver that may sleep currently.
After some discussion on linux-fsdevel, we decided that any driver
may choose to sleep in its ->direct_access method.  To ensure that all
callers of bdev_direct_access() are prepared for this, add a call
to might_sleep().

Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
9 years agoblock: Add support for DAX reads/writes to block devices
Matthew Wilcox [Fri, 3 Jul 2015 14:40:42 +0000 (10:40 -0400)]
block: Add support for DAX reads/writes to block devices

If a block device supports the ->direct_access methods, bypass the normal
DIO path and use DAX to go straight to memcpy() instead of allocating
a DIO and a BIO.

Includes support for the DIO_SKIP_DIO_COUNT flag in DAX, as is done in
do_blockdev_direct_IO().

Signed-off-by: Matthew Wilcox <matthew.r.wilcox@intel.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
9 years agodax: Use copy_from_iter_nocache
Matthew Wilcox [Fri, 3 Jul 2015 14:40:39 +0000 (10:40 -0400)]
dax: Use copy_from_iter_nocache

When userspace does a write, there's no need for the written data to
pollute the CPU cache.  This matches the original XIP code.

Signed-off-by: Matthew Wilcox <willy@linux.intel.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
9 years agodax: Add block size note to documentation
Matthew Wilcox [Fri, 3 Jul 2015 14:40:38 +0000 (10:40 -0400)]
dax: Add block size note to documentation

For block devices which are small enough, mkfs will default to creating
a filesystem with block sizes smaller than page size.

Signed-off-by: Matthew Wilcox <willy@linux.intel.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>