Re: [PATCH] drivers/staging/wilc1000: fix sparse warning: right shift by bigger than source value

2017-07-11 Thread Greg Kroah-Hartman
On Wed, Jul 12, 2017 at 10:23:02AM +0800, Rui Teng wrote: > On 12/07/2017 1:04 AM, Greg Kroah-Hartman wrote: > > On Mon, Jul 10, 2017 at 04:57:31PM +0800, Rui Teng wrote: > > > This patch sets memory to zero directly to avoid unnecessary shift and > > > bitwise operations on bool type, which can fi

Re: [PATCH RESEND] staging: sm750fb: avoid conflicting vesafb

2017-07-11 Thread Greg Kroah-Hartman
On Tue, Jul 11, 2017 at 10:03:01PM +0100, Sudip Mukherjee wrote: > Hi Greg, > > On Fri, Jun 30, 2017 at 09:57:43PM +0100, Sudip Mukherjee wrote: > > From: Teddy Wang > > > > If vesafb is enabled in the config then /dev/fb0 is created by vesa > > and this sm750 driver gets fb1, fb2. But we need t

Re: [PATCH] Clean up lirc zilog error codes

2017-07-11 Thread Frans Klaver
On Tue, Jul 11, 2017 at 7:57 PM, Yves Lemée wrote: > According the coding style guidelines, the ENOSYS error code must be returned > in case of a non existent system call. This code has been replaced with > the ENOTTY error code indicating, a missing functionality. > > Signed-off-by: Yves Lemée

Re: [PATCH] staging: wlan-ng: Use little-endian type

2017-07-11 Thread Frans Klaver
On Tue, Jul 11, 2017 at 9:51 PM, Aviv Palivoda wrote: > Fix the following sparse warning: > drivers/staging//wlan-ng/prism2sta.c:1691:20: warning: incorrect type in > assignment (different base types) > > (a) Change struct hfa384x_authenticate_station_data status member type to > __le16. > (b) A

Re: [PATCH v2 2/2] Staging: android/ion: fix sparse warning

2017-07-11 Thread Frans Klaver
Hi, Again, your subject is too generic. On Wed, Jul 12, 2017 at 6:51 AM, Joseph Wright wrote: > Declare private function static to fix sparse warning: > > ion_cma_heap.c:109:5: warning: symbol '__ion_add_cma_heaps' \ > was not declared. Should it be static? > > Signed-off-by: Joseph Wri

Re: [PATCH v2 1/2] Staging: android/ion: fix sparse warnings

2017-07-11 Thread Frans Klaver
Hi, please consider changing your subject to something like staging: android/ion: declare two functions Perhaps you can make it more on-topic. It's more useful than "fix sparse warning" On Wed, Jul 12, 2017 at 6:51 AM, Joseph Wright wrote: > Declare functions to fix sparse warnings: > > ion_ca

Re: [PATCH 8/8] Staging: lustre :lustre: include :lustre_compat.h: Prefer using the BIT macro

2017-07-11 Thread Dilger, Andreas
> On Jul 11, 2017, at 11:08, Greg KH wrote: > > On Thu, Jul 06, 2017 at 12:43:15PM +0530, Jaya Durga wrote: >> Replace all instances of (1 << 27) with BIT(27) to fix >> checkpatch check messages >> >> Signed-off-by: Jaya Durga >> --- >> drivers/staging/lustre/lustre/include/lustre_compat.h | 2

Re: [PATCH 3/4] Staging: Lustre Fixing multiline block comments in lnetst.h

2017-07-11 Thread Dilger, Andreas
On Jul 11, 2017, at 11:14, Greg Kroah-Hartman wrote: > > On Fri, Jul 07, 2017 at 01:47:04AM +, Craig Inches wrote: >> This fixes multiple block statements found not to match >> style as per checkpatch >> >> Signed-off-by: Craig Inches >> --- >> drivers/staging/lustre/include/linux/lnet/lne

[PATCH v2 0/2] Staging: android/ion: fix sparse warnings

2017-07-11 Thread Joseph Wright
Split sparse warning fixes into multiple patches. Joseph Wright (2): Staging: android/ion: fix sparse warnings Staging: android/ion: fix sparse warning drivers/staging/android/ion/ion.h | 4 drivers/staging/android/ion/ion_cma_heap.c | 2 +- 2 files changed, 5 insertions(+), 1

