[PATCH] Staging: iio: adc: Added Space around binary op.

2017-09-07 Thread Himanshi Jain
Added space around(one on each side of) binary operator(-) as preferred according to kernel coding style. Signed-off-by: Himanshi Jain --- drivers/staging/iio/adc/ad7192.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH 1/2] staging: typec: tcpm: Validate source and sink caps

2017-09-07 Thread Badhri Jagan Sridharan
The source and sink caps should follow the following rules. This patch validates whether the src_caps/snk_caps adheres to it. 6.4.1 Capabilities Message A Capabilities message (Source Capabilities message or Sink Capabilities message) shall have at least one Power Data Object for vSafe5V. The

[PATCH 2/2] staging: typec: tcpm: Only request matching pdos

2017-09-07 Thread Badhri Jagan Sridharan
At present, TCPM code assumes that local device supports variable/batt pdos and always selects the pdo with highest possible power within the board limit. This assumption might not hold good for all devices. To overcome this, this patch makes TCPM only accept a source_pdo when there is a matching

Re: [Outreachy kernel] [PATCH] Staging:pi433:pi433_if.c:Fixes minor typo errors

2017-09-07 Thread Julia Lawall
On Fri, 8 Sep 2017, harsha wrote: > Fixes checkpatch warning -- "occured" and "succesfully" are misspelled Thanks for the patch. The change looks ok, but the subject line is not. Use git log --oneline on the affected file to see what others have done. In general, you cannot guess what the

[PATCH] Staging:pi433:pi433_if.c:Fixes minor typo errors

2017-09-07 Thread harsha
Fixes checkpatch warning -- "occured" and "succesfully" are misspelled Signed-off-by: Harsha Sharma --- drivers/staging/pi433/pi433_if.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/pi433/pi433_if.c

[PATCH] Staging: atomisp: fix alloc_cast.cocci warnings

2017-09-07 Thread Branislav Radocaj
Remove casting the values returned by memory allocation functions like kmalloc, kzalloc, kmem_cache_alloc, kmem_cache_zalloc etc. Semantic patch information: This makes an effort to find cases of casting of values returned by kmalloc, kzalloc, kcalloc, kmem_cache_alloc, kmem_cache_zalloc,

Re: [PATCH v2 04/11] usb: xhci: Add Intel cherrytrail extended cap / otg phy mux handling

2017-09-07 Thread Hans de Goede
Hi, On 07-09-17 15:14, Mathias Nyman wrote: On 05.09.2017 19:42, Hans de Goede wrote: The Intel cherrytrail xhci controller has an extended cap mmio-range which contains registers to control the muxing to the xhci (host mode) or the dwc3 (device mode) and vbus-detection for the otg usb-phy.

[PATCH v2] Staging: ccree: Prefer using BIT macro.

