Re: [PATCH v2] Staging: zram: Fix variable dereferenced before check

2013-10-21 Thread Minchan Kim
On Sat, Oct 19, 2013 at 01:59:05PM -0700, Greg KH wrote: > On Sat, Oct 19, 2013 at 10:01:42PM +0530, Rashika Kheria wrote: > > This patch fixes the following Smatch warning in zram_drv.c- > > ~/git/kernels/linux/drivers/staging/zram/zram_drv.c:663 > > reset_store() warn: variable dereferenced befor

[PATCH v2 09/11] staging: comedi: s626: expand standardized IndxSrc values

2013-10-21 Thread Ian Abbott
The 'IndxSrc' value for the standardized encoder setup is currently 1 bit wide and takes one of the following values: S626_INDXSRC_HARD = 0 // index source from hardware encoder S626_INDXSRC_SOFT = 1 // index source software controlled by IndxPol However the hardware 'IndxSrcA' and 'IndxSrcB'

[PATCH v2 08/11] staging: comedi: s626: make CRA and CRB setup conversions more readable

2013-10-21 Thread Ian Abbott
Use the new macros defined in "s626.h" for constructing and decomposing 'CRA', 'CRB' and standardized encoder setup values to make the conversions between standardized encoder setup values, and CRA/CRB register values easier to follow. There is some messing about with the 'IndxSrc' values which ar

[PATCH v2 10/11] staging: comedi: s626: remove S626_BF_* macros

2013-10-21 Thread Ian Abbott
The `S626_BF_*` bitfield position macros are no longer used and are just a subset of the corresponding `S626_STDBIT_*` bitfield position macros. Remove them. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten --- v2: rebase, resend --- drivers/staging/comedi/drivers/s626.h | 9 -

[PATCH v2 11/11] staging: comedi: s626: replace S626_MULT_X? values

2013-10-21 Thread Ian Abbott
Replace the use of the `S626_MULT_X1`, `S626_MULT_X2` and `S626_MULT_X4` clock multiplier values with the equivalent `S626_CLKMULT_1X`, `S626_CLKMULT_2X` and `S626_CLKMULT_4X` values to avoid duplication. Replace the use of `S626_MULT_X0` with a new macro `S626_CLKMULT_SPECIAL` (this is treated spe

[PATCH v3] Staging: zram: Fix variable dereferenced before check

2013-10-21 Thread Rashika Kheria
This patch fixes the following Smatch warning in zram_drv.c- drivers/staging/zram/zram_drv.c:663 reset_store() warn: variable dereferenced before check 'bdev' (see line 652) drivers/staging/zram/zram_drv.c:899 destroy_device() warn: variable dereferenced before check 'zram->disk' (see line 896) S

[PATCH] staging: comedi: adl_pci9118: fix a misaligned comment

2013-10-21 Thread Ian Abbott
As pointed out by Hartley Sweeten, one of my recent patches resulted in the start of a multi-line comment ending up misaligned. Fix it. Signed-off-by: Ian Abbott --- drivers/staging/comedi/drivers/adl_pci9118.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/

Re: [PATCH v3] Staging: zram: Fix variable dereferenced before check

2013-10-21 Thread Minchan Kim
Hello, On Mon, Oct 21, 2013 at 02:52:41PM +0530, Rashika Kheria wrote: > This patch fixes the following Smatch warning in zram_drv.c- > drivers/staging/zram/zram_drv.c:663 > reset_store() warn: variable dereferenced before check 'bdev' (see line 652) > drivers/staging/zram/zram_drv.c:899 > destroy

[PATCH 2/3] staging: lustre: Remove typedef and update cfs_hash_bd struct

2013-10-21 Thread Lisa Nguyen
Remove typedef keyword and rename the cfs_hash_bd_t struct to cfs_hash_bd in libcfs_hash.h. These changes resolve the "Do not add new typedefs" warning generated by checkpatch.pl and meet kernel coding style. Struct variables in other header and source files that depend on libcfs_hash.h are update

[PATCH 1/3] staging: lustre: Remove typedef and update cfs_debug_limit_state struct

2013-10-21 Thread Lisa Nguyen
Removed typedef keyword and rename the cfs_debug_limit_state_t struct to cfs_debug_limit_state in libcfs_debug.h. These changes resolve the "Do not add new typedefs" warning generated by checkpatch.pl and meet kernel coding style. Struct variables in other header and source files that depend on li

[PATCH V2] staging: r8188eu: Set device type to wlan

2013-10-21 Thread Larry Finger
The latest version of NetworkManager does not recognize the device as wireless without this change. Signed-off-by: Larry Finger Cc: Stable a [3.12+] --- drivers/staging/rtl8188eu/os_dep/os_intfs.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/staging/rtl8188eu/os_dep/os_intfs.

[PATCH 2/3] staging: lustre: lnet: Remove unnecessary () from return statements

2013-10-21 Thread Lisa Nguyen
Remove unnecessary parentheses from return statements in lib-lnet.h to meet kernel coding style. Signed-off-by: Lisa Nguyen --- drivers/staging/lustre/include/linux/lnet/lib-lnet.h | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/staging/lustre/include/lin

[PATCH 1/3] staging: lustre: lnet: Remove unnecessary spaces in lib-lnet.h

2013-10-21 Thread Lisa Nguyen
Remove spaces between function names and open parentheses to meet kernel coding style and eliminate extra space warnings generated by checkpatch.pl Signed-off-by: Lisa Nguyen --- .../staging/lustre/include/linux/lnet/lib-lnet.h | 78 +++--- 1 file changed, 39 insertions(+), 39

[PATCH 3/3] staging: lustre: lnet: Reformat pointer variable in lib-lnet.h

2013-10-21 Thread Lisa Nguyen
Reformat a pointer variable in lib-lnet.h to meet kernel coding style and eliminate pointer format warning generated by checkpatch.pl Signed-off-by: Lisa Nguyen --- drivers/staging/lustre/include/linux/lnet/lib-lnet.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/st