[PATCH v2 2/2] Staging: android/ion: fix sparse warning

2017-07-11 Thread Joseph Wright
Declare private function static to fix sparse warning: ion_cma_heap.c:109:5: warning: symbol '__ion_add_cma_heaps' \ was not declared. Should it be static? Signed-off-by: Joseph Wright --- Changes in v2: - Split into multiple patches drivers/staging/android/ion/ion_cma_heap.c | 2 +-

[PATCH v2 1/2] Staging: android/ion: fix sparse warnings

2017-07-11 Thread Joseph Wright
Declare functions to fix sparse warnings: ion_carveout_heap.c:115:17: warning: symbol 'ion_carveout_heap_create' \ was not declared. Should it be static? ion_chunk_heap.c:120:17: warning: symbol 'ion_chunk_heap_create' \ was not declared. Should it be static? Signed-off-by: Joseph

Re: [PATCH] drivers/staging/wilc1000: fix sparse warning: right shift by bigger than source value

2017-07-11 Thread Rui Teng
On 12/07/2017 1:04 AM, Greg Kroah-Hartman wrote: On Mon, Jul 10, 2017 at 04:57:31PM +0800, Rui Teng wrote: This patch sets memory to zero directly to avoid unnecessary shift and bitwise operations on bool type, which can fix a sparse warning and also improve performance. It does? How did you

Re: [PATCH RESEND] staging: sm750fb: avoid conflicting vesafb

2017-07-11 Thread Sudip Mukherjee
Hi Greg, On Fri, Jun 30, 2017 at 09:57:43PM +0100, Sudip Mukherjee wrote: > From: Teddy Wang > > If vesafb is enabled in the config then /dev/fb0 is created by vesa > and this sm750 driver gets fb1, fb2. But we need to be fb0 and fb1 to > effectively work with xorg. > So if it has been alloted f

[PATCH] staging: vchiq_arm: fix error codes in probe

2017-07-11 Thread Dan Carpenter
If vchiq_debugfs_init() fails, then we accidentally return a valid pointer casted to int on error. This code is simpler if we get rid of the "ptr_err" variable and just use "err" throughout. Signed-off-by: Dan Carpenter diff --git a/drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c

[PATCH] staging: wlan-ng: Use little-endian type

2017-07-11 Thread Aviv Palivoda
Fix the following sparse warning: drivers/staging//wlan-ng/prism2sta.c:1691:20: warning: incorrect type in assignment (different base types) (a) Change struct hfa384x_authenticate_station_data status member type to __le16. (b) All assignment to status are converted to little-endian prior to assi

Re: [PATCH] staging: unisys: visorbus: fix function open braces

2017-07-11 Thread Greg Kroah-Hartman
On Mon, Jul 10, 2017 at 11:48:26PM -0400, Mitchell Tasman wrote: > Resolve multiple checkpatch errors by relocating open braces > following function definitions to the next line. > > Signed-off-by: Mitchell Tasman > --- > drivers/staging/unisys/visorbus/visorbus_main.c | 18 -- >

Re: [PATCH] Staging: android/ion: fix sparse warnings

2017-07-11 Thread Greg KH
On Wed, Jul 05, 2017 at 12:12:24AM +, Joseph Wright wrote: > ion_carveout_heap.c:115:17: warning: symbol 'ion_carveout_heap_create' \ > was not declared. Should it be static? > ion_chunk_heap.c:120:17: warning: symbol 'ion_chunk_heap_create' \ > was not declared. Should it be static

[PATCH] Clean up lirc zilog error codes

2017-07-11 Thread Yves Lemée
According the coding style guidelines, the ENOSYS error code must be returned in case of a non existent system call. This code has been replaced with the ENOTTY error code indicating, a missing functionality. Signed-off-by: Yves Lemée --- drivers/staging/media/lirc/lirc_zilog.c | 10 +-

[PATCH][V2] staging: fbtft: make const array gamma_par_mask static