2017-09-07 Thread Srishti Sharma
Use BIT(x) instead of using (1< --- Changes in v2: - Add tab spaces before BIT macro. drivers/staging/ccree/ssi_cipher.h | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git

Re: [PATCH] Staging: ccree: Prefer using BIT macro.

2017-09-07 Thread Greg KH
On Thu, Sep 07, 2017 at 07:17:09PM +0530, Srishti Sharma wrote: > Use BIT(x) instead of (1< > Signed-off-by: Srishti Sharma > --- > drivers/staging/ccree/ssi_cipher.h | 10 +- > 1 file changed, 5 insertions(+), 5 deletions(-) > >

[PATCH] Staging: ccree: Prefer using BIT macro.

2017-09-07 Thread Srishti Sharma
Use BIT(x) instead of (1< --- drivers/staging/ccree/ssi_cipher.h | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/staging/ccree/ssi_cipher.h

Re: [PATCH] staging: lustre: avoid going through unlock/lock overhead

2017-09-07 Thread Cihangir Akturk
On Thu, Sep 07, 2017 at 02:33:49PM +0200, Greg KH wrote: > On Thu, Sep 07, 2017 at 01:57:42PM +0300, Cihangir Akturk wrote: > > Unlocking a spin lock and then immediately locking without doing > > anything useful in between buys us nothing, except wasting CPU cycles. > > Not always, it can be a

Re: [PATCH v2 04/11] usb: xhci: Add Intel cherrytrail extended cap / otg phy mux handling

2017-09-07 Thread Mathias Nyman
On 05.09.2017 19:42, Hans de Goede wrote: The Intel cherrytrail xhci controller has an extended cap mmio-range which contains registers to control the muxing to the xhci (host mode) or the dwc3 (device mode) and vbus-detection for the otg usb-phy. Having a mux driver included in the xhci code

Re: [PATCH] staging: lustre: avoid going through unlock/lock overhead

2017-09-07 Thread Greg KH
On Thu, Sep 07, 2017 at 01:57:42PM +0300, Cihangir Akturk wrote: > Unlocking a spin lock and then immediately locking without doing > anything useful in between buys us nothing, except wasting CPU cycles. Not always, it can be a "gate" for other users of the lock. Are you sure that is not what

[PATCH] staging: lustre: avoid going through unlock/lock overhead

2017-09-07 Thread Cihangir Akturk
Unlocking a spin lock and then immediately locking without doing anything useful in between buys us nothing, except wasting CPU cycles. Also code size gets smaller. Before: text data bssdechex filename 70415 2356 4108 76879 12c4f

Re: [PATCH v5] Staging: ccree: Remove unused variable.

2017-09-07 Thread Srishti Sharma
On Thu, Sep 7, 2017 at 2:20 PM, Gilad Ben-Yossef wrote: > Hi, > > On Thu, Sep 7, 2017 at 10:49 AM, Srishti Sharma wrote: >> Remove the local variable inflight_counter as it is never used. >> >> Signed-off-by: Srishti Sharma >>

Re: [PATCH] drivers/staging/rtl8188eu: cleanup crc32_init logic

2017-09-07 Thread Greg Kroah-Hartman
On Thu, Sep 07, 2017 at 10:20:52AM +0530, Pushkar Jambhlekar wrote: > crc32_init is using unnecessary else condition. Cleaningup this function > > Signed-off-by: Pushkar Jambhlekar > --- > drivers/staging/rtl8188eu/core/rtw_security.c | 42 > +-- >

Re: [PATCH 2/3] staging: rtlwifi: use kcalloc instead of multiply

2017-09-07 Thread Greg Kroah-Hartman
On Tue, Sep 05, 2017 at 09:46:34AM -0500, Larry Finger wrote: > On 09/05/2017 01:53 AM, Tobin C. Harding wrote: > > checkpatch emits multiple warnings of type > > > > WARNING:ALLOC_WITH_MULTIPLY: Prefer kcalloc over kzalloc with multiply > > > > Replace two calls to kzalloc() with calls to

Re: [PATCH 3/3] staging: rtlwifi: remove unused functions

2017-09-07 Thread Greg Kroah-Hartman
On Tue, Sep 05, 2017 at 09:46:55AM -0500, Larry Finger wrote: > On 09/05/2017 01:53 AM, Tobin C. Harding wrote: > > Functions rtl_rfreg_delay() and rtl_bb_delay() are unused within the > > driver. Both functions call rtl_addr_delay(), this function is unused > > outside of these call sites.The

[PATCH v3 8/8] staging: ccree: remove BUG macro usage

2017-09-07 Thread Gilad Ben-Yossef
Replace BUG() macro usage that crash the kernel with alternatives that signal error and/or try to recover. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_buffer_mgr.c | 18 ++ drivers/staging/ccree/ssi_cipher.c | 1 -

[PATCH v3 6/8] staging: ccree: move over to BIT macro for bit defines

2017-09-07 Thread Gilad Ben-Yossef
Use BIT macro for bit definitions where needed. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_cipher.h | 10 +- drivers/staging/ccree/ssi_driver.c | 3 ++- drivers/staging/ccree/ssi_driver.h | 6 +++--- 3 files changed, 10 insertions(+), 9

[PATCH v3 7/8] staging: ccree: replace noop macro with inline

2017-09-07 Thread Gilad Ben-Yossef
Replace noop macro with a noop inline function Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_driver.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/staging/ccree/ssi_driver.h b/drivers/staging/ccree/ssi_driver.h index

[PATCH v3 4/8] staging: ccree: simplify resource release on error

2017-09-07 Thread Gilad Ben-Yossef
The resource release on probe/init error was being handled in an awkward manner and possibly leaking memory on certain (unlikely) error path. Fix it by simplifying the error resource release and making it easier to track. Reported-by: Dan Carpenter Signed-off-by: Gilad

[PATCH v3 0/8] staging: ccree: more cleanup work for 4.15

2017-09-07 Thread Gilad Ben-Yossef
More cleanup work from Sunil and myself. I've previously sent some of these as part of a larger patch set. I've decided to split the patch set to smaller chunks to make it more manageable. This patch set applies on top of commit 28eb51f7468a ("staging:rtl8188eu:core Fix remove unneccessary else

[PATCH v3 3/8] staging: ccree: Use platform_get_irq and devm_request_irq

2017-09-07 Thread Gilad Ben-Yossef
From: Suniel Mahesh It is recommended to use managed function devm_request_irq(), which simplifies driver cleanup paths and driver code. This patch does the following: (a) replace platform_get_resource(), request_irq() and corresponding error handling with

[PATCH v3 5/8] staging: ccree: remove unused completion

2017-09-07 Thread Gilad Ben-Yossef
icache_setup_completion is no longer used. Remove it. Signed-off-by: Gilad Ben-Yossef --- drivers/staging/ccree/ssi_driver.c | 2 -- drivers/staging/ccree/ssi_driver.h | 1 - 2 files changed, 3 deletions(-) diff --git a/drivers/staging/ccree/ssi_driver.c

[PATCH v3 1/8] staging: ccree: Replace kzalloc with devm_kzalloc

2017-09-07 Thread Gilad Ben-Yossef
From: Suniel Mahesh It is recommended to use managed function devm_kzalloc, which simplifies driver cleanup paths and driver code. This patch does the following: (a) replace kzalloc with devm_kzalloc. (b) drop kfree(), because memory allocated with devm_kzalloc() is

[PATCH v3 2/8] staging: ccree: Convert to devm_ioremap_resource for map, unmap

2017-09-07 Thread Gilad Ben-Yossef
From: Suniel Mahesh It is recommended to use managed function devm_ioremap_resource(), which simplifies driver cleanup paths and driver code. This patch does the following: (a) replace request_mem_region(), ioremap() and corresponding error handling with

Re: [PATCH 8/8] staging: ccree: remove BUG macro usage

2017-09-07 Thread Gilad Ben-Yossef
On Wed, Sep 6, 2017 at 10:28 PM, Dan Carpenter wrote: > On Sun, Sep 03, 2017 at 11:56:50AM +0300, Gilad Ben-Yossef wrote: >> @@ -1154,7 +1150,8 @@ static inline int ssi_buffer_mgr_aead_chain_data( >> //if have reached the end of the sgl, then this is

Re: [PATCH v5] Staging: ccree: Remove unused variable.

2017-09-07 Thread Gilad Ben-Yossef
Hi, On Thu, Sep 7, 2017 at 10:49 AM, Srishti Sharma wrote: > Remove the local variable inflight_counter as it is never used. > > Signed-off-by: Srishti Sharma > --- I've been meaning to clean that for some time now and never got around to do it.

Re: [Outreachy kernel] [PATCH v5] Staging: ccree: Remove unused variable.

2017-09-07 Thread Julia Lawall
On Thu, 7 Sep 2017, Srishti Sharma wrote: > Remove the local variable inflight_counter as it is never used. > > Signed-off-by: Srishti Sharma Acked-by: Julia Lawall > --- > Changes in v5: > - Correct the format of the subject. >

Re: [PATCH v5] Staging: ccree: Remove unused variable.

2017-09-07 Thread Dan Carpenter
Looks good. Thanks! regards, dan carpenter ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

[PATCH v5] Staging: ccree: Remove unused variable.

2017-09-07 Thread Srishti Sharma
Remove the local variable inflight_counter as it is never used. Signed-off-by: Srishti Sharma --- Changes in v5: - Correct the format of the subject. drivers/staging/ccree/ssi_cipher.c | 3 --- 1 file changed, 3 deletions(-) diff --git

Re: [Outreachy kernel] [PATCH v4] Staging: ccree: ssi_cipher.c: Remove unused variable.

2017-09-07 Thread Srishti Sharma
On Thu, Sep 7, 2017 at 12:24 PM, Julia Lawall wrote: > One last detail. The subject line above is not in the same format as that > of all of the other subject lines one commits affecting this file. You > can use git log --oneline to see what others have done. It is not

Re: [Outreachy kernel] [PATCH v4] Staging: ccree: ssi_cipher.c: Remove unused variable.

2017-09-07 Thread Julia Lawall
One last detail. The subject line above is not in the same format as that of all of the other subject lines one commits affecting this file. You can use git log --oneline to see what others have done. It is not really possible to guess correctly. However, one does not generally include the

Re: [PATCH v3] Staging: ccree: ssi_cipher.c: Remove unused variable.

2017-09-07 Thread Joe Perches
On Thu, 2017-09-07 at 00:32 +0300, Dan Carpenter wrote: > Always compile your patches. > > CC [M] drivers/staging/ccree/ssi_cipher.o > drivers/staging/ccree/ssi_cipher.c: In function ‘ssi_blkcipher_complete’: > drivers/staging/ccree/ssi_cipher.c:700:6: warning: unused variable >