[PATCH] staging: rtl8188eu: clean up some declarations

2020-05-24 Thread Michael Straube
Clean up some array declarations in phy_iq_calibrate() to reduce indentation and clear line over 80 characters checkpatch warnings. Signed-off-by: Michael Straube --- drivers/staging/rtl8188eu/hal/phy.c | 33 +++-- 1 file changed, 17 insertions(+), 16 deletions(-) diff -

[PATCH] staging/rtl8192e: Remove function callback casts

2020-05-24 Thread Oscar Carter
In an effort to enable -Wcast-function-type in the top-level Makefile to support Control Flow Integrity builds, remove all the function callback casts. To do this modify the function prototypes accordingly. Signed-off-by: Oscar Carter --- drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 24 ++

Re: [PATCH] staging: rtl8188eu: clean up some declarations

2020-05-24 Thread Joe Perches
On Sun, 2020-05-24 at 10:27 +0200, Michael Straube wrote: > Clean up some array declarations in phy_iq_calibrate() to reduce > indentation and clear line over 80 characters checkpatch warnings. Better still would be to mark these as static const and also mark the functions that use them to take co

[PATCH v2 2/2] staging: rtl8188eu: make some arrays static const

2020-05-24 Thread Michael Straube
Make some arrays in phy_iq_calibrate() static const and adjust the functions that take these arrays as parameters accordingly. Reduces object file size by 84 bytes (GCC 9.3.1 x86_64). Suggested-by: Joe Perches Signed-off-by: Michael Straube --- drivers/staging/rtl8188eu/hal/phy.c | 21 +

[PATCH v2 1/2] staging: rtl8188eu: clean up some declarations

2020-05-24 Thread Michael Straube
Clean up some array declarations in phy_iq_calibrate() to reduce indentation and clear line over 80 characters checkpatch warnings. Signed-off-by: Michael Straube --- v1 -> v2 Added patch that makes arrays static const. drivers/staging/rtl8188eu/hal/phy.c | 33 +++-- 1 f

[staging:staging-testing 319/378] drivers/staging/vt6656/rxtx.c:42:18: warning: unused variable 'vnt_frame_time'

2020-05-24 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git staging-testing head: a3975dea1696b7c81319dc4b66e3c378dd47ccfb commit: 61bb798767e4a55165ab0cdaf72dd7459ebab0cc [319/378] staging: vt6656: vnt_get_rtscts_rsvtime_le replace with rts/cts duration. config: x86_64-allyescon

[PATCH] Removing ununsed variable int lo, hi, int data and int i from comedi/drivers/dt2814.c.

2020-05-24 Thread Gaurav Pathak
Silence following sparse warning: drivers/staging/comedi/drivers/dt2814.c: In function ‘dt2814_interrupt’: drivers/staging/comedi/drivers/dt2814.c:193:6: warning: variable ‘data’ set but not used [-Wunused-but-set-variable] int data; ^~~~ drivers/staging/comedi/drivers/dt2814.c: In functio

Re: [PATCH] Removing ununsed variable int lo, hi, int data and int i from comedi/drivers/dt2814.c.

