Re: [PATCH net] staging: Remove set but not used variable ‘status’

2019-05-25 Thread maowenan
On 2019/5/25 13:01, Greg KH wrote: > On Sat, May 25, 2019 at 12:26:42PM +0800, Mao Wenan wrote: >> Fixes gcc '-Wunused-but-set-variable' warning: >> >> drivers/staging/kpc2000/kpc_spi/spi_driver.c: In function >> ‘kp_spi_transfer_one_message’: >>

Re: [PATCH v5 1/4] media: v4l: Add definitions for the HEVC slice controls

2019-05-25 Thread Hans Verkuil
Hi Paul, This patch is missing your Signed-of-by line! Can you reply with your SoB? Regards, Hans On 5/24/19 11:36 AM, Paul Kocialkowski wrote: > This introduces the required definitions for HEVC decoding support with > stateless VPUs. The controls associated to the HEVC slice format

Re: [PATCH v5 1/4] media: v4l: Add definitions for the HEVC slice controls

2019-05-25 Thread Hans Verkuil
Hi Paul, Besides the missing SoB I have two more comments: On 5/24/19 11:36 AM, Paul Kocialkowski wrote: > This introduces the required definitions for HEVC decoding support with > stateless VPUs. The controls associated to the HEVC slice format provide > the required meta-data for decoding

Re: [PATCH] staging: kpc2000: simplify nested conditionals that just return a boolean.

2019-05-25 Thread Dan Carpenter
On Fri, May 24, 2019 at 01:19:26PM +0100, Jeremy Sowden wrote: > kp2000_check_uio_irq contained a pair of nested ifs which each evaluated > a bitwise operation. If both operations yielded true, the function > returned 1; otherwise it returned 0. > > Replaced the whole thing with one return

[PATCH -next] staging: rtl8723bs: hal: Remove set but not used variable 'no_res' and 'phal'

2019-05-25 Thread YueHaibing
Fixes gcc '-Wunused-but-set-variable' warning: drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c: In function xmit_xmitframes: drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c:205:5: warning: variable no_res set but not used [-Wunused-but-set-variable] drivers/staging/rtl8723bs/hal/rtl8723bs_xmit.c:

Re: [PATCH v5 3/4] media: pixfmt: Document the HEVC slice pixel format

2019-05-25 Thread Hans Verkuil
On 5/24/19 11:36 AM, Paul Kocialkowski wrote: > Document the current state of the HEVC slice pixel format. > The format will need to evolve in the future, which is why it is > not part of the public API. > > Signed-off-by: Paul Kocialkowski > --- > .../media/uapi/v4l/pixfmt-compressed.rst

Re: [PATCH v5 1/4] media: v4l: Add definitions for the HEVC slice controls

2019-05-25 Thread Paul Kocialkowski
Hi Hans, On Sat, 2019-05-25 at 13:08 +0200, Hans Verkuil wrote: > Hi Paul, > > This patch is missing your Signed-of-by line! Can you reply with your SoB? Ouch, sorry about that. This is definitely: Signed-off-by: Paul Kocialkowski Cheers, Paul > Regards, > > Hans > > On 5/24/19

[PATCH -next v2] staging: kpc2000: Remove set but not used variable ‘status’

2019-05-25 Thread Mao Wenan
Fixes gcc '-Wunused-but-set-variable' warning: drivers/staging/kpc2000/kpc_spi/spi_driver.c: In function ‘kp_spi_transfer_one_message’: drivers/staging/kpc2000/kpc_spi/spi_driver.c:282:9: warning: variable ‘status’ set but not used [-Wunused-but-set-variable] int status = 0; ^~

Re: [PATCH 2/2] staging: kpc2000: add missing dependencies for kpc2000

2019-05-25 Thread Simon Sandström
On Sat, May 25, 2019 at 07:00:17AM +0200, Greg KH wrote: > On Fri, May 24, 2019 at 10:30:58PM +0200, Simon Sandström wrote: > > Fixes build errors: > > > > ERROR: "mfd_remove_devices" [kpc2000.ko] undefined! > > ERROR: "uio_unregister_device" [kpc2000.ko] undefined! > > ERROR: "mfd_add_devices"

Re: [PATCH net] staging: Remove set but not used variable ‘status’