2017-07-11 Thread Colin King
From: Colin Ian King Don't populate array gamma_par_mask on the stack but instead make it static. Makes the object code smaller by 148 bytes: Before: textdata bss dec hex filename 29931104 040971001 drivers/staging/fbtft/fb_st7789v.o After: textda

Re: [PATCH] staging: ks7010: fix styling WARNINGs

2017-07-11 Thread Greg KH
On Fri, Jun 30, 2017 at 11:39:27AM -0700, Mark Rogers wrote: > Thank you for your feedback. I guess when making this patch I had the > preferred coding style in mind, but didn't ask myself if making the code > conform to it would truly improve readability. > > I agree with all of your comments. Do

Re: [PATCH 04/25] staging: unisys: visorbus: visorbus_main.c: fixed comment formatting issues

2017-07-11 Thread Greg KH
On Fri, Jun 30, 2017 at 03:43:05PM -0400, David Kershner wrote: > From: Sameer Wadgaonkar > > Removed comments from the right side of the lines. You also reformattted a few of them. Not a big deal, but don't lie in changelogs :) thanks, greg k-h ___

Re: [PATCH 3/4] Staging: Lustre Fixing multiline block comments in lnetst.h

2017-07-11 Thread Greg Kroah-Hartman
On Fri, Jul 07, 2017 at 01:47:04AM +, Craig Inches wrote: > This fixes multiple block statements found not to match > style as per checkpatch > > Signed-off-by: Craig Inches > --- > drivers/staging/lustre/include/linux/lnet/lnetst.h | 129 > + > 1 file changed, 81 insert

Re: [PATCH 1/4] Staging: Luster: Clean up line over 80Char in lib-lnet.h