2020-05-24 Thread Luc Van Oostenryck
Hi, On Sun, May 24, 2020 at 05:06:18PM +0530, Gaurav Pathak wrote: > Silence following sparse warning: > drivers/staging/comedi/drivers/dt2814.c: In function ‘dt2814_interrupt’: > drivers/staging/comedi/drivers/dt2814.c:193:6: warning: variable ‘data’ set > but not used [-Wunused-but-set-variable

Re: [PATCH v2 2/2] staging: rtl8188eu: make some arrays static const

2020-05-24 Thread Joe Perches
On Sun, 2020-05-24 at 12:15 +0200, Michael Straube wrote: > Make some arrays in phy_iq_calibrate() static const and adjust > the functions that take these arrays as parameters accordingly. > Reduces object file size by 84 bytes (GCC 9.3.1 x86_64). You could also do drivers/net/wireless/realtek/rtl

Re: [PATCH] Removing ununsed variable int lo, hi, int data and int i from comedi/drivers/dt2814.c.

2020-05-24 Thread GAURAV PATHAK
Nevermind, my sparse version was broken. Installed sparse 0.6.1, but still no warnings from sparse in any of the directories in drivers staging. E.g.: make C=2 M=drivers/staging/sm750fb CHECK drivers/staging/sm750fb/sm750.c CHECK drivers/staging/sm750fb/sm750_hw.c CHECK drivers/stagin

Re: [PATCH] Removing ununsed variable int lo, hi, int data and int i from comedi/drivers/dt2814.c.

2020-05-24 Thread Luc Van Oostenryck
On Sun, May 24, 2020 at 06:19:22PM +0530, GAURAV PATHAK wrote: > Thanks a lot for your reply. > I am trying to run sparse on drivers/staging directory, > but I am not getting any useful warnings. > Steps that I did: > > - Referred https://www.kernel.org/doc/man-pages/linux-next.html to get > linux

Re: [PATCH] Removing ununsed variable int lo, hi, int data and int i from comedi/drivers/dt2814.c.

2020-05-24 Thread Luc Van Oostenryck
On Sun, May 24, 2020 at 07:02:20PM +0530, GAURAV PATHAK wrote: > > For few drivers, I am getting: > > CC [M] drivers/staging/vt6656/key.o > CHECK drivers/staging/vt6656/rf.c > /usr/lib/gcc/x86_64-linux-gnu/7/include/stddef.h:417:9: warning: preprocessor > token offsetof redefined > ./includ

Re: [PATCH 1/5] iio: core: pass parent device as parameter during allocation

2020-05-24 Thread Jonathan Cameron
On Fri, 22 May 2020 11:56:40 +0300 Andy Shevchenko wrote: > On Fri, May 22, 2020 at 11:36 AM Alexandru Ardelean > wrote: > > > > The change passes the parent device to the iio_device_alloc() call. This > > also updates the devm_iio_device_alloc() call to consider the device object > > as the par

[PATCH] staging: greybus: loopback: fix a spelling error.

2020-05-24 Thread Till Varoquaux
Successed -> succeeded. Signed-off-by: Till Varoquaux --- drivers/staging/greybus/loopback.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/greybus/loopback.c b/drivers/staging/greybus/loopback.c index 583d9708a191..2471448ba42a 100644 --- a/drivers/staging

[PATCH 03/11] media: atomisp: avoid a copy of v4l2_mbus_framefmt at stack

2020-05-24 Thread Mauro Carvalho Chehab
There's no reason to copy isp_sink_fmt, as the driver uses it for read-only purposes. Linux stack is a precious resource. Let's avoid wasting it. Signed-off-by: Mauro Carvalho Chehab --- drivers/staging/media/atomisp/pci/atomisp_cmd.c | 10 +- 1 file changed, 5 insertions(+), 5 deletion

[PATCH 02/11] media: atomisp: reduce debug printk rate when IRQs are received

2020-05-24 Thread Mauro Carvalho Chehab
Currently, when an EOF IRQ is received, it generates two messages: [ 59.191893] atomisp-isp2 :00:03.0: irq:0x20 [ 59.191913] atomisp-isp2 :00:03.0: atomisp_isr EOF exp_id 142, asd 0 Flooding the dmesg with lots of messages per second. The same pattern happens for

[PATCH 06/11] media: atomisp: update TODO list

2020-05-24 Thread Mauro Carvalho Chehab
Let's reflect the current status at the TODO list, as other developers can help addressing issues over there. Signed-off-by: Mauro Carvalho Chehab --- drivers/staging/media/atomisp/TODO | 188 ++--- 1 file changed, 142 insertions(+), 46 deletions(-) diff --git a/drivers/

[PATCH 11/11] media: atomisp: fix size of delay_frames array

2020-05-24 Thread Mauro Carvalho Chehab
Right now, the variables that define the max number of delay frames is defined as: #define VIDEO_FRAME_DELAY 2 #define MAX_NUM_VIDEO_DELAY_FRAMES (VIDEO_FRAME_DELAY + 1) #define NUM_PREVIEW_DVS_FRAMES (2) #define MAX_NUM_DELAY_FRAMES MA

[PATCH 10/11] media: atomisp: drop a cast for a const argument

2020-05-24 Thread Mauro Carvalho Chehab
Some arguments for tnf and ref settings are meant to be const, but they're defined without such annotation. Due to that, there's an ugly cast at sh_css_sp.c. Signed-off-by: Mauro Carvalho Chehab --- .../atomisp/pci/isp/kernels/ref/ref_1.0/ia_css_ref.host.c | 2 +- .../atomisp/pci/isp/kernels

[PATCH 07/11] media: atomisp: get rid of some old broken debug code

2020-05-24 Thread Mauro Carvalho Chehab
It sounds that someone once changed the debug level at compile time for some testing, but forgot to remove the legacy code after finishing debuging it. Get rid of the dead code. Signed-off-by: Mauro Carvalho Chehab --- drivers/staging/media/atomisp/pci/atomisp_cmd.c | 3 --- 1 file changed, 3 d

[PATCH 00/11] Some fixes and cleanups for atomisp driver

2020-05-24 Thread Mauro Carvalho Chehab
The atomisp driver has lots of issues. This series get rid of a few of them and updates the TODO list to reflect the current status and provide more details aboug some items. Mauro Carvalho Chehab (11): media: atomisp: get rid of hmm_vm.c media: atomisp: reduce debug printk rate when IRQs are

[PATCH 01/11] media: atomisp: get rid of hmm_vm.c

2020-05-24 Thread Mauro Carvalho Chehab
This is not used anywhere. So, let's trash it. Signed-off-by: Mauro Carvalho Chehab --- drivers/staging/media/atomisp/Makefile| 1 - .../media/atomisp/include/hmm/hmm_vm.h| 65 - .../media/atomisp/pci/hmm/hmm_dynamic_pool.c | 233 -- .../staging/media/atom

[PATCH 08/11] media: atomisp: make it use dbg_level to control debug level

2020-05-24 Thread Mauro Carvalho Chehab
This driver has 3 different types of debug messages: - dev_dbg() - dbg_level - ia_css_debug_trace_level Which is crazy. Ideally, it shold just use dev_dbg() everywhere, but for now let's unify the last two machanisms. Signed-off-by: Mauro Carvalho Chehab --- drivers/sta

[PATCH 05/11] media: atomisp: don't flood dmesg with -EAGAIN return codes

2020-05-24 Thread Mauro Carvalho Chehab
Using DQBUF on non-blocking mode will return -EAGAIN if nothing arrives. Printing it has no value, even for debug purposes. So, only display real return codes. Signed-off-by: Mauro Carvalho Chehab --- drivers/staging/media/atomisp/pci/atomisp_ioctl.c | 3 ++- 1 file changed, 2 insertions(+), 1 d

[PATCH 04/11] media: atomisp: improve debug messages for set format

2020-05-24 Thread Mauro Carvalho Chehab
There are several error conditions that don't print anything, making harder to identify bugs at the code there. Signed-off-by: Mauro Carvalho Chehab --- .../staging/media/atomisp/pci/atomisp_cmd.c | 31 +-- 1 file changed, 22 insertions(+), 9 deletions(-) diff --git a/drivers/