2019-05-25 Thread Sven Van Asbroeck
On Sat, May 25, 2019 at 12:20 AM Mao Wenan wrote: > > The variable 'status' is not used any more, remve it. > /* do the transfers for this message */ > list_for_each_entry(transfer, >transfers, transfer_list) { > if (transfer->tx_buf == NULL && transfer->rx_buf == NULL && >

Re: [PATCH 2/2] staging: gdm724x: Remove variable

2019-05-25 Thread Sven Van Asbroeck
On Fri, May 24, 2019 at 2:04 AM Nishka Dasgupta wrote: > > The return variable is used only twice (in two different branches), and > both times it is assigned the same constant value. These can therefore > be merged into the same assignment, placed at the point that both > these branches (and no

Re: [PATCH 2/2] staging: kpc2000: add missing dependencies for kpc2000

2019-05-25 Thread Simon Sandström
On Sat, May 25, 2019 at 10:39:18AM +0200, Simon Sandström wrote: > On Sat, May 25, 2019 at 07:00:17AM +0200, Greg KH wrote: > > > > This is already in linux-next (in a different form), are you sure you > > are working against the latest kernel tree? > > > > thanks, > > > > greg k-h > > It's

Re: [PATCH v5 2/4] media: pixfmt: Add HEVC slice pixel format

2019-05-25 Thread Jernej Škrabec
Hi! Dne petek, 24. maj 2019 ob 11:36:33 CEST je Paul Kocialkowski napisal(a): > Introduce the V4L2_PIX_FMT_HEVC_SLICE pixel format, which currently > describes an output buffer with enough appended slice data for > producing one decoded frame with a stateless video decoder. > > This will need to

[PATCH] Staging: rtl8723bs: hal: fix warning possible condition with no effect (if == else)

2019-05-25 Thread Hariprasad Kelam
this patch fixes below coccicheck warning ./drivers/staging/rtl8723bs/hal/odm_DIG.c:499:1-3: WARNING: possible condition with no effect (if == else) Signed-off-by: Hariprasad Kelam --- drivers/staging/rtl8723bs/hal/odm_DIG.c | 9 ++--- 1 file changed, 2 insertions(+), 7 deletions(-) diff

[PATCH 8/8] staging: kpc2000: kpc_i2c: Use devm_* API to manage mapped I/O space

2019-05-25 Thread Geordan Neukum
The kpc_i2c driver does not unmap its I/O space upon error cases in the probe() function or upon remove(). Make the driver clean up after itself more maintainably by using the managed resource API. Signed-off-by: Geordan Neukum --- drivers/staging/kpc2000/kpc2000_i2c.c | 4 +++- 1 file changed,

[PATCH 7/8] staging: kpc2000: kpc_i2c: fail probe if unable to map I/O space

2019-05-25 Thread Geordan Neukum
The kpc2000 driver does not verify whether or not mapping the I/O space succeeded during probe time. Make the driver verify that the mapping operation was successful before potentially using that area in the future. Signed-off-by: Geordan Neukum --- drivers/staging/kpc2000/kpc2000_i2c.c | 2 ++

[PATCH 6/8] staging: kpc2000: kpc_i2c: fail probe if unable to get I/O resource

2019-05-25 Thread Geordan Neukum
The kpc_i2c driver attempts to map its I/O space without verifying whether or not the result of platform_get_resource() is NULL. Make the driver check that platform_get_resource did not return NULL before attempting to use the value returned to map an I/O space. Signed-off-by: Geordan Neukum ---

[PATCH 2/8] staging: kpc2000: kpc_i2c: Remove pldev from i2c_device structure

2019-05-25 Thread Geordan Neukum
The i2c_device structure contains a member used to stash a pointer to a platform_device. The driver contains no cases of this member being used after initialization. Remove the unnecessary struct member and the initialization of this member in the sole instance where the driver creates a variable

[PATCH 4/8] staging: kpc2000: kpc_i2c: Remove unnecessary consecutive newlines

2019-05-25 Thread Geordan Neukum
The kpc2000_i2c.c file contains instances of unnecessary consecutive newlines which impact the readability of the file. Remove these unnecessary newlines. Signed-off-by: Geordan Neukum --- drivers/staging/kpc2000/kpc2000_i2c.c | 5 - 1 file changed, 5 deletions(-) diff --git

[PATCH 1/8] staging: kpc2000: kpc_i2c: Remove unused rw_sem

2019-05-25 Thread Geordan Neukum
In pi2c_probe, a rw_sem is initialized and stashed off in the i2c_device private runtime state struct. This rw_sem is never used after initialization. Remove the rw_sem and cleanup unneeded header inclusion. Signed-off-by: Geordan Neukum --- drivers/staging/kpc2000/kpc2000_i2c.c | 3 --- 1 file

[PATCH 5/8] staging: kpc2000: kpc_i2c: Use drvdata instead of platform_data

2019-05-25 Thread Geordan Neukum
The kpc_i2c driver stashes private state data in the platform_data member of its device structure. In general, the platform_data structure is used for passing data to the driver during probe() rather than as a storage area for runtime state data. Instead, use the drvdata member for all state info

[PATCH 3/8] staging: kpc2000: kpc_i2c: Use BIT macro rather than manual bit shifting

2019-05-25 Thread Geordan Neukum
The FEATURES_* symbols use bit shifting of the style (1 << k) in order to assign a certain meaning to the value of inividual bits being set in the value of a given variable. Instead, use the BIT() macro in order to improve readability and maintain consistency with the rest of the kernel.

[PATCH 0/8] staging: kpc2000: kpc_i2c: assorted driver cleanup

2019-05-25 Thread Geordan Neukum
This series contains some patches aimed toward: - cleaning up unused/unneeded parts of driver state - a couple of small style fixups - a couple of API changes - better error handling in probe() in the kpc2000 i2c driver. Geordan Neukum (8): staging: kpc2000: kpc_i2c: Remove unused rw_sem