2017-07-11 Thread Greg Kroah-Hartman
On Fri, Jul 07, 2017 at 01:46:42AM +, Craig Inches wrote: > This patch fixes a warning generated by checkpatch for > a line over 80 characters. > > Signed-off-by: Craig Inches > --- > drivers/staging/lustre/include/linux/lnet/lib-lnet.h | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(

Re: [PATCH] staging: lustre: mgc: Fix incorrect type in assignment

2017-07-11 Thread Greg Kroah-Hartman
On Sat, Jul 01, 2017 at 05:26:52PM +0300, Kamal Heib wrote: > Fix the following sparse warnings: > mgc_request.c:68:25: warning: incorrect type in assignment (different base > types) > mgc_request.c:68:25:expected unsigned long long [unsigned] [long] [long > long] > mgc_request.c:68:25:g

Re: [PATCH 390/390] staging:rtl8723bs:core:rtw_btcoex: Fixed checkpatch.pl warning on 'Comparisons should place the constant on the right side of the test'.

2017-07-11 Thread Greg KH
On Wed, Jul 05, 2017 at 12:49:52PM +0530, Shreeya Patel wrote: > Fixed a coding style issue. > > Signed-off-by: Shreeya Patel > --- > drivers/staging/rtl8723bs/core/rtw_btcoex.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Where are the 329 other patches in this series? I can't take

Re: [PATCH 7/7] Staging: rtl8712 : rtl871x_io.c:fix coding style of kmalloc usage

2017-07-11 Thread Greg KH
On Tue, Jul 04, 2017 at 04:11:31PM +0530, Jaya Durga wrote: > CHECK: multiple assignments should be avoided > CHECK: Prefer kmalloc(sizeof(*pintf_hdl->pintfpriv)...) > over kmalloc(sizeof(struct intf_priv)...) > > Signed-off-by: Jaya Durga > --- > drivers/staging/rtl8712/rtl871x_io.c | 3 ++- >

Re: [PATCH 2/6] Staging: rtl8712 : os_intfs.c: use octal permission representation

2017-07-11 Thread Greg KH
On Tue, Jul 04, 2017 at 11:31:15AM +0530, Jaya Durga wrote: > Fix checkpatch.pl Warning: Symbolic permissions 'S_IRUGO | S_IWUSR' are not > preferred. > Consider using octal permissions '0644'. > > Signed-off-by: Jaya Durga > --- > drivers/staging/rtl8712/os_intfs.c | 2 +- > 1 file changed, 1

Re: [PATCH 2/6] Staging: rtl8712 : os_intfs.c: use octal permission representation

2017-07-11 Thread Greg KH
On Fri, Jun 30, 2017 at 11:28:13AM +0530, Jaya Durga wrote: > Fix checkpatch.pl Warning: Symbolic permissions 'S_IRUGO | S_IWUSR' are not > preferred. > Consider using octal permissions '0644'. > > Signed-off-by: Jaya Durga > --- > drivers/staging/rtl8712/os_intfs.c | 2 +- > 1 file changed, 1

Re: [PATCH 8/8] Staging: lustre :lustre: include :lustre_compat.h: Prefer using the BIT macro

2017-07-11 Thread Greg KH
On Thu, Jul 06, 2017 at 12:43:15PM +0530, Jaya Durga wrote: > Replace all instances of (1 << 27) with BIT(27) to fix > checkpatch check messages > > Signed-off-by: Jaya Durga > --- > drivers/staging/lustre/lustre/include/lustre_compat.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >

Re: [PATCH] drivers/staging/wilc1000: fix sparse warning: right shift by bigger than source value

2017-07-11 Thread Greg Kroah-Hartman
On Mon, Jul 10, 2017 at 04:57:31PM +0800, Rui Teng wrote: > This patch sets memory to zero directly to avoid unnecessary shift and > bitwise operations on bool type, which can fix a sparse warning and also > improve performance. It does? How did you measure the performance impact? What was now f

Re: [PATCH 00/10] Fix alignment issues in staging/ccree

2017-07-11 Thread Greg KH
On Sun, Jul 02, 2017 at 01:25:45AM +0200, Simon Sandström wrote: > Fixes a total of 195 alignment issues in staging/ccree reported by > checkpatch.pl. Adds a few "line over 80 characters" warnings as a > result of the realignments, but I could try to get rid of them in the > same patchset if needed

Re: [PATCH 1/2] staging: atomisp2: hmm: Fixed comment style

2017-07-11 Thread Sakari Ailus
On Mon, Jul 10, 2017 at 08:56:20PM +0200, Philipp Guendisch wrote: > This patch fixed comment style. Semantic should not be affected. > There are also two warnings left about too long lines, which > reduce readability if changed. > > Signed-off-by: Philipp Guendisch > Signed-off-by: Chris Baller

[PATCH] staging: ccree: move FIPS support to kernel infrastructure

2017-07-11 Thread Gilad Ben-Yossef
The ccree driver had its own FIPS support, complete with a test harness comparable to crypto testmgr and an implementation which disables crypto functionality on FIPS test error detection, either in Linux or from TEE. This patch removes the duplication, while reimplementing the handling of TEE rep

Re: [PATCH 1/2] staging: ccree: remove unnecessary cast on kmalloc

2017-07-11 Thread Gilad Ben-Yossef
On Sun, Jul 9, 2017 at 8:43 AM, Gustavo A. R. Silva wrote: > The assignment operator implicitly converts a void pointer to the type of the > pointer it is assigned to. > > This issue was detected using Coccinelle and the following semantic patch: > > @@ > expression * e; > expression arg1, arg2; >

Re: [PATCH 0/5] staging: ccree: fix checkpatch errors

2017-07-11 Thread Gilad Ben-Yossef
Tyler, On Tue, Jul 11, 2017 at 4:38 PM, Gilad Ben-Yossef wrote: > On Mon, Jul 10, 2017 at 12:10 AM, wrote: >> From: Tyler Olivieri >> >> This patchset fixes several checkpatch errors and warnings in /staging/ccree: You've messed Greg's email address, so my ACK bounced. The content is good,

Re: [PATCH v2] staging: ccree: Use __func__ instead of function name

2017-07-11 Thread Gilad Ben-Yossef
Hello Karthik , Thank you for the patch. On Thu, Jun 29, 2017 at 8:08 PM, wrote: > From: Karthik Tummala > > Fixed following checkpatch.pl warning: > WARNING: Prefer using '"%s...", __func__' to using > the function's name, in a string > > It is prefered to use '%s & __func__' instead

Re: [PATCH 0/5] staging: ccree: fix checkpatch errors

2017-07-11 Thread Gilad Ben-Yossef
On Mon, Jul 10, 2017 at 12:10 AM, wrote: > From: Tyler Olivieri > > This patchset fixes several checkpatch errors and warnings in /staging/ccree: > > ERROR: that open brace { should be on the previous line > ERROR: open brace '{' following function declarations go on the next line > WARNING: EXP

Re: [PATCH] [media] staging/imx: remove confusing IS_ERR_OR_NULL usage

2017-07-11 Thread Arnd Bergmann
On Thu, Jun 29, 2017 at 11:13 AM, Philipp Zabel wrote: >> @@ -134,23 +134,26 @@ static void csi_idmac_put_ipu_resources(struct >> csi_priv *priv) >> static int csi_idmac_get_ipu_resources(struct csi_priv *priv) >> { >> int ch_num, ret; >> + struct ipu_smfc *smfc, *idmac_ch; > > This

[PATCH v2] [media] staging/imx: remove confusing IS_ERR_OR_NULL usage

2017-07-11 Thread Arnd Bergmann
While looking at a compiler warning, I noticed the use of IS_ERR_OR_NULL, which is generally a sign of a bad API design and should be avoided. In this driver, this is fairly easy, we can simply stop storing error pointers in persistent structures, and change the two functions that might return eit

Re: [PATCH] staging: bcm2835-audio: replace BUG_ON with WARN_ON

2017-07-11 Thread Greg KH
On Tue, Jul 11, 2017 at 04:54:24PM +0530, karuna grewal wrote: > replace BUG_ON with WARN_ON as pointed out by checkpatch > > Signed-off-by: Karuna Grewal I can not accept patches sent in html format... > --- >  drivers/staging/vc04_services/bcm2835-audio/bcm2835-ctl.c | 2 +- >  1 file changed,

Re: [PATCH] staging: bcm2835-audio: remove more than 80 char error

2017-07-11 Thread Joe Perches
On Tue, 2017-07-11 at 16:59 +0530, Karuna Grewal wrote: > remove the more than 80 character error as pointed out by checkpatch by > spliting the statements at the separators in the statements . Not every 80 column warning needs fixing. Your selection of separators is poor. For instance:

Re: [PATCH] staging: bcm2835-audio: remove more than 80 char error

2017-07-11 Thread Dan Carpenter
On Tue, Jul 11, 2017 at 04:59:14PM +0530, Karuna Grewal wrote: > remove the more than 80 character error as pointed out by checkpatch by > spliting the statements at the separators in the statements . > Don't indent your commit log. > - if (changed || (ucontrol->value.integer

Re: [PATCH] Stagingdriver cctree: Fix for checkpatch warning

2017-07-11 Thread Gilad Ben-Yossef
Hello Philip, Thank your patch. Your patch subject line is not descriptive and not formatted well. A better subject would be something like: staging: ccree: move comment to fit coding style Thanks, Gilad On Fri, Jun 30, 2017 at 7:32 AM, wrote: > From: Bincy K Philip > > Trivial fix for Lin

Re: [PATCH 00/10] Fix alignment issues in staging/ccree

2017-07-11 Thread Gilad Ben-Yossef
On Mon, Jul 3, 2017 at 3:28 PM, Simon Sandström wrote: > On Mon, Jul 03, 2017 at 10:19:31AM +0300, Gilad Ben-Yossef wrote: >> but for the few cases where its a complex expression that can be >> broken down like this one: >> >> WARNING: line over 80 characters >> #93: FILE: drivers/staging/ccree/ss

[PATCH] staging: bcm2835-audio: remove more than 80 char error

2017-07-11 Thread Karuna Grewal
remove the more than 80 character error as pointed out by checkpatch by spliting the statements at the separators in the statements . Signed-off-by: Karuna Grewal --- .../vc04_services/bcm2835-audio/bcm2835-ctl.c | 53 ++ 1 file changed, 35 insertions(+), 18 dele

Re: [patch] staging: speakup: safely close tty

2017-07-11 Thread Okash Khawaja
Hi, On Mon, Jul 10, 2017 at 12:55:44PM +0100, Alan Cox wrote: > On Fri, 7 Jul 2017 20:13:01 +0100 > Okash Khawaja wrote: > > > Speakup opens tty using tty_open_by_driver. When closing, it calls > > tty_ldisc_release but doesn't close and remove the tty itself. As a > > result, that tty cannot th