[PATCH 04/12] cx231xx: give each master i2c bus a seperate name

2014-09-24 Thread Matthias Schwarzott
Signed-off-by: Matthias Schwarzott --- drivers/media/usb/cx231xx/cx231xx-i2c.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/media/usb/cx231xx/cx231xx-i2c.c b/drivers/media/usb/cx231xx/cx231xx-i2c.c index a30d400..178fa48 100644 --- a/drivers/media/usb/cx231xx/cx231xx-i2c.c ++

[PATCH 02/12] cx231xx: use own i2c_client for eeprom access

2014-09-24 Thread Matthias Schwarzott
Signed-off-by: Matthias Schwarzott --- drivers/media/usb/cx231xx/cx231xx-cards.c | 24 +--- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/drivers/media/usb/cx231xx/cx231xx-cards.c b/drivers/media/usb/cx231xx/cx231xx-cards.c index 791f00c..092fb85 100644 ---

[PATCH 07/12] cx231xx: remember status of port_3 switch

2014-09-24 Thread Matthias Schwarzott
Is remembering stable enough, or must this state be queried from the register when needed. Signed-off-by: Matthias Schwarzott --- drivers/media/usb/cx231xx/cx231xx-avcore.c | 3 +++ drivers/media/usb/cx231xx/cx231xx.h| 1 + 2 files changed, 4 insertions(+) diff --git a/drivers/media/us

[PATCH 05/12] cx231xx: Use symbolic constants for i2c ports

2014-09-24 Thread Matthias Schwarzott
use already existing I2C_0 ... I2C_3 Signed-off-by: Matthias Schwarzott --- drivers/media/usb/cx231xx/cx231xx-cards.c | 62 +++ drivers/media/usb/cx231xx/cx231xx.h | 8 ++-- 2 files changed, 35 insertions(+), 35 deletions(-) diff --git a/drivers/media/usb/cx23

[PATCH 12/12] cx231xx: scan all four existing i2c busses instead of the 3 masters

2014-09-24 Thread Matthias Schwarzott
Signed-off-by: Matthias Schwarzott --- drivers/media/usb/cx231xx/cx231xx-core.c | 6 ++ drivers/media/usb/cx231xx/cx231xx-i2c.c | 8 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/drivers/media/usb/cx231xx/cx231xx-core.c b/drivers/media/usb/cx231xx/cx231xx-core.c i

[PATCH 11/12] cx231xx: drop unconditional port3 switching

2014-09-24 Thread Matthias Schwarzott
All switching should be done by i2c mux adapters. Drop explicit dont_use_port_3 flag. Drop info message about switch. Only the removed code in start_streaming is questionable: It did switch the port_3 flag without accessing i2c in between. Signed-off-by: Matthias Schwarzott --- drivers/media/us

[PATCH 10/12] cx231xx: register i2c mux adapters for master1 and use as I2C_1 and I2C_3

2014-09-24 Thread Matthias Schwarzott
Signed-off-by: Matthias Schwarzott --- drivers/media/usb/cx231xx/Kconfig| 1 + drivers/media/usb/cx231xx/cx231xx-core.c | 5 drivers/media/usb/cx231xx/cx231xx-i2c.c | 45 ++-- drivers/media/usb/cx231xx/cx231xx.h | 4 +++ 4 files changed, 53 insert

[PATCH 08/12] cx231xx: let is_tuner check the real i2c port and not the i2c master number

2014-09-24 Thread Matthias Schwarzott
get used i2c port from bus_nr and status of port_3 switch Signed-off-by: Matthias Schwarzott --- drivers/media/usb/cx231xx/cx231xx-i2c.c | 11 ++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/drivers/media/usb/cx231xx/cx231xx-i2c.c b/drivers/media/usb/cx231xx/cx231xx-i2

[PATCH 03/12] cx231xx: delete i2c_client per bus

2014-09-24 Thread Matthias Schwarzott
Signed-off-by: Matthias Schwarzott --- drivers/media/usb/cx231xx/cx231xx-i2c.c | 7 --- drivers/media/usb/cx231xx/cx231xx.h | 1 - 2 files changed, 8 deletions(-) diff --git a/drivers/media/usb/cx231xx/cx231xx-i2c.c b/drivers/media/usb/cx231xx/cx231xx-i2c.c index 67a1391..a30d400 100644

[PATCH 06/12] cx231xx: add wrapper to get the i2c_adapter pointer

2014-09-24 Thread Matthias Schwarzott
Already map unused I2C_3 to adapter number 1 to prepare for switching. Add local variables for i2c_adapters in dvb_init to get line lengths shorter. Signed-off-by: Matthias Schwarzott --- drivers/media/usb/cx231xx/cx231xx-cards.c | 8 +++--- drivers/media/usb/cx231xx/cx231xx-dvb.c | 42 +

[PATCH 09/12] cx231xx: change usage of I2C_1 to the real i2c port

2014-09-24 Thread Matthias Schwarzott
change almost all instances of I2C_1 to I2C_3 Keep I2C_1 for these cases: * All that have dont_use_port_3 set. * CX231XX_BOARD_HAUPPAUGE_EXETER, old code did explicitly not switch to port3. * eeprom access for 930C Signed-off-by: Matthias Schwarzott --- drivers/media/usb/cx231xx/cx231xx-cards.c

[PATCH 01/12] cx231xx: let i2c bus scanning use its own i2c_client

2014-09-24 Thread Matthias Schwarzott
Signed-off-by: Matthias Schwarzott --- drivers/media/usb/cx231xx/cx231xx-i2c.c | 17 +++-- drivers/media/usb/cx231xx/cx231xx.h | 2 +- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/drivers/media/usb/cx231xx/cx231xx-i2c.c b/drivers/media/usb/cx231xx/cx231xx-i2c.

[PATCH v2] [media] videobuf-dma-contig: set vm_pgoff to be zero to pass the sanity check in vm_iomap_memory().

2014-09-24 Thread Fancy Fang
When user requests V4L2_MEMORY_MMAP type buffers, the videobuf-core will assign the corresponding offset to the 'boff' field of the videobuf_buffer for each requested buffer sequentially. Later, user may call mmap() to map one or all of the buffers with the 'offset' parameter which is equal to its

[PATCH v2] [media] videobuf-dma-contig: set vm_pgoff to be zero to pass the sanity check in vm_iomap_memory().

2014-09-24 Thread Fancy Fang
When user requests V4L2_MEMORY_MMAP type buffers, the videobuf-core will assign the corresponding offset to the 'boff' field of the videobuf_buffer for each requested buffer sequentially. Later, user may call mmap() to map one or all of the buffers with the 'offset' parameter which is equal to its

cron job: media_tree daily build: ERRORS

2014-09-24 Thread Hans Verkuil
This message is generated daily by a cron job that builds media_tree for the kernels and architectures in the list below. Results of the daily build of media_tree: date: Thu Sep 25 04:00:18 CEST 2014 git branch: test git hash: c0aaf696d45e2a72048a56441e81dad78659c698 gcc versi

RE: [PATCH] [media] videobuf-dma-contig: replace vm_iomap_memory() with remap_pfn_range().

2014-09-24 Thread chen.f...@freescale.com
Thanks for your idea, Marek and Hans. This change makes sense. And I've already verified it. I'll resubmit my change soon. Best regards, Fancy Fang -Original Message- From: Hans Verkuil [mailto:hverk...@xs4all.nl] Sent: Wednesday, September 24, 2014 8:43 PM To: Marek Szyprowski; Fang Che

RE: [PATCH] [media] videobuf-dma-contig: replace vm_iomap_memory() with remap_pfn_range().

2014-09-24 Thread chen.f...@freescale.com
Thanks for your idea, Marek and Hans. This change makes sense. And I've already verified it. I'll resubmit my change soon. Best regards, Fancy Fang -Original Message- From: Hans Verkuil [mailto:hverk...@xs4all.nl] Sent: Wednesday, September 24, 2014 8:43 PM To: Marek Szyprowski; Fang Che

[PATCH] [media] exynos4-is: fix some warnings when compiling on arm64

2014-09-24 Thread Mauro Carvalho Chehab
Got those warnings when compiling with gcc 4.9.1 for arm64: drivers/media/platform/exynos4-is/fimc-isp-video.c: In function ‘isp_video_capture_buffer_queue’: drivers/media/platform/exynos4-is/fimc-isp-video.c:221:4: warning: format ‘%x’ expects argument of type ‘unsigned int’, but argument 7 has

Re: [PATCH 01/18] [media] ir-hix5hd2: fix address space casting

2014-09-24 Thread zhangfei
On 09/25/2014 06:27 AM, Mauro Carvalho Chehab wrote: drivers/media/rc/ir-hix5hd2.c:99:41: warning: incorrect type in argument 2 (different address spaces) drivers/media/rc/ir-hix5hd2.c:99:41:expected void volatile [noderef] *addr drivers/media/rc/ir-hix5hd2.c:99:41:got void * drivers/

[PATCH 2/3] [media] pci drivers: use %zu instead of %zd

2014-09-24 Thread Mauro Carvalho Chehab
size_t is unsigned. Signed-off-by: Mauro Carvalho Chehab diff --git a/drivers/media/pci/cx18/cx18-alsa-pcm.c b/drivers/media/pci/cx18/cx18-alsa-pcm.c index 180077c49123..ffb6acdc575f 100644 --- a/drivers/media/pci/cx18/cx18-alsa-pcm.c +++ b/drivers/media/pci/cx18/cx18-alsa-pcm.c @@ -80,7 +80,7

[PATCH 3/3] [media] usb drivers: use %zu instead of %zd

2014-09-24 Thread Mauro Carvalho Chehab
size_t is unsigned. Signed-off-by: Mauro Carvalho Chehab diff --git a/drivers/media/usb/cx231xx/cx231xx-avcore.c b/drivers/media/usb/cx231xx/cx231xx-avcore.c index 51872b9f75a1..40a69879fc0a 100644 --- a/drivers/media/usb/cx231xx/cx231xx-avcore.c +++ b/drivers/media/usb/cx231xx/cx231xx-avcore.c

[PATCH 1/3] [media] dvb-frontends: use %zu instead of %zd

2014-09-24 Thread Mauro Carvalho Chehab
size_t is unsigned. Signed-off-by: Mauro Carvalho Chehab diff --git a/drivers/media/dvb-frontends/bcm3510.c b/drivers/media/dvb-frontends/bcm3510.c index 998d15031461..638c7aa0fb7e 100644 --- a/drivers/media/dvb-frontends/bcm3510.c +++ b/drivers/media/dvb-frontends/bcm3510.c @@ -639,7 +639,7 @@

Re: [PATCH 15/18] [media] s5p_mfc_opr: Fix warnings

2014-09-24 Thread Mauro Carvalho Chehab
Em Wed, 24 Sep 2014 20:02:19 -0300 Fabio Estevam escreveu: > Hi Mauro, > > On Wed, Sep 24, 2014 at 7:27 PM, Mauro Carvalho Chehab > wrote: > > > > drivers/media//platform/s5p-mfc/s5p_mfc_opr.c:44:2: warning: format ‘%d’ > > expects argument of type ‘int’, but argument 4 has type ‘size_t’ [-W

[PATCHv2 2/2] [media] s5p-mfc: Fix several printk warnings

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/platform/s5p-mfc/s5p_mfc_ctrl.c:192:3: warning: format ‘%x’ expects argument of type ‘unsigned int’, but argument 4 has type ‘dma_addr_t’ [-Wformat=] drivers/media/platform/s5p-mfc/s5p_mfc_ctrl.c:196:3: warning: format ‘%x’ expects argument of type ‘unsigned int’, but argument 4 ha

[PATCHv2 1/2] [media] s5p_mfc_opr: Fix warnings

2014-09-24 Thread Mauro Carvalho Chehab
CC drivers/media//platform/s5p-mfc/s5p_mfc_opr.o drivers/media//platform/s5p-mfc/s5p_mfc_opr.c: In function ‘s5p_mfc_alloc_priv_buf’: drivers/media//platform/s5p-mfc/s5p_mfc_opr.c:44:2: warning: format ‘%d’ expects argument of type ‘int’, but argument 4 has type ‘size_t’ [-Wformat=] mfc_

Re: [PATCH 09/18] [media] cx88: remove return after BUG()

2014-09-24 Thread Mauro Carvalho Chehab
Em Thu, 25 Sep 2014 01:32:04 +0300 Antti Palosaari escreveu: > Are these even cases you should use BUG()? How about WARN()... Those are all very bad driver's behavior. Fixing it would likely require several fixups, as if one of those got hit, something evil happened. Anyway, Hans is converting

Re: [PATCH 13/18] [media] s5p_mfc_opr_v5: Fix lots of warnings on x86_64

2014-09-24 Thread Fabio Estevam
On Wed, Sep 24, 2014 at 7:27 PM, Mauro Carvalho Chehab wrote: > - mfc_debug(2, "buf_size1: %d, buf_size2: %d\n", buf_size1, buf_size2); > + mfc_debug(2, "buf_size1: %zd, buf_size2: %zd\n", buf_size1, > buf_size2); This should be %zu. Same for other %zd ocurrences. -- To unsubscribe

Re: [PATCH 15/18] [media] s5p_mfc_opr: Fix warnings

2014-09-24 Thread Fabio Estevam
Hi Mauro, On Wed, Sep 24, 2014 at 7:27 PM, Mauro Carvalho Chehab wrote: > drivers/media//platform/s5p-mfc/s5p_mfc_opr.c:44:2: warning: format ‘%d’ > expects argument of type ‘int’, but argument 4 has type ‘size_t’ [-Wformat=] ... > - mfc_debug(3, "Allocating priv: %d\n", b->size); > +

Re: [PATCH 09/18] [media] cx88: remove return after BUG()

2014-09-24 Thread Antti Palosaari
Are these even cases you should use BUG()? How about WARN()... Antti On 09/25/2014 01:27 AM, Mauro Carvalho Chehab wrote: As reported by smatch: drivers/media/pci/cx88/cx88-video.c:699 get_queue() info: ignoring unreachable code. drivers/media/pci/cx88/cx88-video.c:714 get_resource() info: ig

[PATCH 17/18] [media] s3c-camif: fix dma_addr_t printks

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media//platform/s3c-camif/camif-capture.c: In function ‘camif_prepare_addr’: include/linux/dynamic_debug.h:64:16: warning: format ‘%x’ expects argument of type ‘unsigned int’, but argument 5 has type ‘dma_addr_t’ [-Wformat=] static struct _ddebug __aligned(8) \ ^ incl

[PATCH 08/18] [media] cx88: fix cards table CodingStyle

2014-09-24 Thread Mauro Carvalho Chehab
This is actually a coding style issue, but it was generating lots of smatch warnings: drivers/media/pci/cx88/cx88-cards.c:1513:37: warning: Initializer entry defined twice drivers/media/pci/cx88/cx88-cards.c:1517:19: also defined here drivers/media/pci/cx88/cx88-cards.c:1533:36: warning: Initia

[PATCH 14/18] [media] s5p_mfc_opr_v6: get rid of warnings when compiled with 64 bits

2014-09-24 Thread Mauro Carvalho Chehab
There are several errors related to size_t size and the usage of unsigned int for pointers: drivers/media/platform/s5p-mfc/s5p_mfc_opr_v6.c: In function ‘s5p_mfc_alloc_codec_buffers_v6’: drivers/media/platform/s5p-mfc/s5p_mfc_opr_v6.c:103:3: warning: format ‘%d’ expects argument of type ‘int’, b

[PATCH 15/18] [media] s5p_mfc_opr: Fix warnings

2014-09-24 Thread Mauro Carvalho Chehab
CC drivers/media//platform/s5p-mfc/s5p_mfc_opr.o drivers/media//platform/s5p-mfc/s5p_mfc_opr.c: In function ‘s5p_mfc_alloc_priv_buf’: drivers/media//platform/s5p-mfc/s5p_mfc_opr.c:44:2: warning: format ‘%d’ expects argument of type ‘int’, but argument 4 has type ‘size_t’ [-Wformat=] mfc_

[PATCH 04/18] [media] saa7164-core: declare symbols as static

2014-09-24 Thread Mauro Carvalho Chehab
Those symbols are used only at saa7164-core. drivers/media/pci/saa7164/saa7164-core.c:55:14: warning: symbol 'fw_debug' was not declared. Should it be static? drivers/media/pci/saa7164/saa7164-core.c:75:14: warning: symbol 'print_histogram' was not declared. Should it be static? drivers/media/pc

[PATCH 13/18] [media] s5p_mfc_opr_v5: Fix lots of warnings on x86_64

2014-09-24 Thread Mauro Carvalho Chehab
When compiled on x86_64, several warnings popup: drivers/media//platform/s5p-mfc/s5p_mfc_opr_v5.c:476:3: warning: format ‘%x’ expects argument of type ‘unsigned int’, but argument 5 has type ‘size_t’ [-Wformat=] drivers/media//platform/s5p-mfc/s5p_mfc_opr_v5.c:480:3: warning: format ‘%x’ expect

[PATCH 11/18] [media] drxd: remove a dead code

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/dvb-frontends/drxd_hard.c:2839 drxd_init() info: ignoring unreachable code. Firmware request/release is not at drxd_init. So, we can remove that dead code. Signed-off-by: Mauro Carvalho Chehab diff --git a/drivers/media/dvb-frontends/drxd_hard.c b/drivers/media/dvb-frontends/drx

[PATCH 10/18] [media] saa7146: remove return after BUG()

2014-09-24 Thread Mauro Carvalho Chehab
As reported by smatch: drivers/media/common/saa7146/saa7146_fops.c:314 fops_mmap() info: ignoring unreachable code. drivers/media/common/saa7146/saa7146_fops.c:402 fops_read() info: ignoring unreachable code. drivers/media/common/saa7146/saa7146_fops.c:426 fops_write() inf

[PATCH 12/18] [media] em28xx: Fix identation

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/usb/em28xx/em28xx-audio.c:270 snd_em28xx_capture_open() warn: if statement not indented Signed-off-by: Mauro Carvalho Chehab diff --git a/drivers/media/usb/em28xx/em28xx-audio.c b/drivers/media/usb/em28xx/em28xx-audio.c index 90c7a83989d1..957c7ae30efe 100644 --- a/drivers/media/

[PATCH 07/18] [media] radio-sf16fmr2: declare some structs as static

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/radio/radio-sf16fmr2.c:308:19: warning: symbol 'fmr2_isa_driver' was not declared. Should it be static? drivers/media/radio/radio-sf16fmr2.c:316:19: warning: symbol 'fmr2_pnp_driver' was not declared. Should it be static? Signed-off-by: Mauro Carvalho Chehab diff --git a/drivers/

[PATCH 01/18] [media] ir-hix5hd2: fix address space casting

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/rc/ir-hix5hd2.c:99:41: warning: incorrect type in argument 2 (different address spaces) drivers/media/rc/ir-hix5hd2.c:99:41:expected void volatile [noderef] *addr drivers/media/rc/ir-hix5hd2.c:99:41:got void * drivers/media/rc/ir-hix5hd2.c:100:16: warning: incorrect type in

[PATCH 09/18] [media] cx88: remove return after BUG()

2014-09-24 Thread Mauro Carvalho Chehab
As reported by smatch: drivers/media/pci/cx88/cx88-video.c:699 get_queue() info: ignoring unreachable code. drivers/media/pci/cx88/cx88-video.c:714 get_resource() info: ignoring unreachable code. drivers/media/pci/cx88/cx88-video.c:815 video_read() info: ignoring unreachable code. Signed-off-b

[PATCH 03/18] [media] sta2x11_vip: fix address space casting

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/pci/sta2x11/sta2x11_vip.c:226:38: warning: incorrect type in argument 1 (different modifiers) drivers/media/pci/sta2x11/sta2x11_vip.c:226:38:expected void [noderef] * drivers/media/pci/sta2x11/sta2x11_vip.c:226:38:got void volatile [noderef] * drivers/media/pci/sta2x11/sta2

[PATCH 18/18] [media] ti-vpe: Fix typecast

2014-09-24 Thread Mauro Carvalho Chehab
Addresses have the same size of unsigned long, and not u32. That removes a warning on 64 bits compilation: drivers/media//platform/ti-vpe/vpdma.c:332:11: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] WARN_ON(((u32) buf->addr & VPDMA_DESC_ALIGN) != 0);

[PATCH 02/18] [media] st_rc: fix address space casting

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/rc/st_rc.c:107:38: warning: incorrect type in argument 1 (different address spaces) drivers/media/rc/st_rc.c:107:38:expected void const volatile [noderef] *addr drivers/media/rc/st_rc.c:107:38:got void * drivers/media/rc/st_rc.c:110:53: warning: incorrect type in argument 1

[PATCH 06/18] [media] radio-sf16fmi: declare pnp_attached as static

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/radio/radio-sf16fmi.c:59:6: warning: symbol 'pnp_attached' was not declared. Should it be static? Signed-off-by: Mauro Carvalho Chehab diff --git a/drivers/media/radio/radio-sf16fmi.c b/drivers/media/radio/radio-sf16fmi.c index bcd0946c84a5..28a89466cddc 100644 --- a/drivers/medi

[PATCH 16/18] s5p-mfc: Fix several printk warnings

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/platform/s5p-mfc/s5p_mfc_ctrl.c:192:3: warning: format ‘%x’ expects argument of type ‘unsigned int’, but argument 4 has type ‘dma_addr_t’ [-Wformat=] drivers/media/platform/s5p-mfc/s5p_mfc_ctrl.c:196:3: warning: format ‘%x’ expects argument of type ‘unsigned int’, but argument 4 ha

[PATCH 05/18] [media] pms: Fix a bad usage of the stack

2014-09-24 Thread Mauro Carvalho Chehab
As warned by smatch: drivers/media/parport/pms.c:632:21: warning: Variable length array is used. The pms driver is doing something really bad: it is using the stack to read data into a buffer whose size is given by the user by the read() syscall. Replace it by a dynamically allocated buff

Re: [PATCH 4/4] V4L/DVB: Add sleep for firmware ready

2014-09-24 Thread Antti Palosaari
After looking it again, the 10ms delay seen in sniff is between boot request and reply. Looks like it took 10ms from chip to reply boot command. But there is no any other delays before nor after booth command. If some small extra delay is really needed for Linux, but not Windows, it indicates linux

Re: [PATCH 2/5] media: v4l2-core changes to use media tuner token api

2014-09-24 Thread Shuah Khan
On 09/24/2014 06:25 AM, Hans Verkuil wrote: > Hi Shuah, > > > Let's be realistic: if an application doesn't test for error codes, > then that's the problem of the application. Also, EBUSY will only be > returned if someone else is holding the tuner in a different mode. > And that didn't work anyw

Re: [PATCH 2/5] media: v4l2-core changes to use media tuner token api

2014-09-24 Thread Shuah Khan
On 09/24/2014 05:57 AM, Hans Verkuil wrote: > Hi Shuah, > > Here is my review... > > On 09/22/2014 05:00 PM, Shuah Khan wrote: >> Changes to v4l2-core to hold tuner token in v4l2 ioctl that change >> the tuner modes, and reset the token from fh exit. The changes are >> limited to vb2 calls that d

[PATCH] rc: fix hix5hd2 build issue in 0-DAY kernel build

2014-09-24 Thread Zhangfei Gao
Add dependence of ARCH_HIX5HD2 to solve build error in arch like ia64 error: implicit declaration of function 'readl_relaxed' & 'writel_relaxed' Change CONFIG_PM to CONFIG_PM_SLEEP to solve warning: 'hix5hd2_ir_suspend' & 'hix5hd2_ir_resume' defined but not used Reported-by: Fengguang Wu Signed-

re: [media] rc: Introduce hix5hd2 IR transmitter driver

2014-09-24 Thread Dan Carpenter
Hello Guoxiong Yan, The patch a84fcdaa9058: "[media] rc: Introduce hix5hd2 IR transmitter driver" from Aug 30, 2014, leads to the following static checker warning: drivers/media/rc/ir-hix5hd2.c:111 hix5hd2_ir_config() warn: odd binop '0x3e80 & 0x' drivers/media/rc/ir-hix5

Re: [PATCH v4 3/4] tc90522: add driver for Toshiba TC90522 quad demodulator

2014-09-24 Thread Akihiro TSUKADA
> Ok, but see the definition at the API spec: > > > http://linuxtv.org/downloads/v4l-dvb-apis/FE_GET_SET_PROPERTY.html#isdb-hierq-layers > > Basically, we use 0, 1, 2, 4 no matter what mode, e. g. I understand. (though I wonder why "4" is assigned instead of "3" when it is not a flag bit

Re: [PATCH 2/5] media: v4l2-core changes to use media tuner token api

2014-09-24 Thread Shuah Khan
On 09/24/2014 05:57 AM, Hans Verkuil wrote: > Hi Shuah, > > Here is my review... > > On 09/22/2014 05:00 PM, Shuah Khan wrote: >> Changes to v4l2-core to hold tuner token in v4l2 ioctl that change >> the tuner modes, and reset the token from fh exit. The changes are >> limited to vb2 calls that d

Re: [PATCH] [media] qm1d1c0042: fix compilation on 32 bits

2014-09-24 Thread Mauro Carvalho Chehab
Em Wed, 24 Sep 2014 16:38:02 +0300 Antti Palosaari escreveu: > > > On 09/24/2014 04:34 PM, Mauro Carvalho Chehab wrote: > > Em Wed, 24 Sep 2014 21:27:57 +0900 > > Akihiro TSUKADA escreveu: > > > >>> - b = (((s64) freq) << 20) / state->cfg.xtal_freq - (((s64) a) << 20); > >>> + b = (s32)div64_s

[PATCH 4/4] [media] qm1d1c0042: fix frequency calculus

2014-09-24 Thread Mauro Carvalho Chehab
Changeset aee9cf18e96e broke the frequency calculus. Fix it. Signed-off-by: Mauro Carvalho Chehab diff --git a/drivers/media/tuners/qm1d1c0042.c b/drivers/media/tuners/qm1d1c0042.c index 2a990f406cf5..18bc745ed108 100644 --- a/drivers/media/tuners/qm1d1c0042.c +++ b/drivers/media/tuners/qm1d1c0

[PATCH 1/4] [media] as102_drv.h: added a missing newline

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/usb/as102/as102_drv.h:83:6: warning: no newline at end of file Signed-off-by: Mauro Carvalho Chehab diff --git a/drivers/media/usb/as102/as102_drv.h b/drivers/media/usb/as102/as102_drv.h index 9430d30163a3..aee2d76e8dfc 100644 --- a/drivers/media/usb/as102/as102_drv.h +++ b/driver

[PATCH 3/4] [media] as102: fix endiannes casts

2014-09-24 Thread Mauro Carvalho Chehab
Smatch complains a lot about endiannes issues on as102: drivers/media/usb/as102/as10x_cmd_stream.c:41:47: warning: incorrect type in assignment (different base types) drivers/media/usb/as102/as10x_cmd_stream.c:41:47:expected unsigned short [unsigned] [usertype] proc_id drivers/media/usb/as10

[PATCH 2/4] [media] dvb_frontend: Fix __user namespace

2014-09-24 Thread Mauro Carvalho Chehab
As reported by smatch: drivers/media/dvb-core/dvb_frontend.c:1960:45: warning: incorrect type in argument 2 (different address spaces) drivers/media/dvb-core/dvb_frontend.c:1960:45:expected void const [noderef] *from drivers/media/dvb-core/dvb_frontend.c:1960:45:got struct dtv_property

Re: [PATCH 1/5] media: add media token device resource framework

2014-09-24 Thread Shuah Khan
On 09/24/2014 05:26 AM, Hans Verkuil wrote: > Hi Shuah, > > Here is my review... > > On 09/22/2014 05:00 PM, Shuah Khan wrote: >> Add media token device resource framework to allow sharing >> resources such as tuner, dma, audio etc. across media drivers >> and non-media sound drivers that control

Re: [PATCH] [media] qm1d1c0042: fix compilation on 32 bits

2014-09-24 Thread Antti Palosaari
On 09/24/2014 04:34 PM, Mauro Carvalho Chehab wrote: Em Wed, 24 Sep 2014 21:27:57 +0900 Akihiro TSUKADA escreveu: - b = (((s64) freq) << 20) / state->cfg.xtal_freq - (((s64) a) << 20); + b = (s32)div64_s64(((s64) freq) << 20, + state->cfg.xtal_freq - (((s

Re: [PATCH v2 6/6] devicetree: bindings: Document Renesas JPEG Processing Unit.

2014-09-24 Thread Mikhail Ulianov
On Tue, 26 Aug 2014 11:42:57 +0900 Simon Horman wrote: > On Tue, Aug 26, 2014 at 02:02:00AM +0200, Laurent Pinchart wrote: > > Hi Simon, > > > > On Tuesday 26 August 2014 08:57:20 Simon Horman wrote: > > > On Mon, Aug 25, 2014 at 02:59:46PM +0200, Geert Uytterhoeven > > > wrote: > > > > On Mon,

Re: [PATCH] [media] qm1d1c0042: fix compilation on 32 bits

2014-09-24 Thread Mauro Carvalho Chehab
Em Wed, 24 Sep 2014 21:27:57 +0900 Akihiro TSUKADA escreveu: > > - b = (((s64) freq) << 20) / state->cfg.xtal_freq - (((s64) a) << 20); > > + b = (s32)div64_s64(((s64) freq) << 20, > > + state->cfg.xtal_freq - (((s64) a) << 20)); > > + > > I'm afraid it should be like th

Re: [PATCH v4 3/4] tc90522: add driver for Toshiba TC90522 quad demodulator

2014-09-24 Thread Mauro Carvalho Chehab
Em Wed, 24 Sep 2014 21:06:43 +0900 Akihiro TSUKADA escreveu: > > And TMCC returns it as 0, 1, 2, 3, 4, instead of 0, 1, 2, 4, 8. > > According to ARIB STD B31 3.15.6.7 (table 3.30), > The value is encoded and depends on the "mode". > so demods have to encode/decode anyway. Ok, but see the defin

[PATCH] [media] Fix smatch warning: unknown field name in initializer

2014-09-24 Thread Mauro Carvalho Chehab
This is detected with: gcc-4.8.3-7.fc20.x86_64 Smatch, up to this patch: commit de462ba2c79d9347368c887ed93113e7818a7b07 Author: Dan Carpenter Date: Wed Sep 17 13:31:16 2014 +0300 drivers/media/v4l2-core/v4l2-dv-timings.c:34:9: error: unknown field name in init

Re: [PATCH] [media] videobuf-dma-contig: replace vm_iomap_memory() with remap_pfn_range().

2014-09-24 Thread Hans Verkuil
On 09/24/2014 02:40 PM, Marek Szyprowski wrote: Hello, On 2014-09-10 09:00, Hans Verkuil wrote: On 09/10/14 07:28, Fancy Fang wrote: When user requests V4L2_MEMORY_MMAP type buffers, the videobuf-core will assign the corresponding offset to the 'boff' field of the videobuf_buffer for each re

[PATCH 4/4] [media] s5p_mfc_opr_v6: remove address space removal warnings

2014-09-24 Thread Mauro Carvalho Chehab
Smatch still has 3 warnings for s5p_mfc_opr_v6: drivers/media/platform/s5p-mfc/s5p_mfc_opr_v6.c:2028:18: warning: cast removes address space of expression drivers/media/platform/s5p-mfc/s5p_mfc_opr_v6.c:2034:18: warning: cast removes address space of expression drivers/media/platform/s5p-mfc/s5p

[PATCH 1/4] [media] s5p_mfc: use static for some structs

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/platform/s5p-mfc/s5p_mfc.c:1334:28: warning: symbol 'mfc_buf_size_v5' was not declared. Should it be static? drivers/media/platform/s5p-mfc/s5p_mfc.c:1341:25: warning: symbol 'buf_size_v5' was not declared. Should it be static? drivers/media/platform/s5p-mfc/s5p_mfc.c:1347:26: warni

[PATCH 2/4] [media] s5p_mfc_opr_v5: fix smatch warnings

2014-09-24 Thread Mauro Carvalho Chehab
drivers/media/platform/s5p-mfc/s5p_mfc_opr_v5.c:266:23: warning: incorrect type in argument 2 (different modifiers) drivers/media/platform/s5p-mfc/s5p_mfc_opr_v5.c:266:23:expected void volatile [noderef] *addr drivers/media/platform/s5p-mfc/s5p_mfc_opr_v5.c:266:23:got void const volatile

[PATCH 3/4] [media] s5p_mfc_opr_v6: fix wrong type for registers

2014-09-24 Thread Mauro Carvalho Chehab
As reported by smatch, there are several warnings related to bad types for registers. Worse than that, there are too many errors, preventing smatch to warn about real issues. So, fix them: drivers/media/platform/s5p-mfc/s5p_mfc_opr_v6.c:414:35: warning: incorrect type in argument 2 (different add

[PATCH 0/4] Remove smatch warnings on s5p-mfc driver

2014-09-24 Thread Mauro Carvalho Chehab
When compiling s5p-mfc driver with: make ARCH=i386 C=1 CF=-D__CHECK_ENDIAN__ CONFIG_DEBUG_SECTION_MISMATCH=y W=1 CF=-D__CHECK_ENDIAN__ M=drivers/media Lots of smatch warnings are produced, because: - some static vars were missing 'static'; - the readl/writel pointers were wrongly

Re: [PATCH] [media] videobuf-dma-contig: replace vm_iomap_memory() with remap_pfn_range().

2014-09-24 Thread Marek Szyprowski
Hello, On 2014-09-10 09:00, Hans Verkuil wrote: On 09/10/14 07:28, Fancy Fang wrote: When user requests V4L2_MEMORY_MMAP type buffers, the videobuf-core will assign the corresponding offset to the 'boff' field of the videobuf_buffer for each requested buffer sequentially. Later, user may call m

Re: [PATCH] [media] qm1d1c0042: fix compilation on 32 bits

2014-09-24 Thread Akihiro TSUKADA
> - b = (((s64) freq) << 20) / state->cfg.xtal_freq - (((s64) a) << 20); > + b = (s32)div64_s64(((s64) freq) << 20, > +state->cfg.xtal_freq - (((s64) a) << 20)); > + I'm afraid it should be like the following. > + b = (s32)(div64_s64(((s64) freq) << 20, state->c

Re: [PATCH 2/5] media: v4l2-core changes to use media tuner token api

2014-09-24 Thread Hans Verkuil
Hi Shuah, On 09/23/2014 10:46 PM, Shuah Khan wrote: Hi Devin/Mauro/Hans, Summarizing the discussion on v4l to keep others on this thread in the loop. Please see below: Hans! Could you please take a look and see if it raises any red flags for you. On 09/23/2014 08:17 AM, Devin Heitmueller wrot

Re: [PATCH v4 3/4] tc90522: add driver for Toshiba TC90522 quad demodulator

2014-09-24 Thread Akihiro TSUKADA
> And TMCC returns it as 0, 1, 2, 3, 4, instead of 0, 1, 2, 4, 8. According to ARIB STD B31 3.15.6.7 (table 3.30), The value is encoded and depends on the "mode". so demods have to encode/decode anyway. > AFAIKT, that doesn't work in Sound Broadcast mode, as the demod won't > be able to read the

RE: [GIT PULL for 3.18] mem2mem changes

2014-09-24 Thread Kamil Debski
Hi, > -Original Message- > From: Mauro Carvalho Chehab [mailto:mche...@osg.samsung.com] > Sent: Wednesday, September 24, 2014 1:35 PM > To: Kamil Debski > Cc: linux-media@vger.kernel.org > Subject: Re: [GIT PULL for 3.18] mem2mem changes > > Em Wed, 24 Sep 2014 11:04:14 +0200 > Kamil Debs

Re: [PATCH 2/5] media: v4l2-core changes to use media tuner token api

2014-09-24 Thread Hans Verkuil
Hi Shuah, Here is my review... On 09/22/2014 05:00 PM, Shuah Khan wrote: Changes to v4l2-core to hold tuner token in v4l2 ioctl that change the tuner modes, and reset the token from fh exit. The changes are limited to vb2 calls that disrupt digital stream. vb1 changes are made in the driver. Th

Re: [GIT PULL for 3.18] mem2mem changes

2014-09-24 Thread Mauro Carvalho Chehab
Em Wed, 24 Sep 2014 11:04:14 +0200 Kamil Debski escreveu: > The following changes since commit c0aaf696d45e2a72048a56441e81dad78659c698: > > [media] coda: coda-bit: Include "" (2014-09-21 16:43:28 > -0300) > > are available in the git repository at: > > ssh://linuxtv/git/kdebski/media_tree

Re: [PATCH v4 3/4] tc90522: add driver for Toshiba TC90522 quad demodulator

2014-09-24 Thread Mauro Carvalho Chehab
Em Wed, 24 Sep 2014 20:14:01 +0900 Akihiro TSUKADA escreveu: > > Btw, please check if your driver is handling it well, as the valid > > values for interleave are 0, 1, 2, 4 (actually, dib8000 also > > supports interleaving equal to 8, if sound_broadcast). > > I have no info on how to set time in

Re: [PATCH 1/5] media: add media token device resource framework

2014-09-24 Thread Hans Verkuil
Hi Shuah, Here is my review... On 09/22/2014 05:00 PM, Shuah Khan wrote: Add media token device resource framework to allow sharing resources such as tuner, dma, audio etc. across media drivers and non-media sound drivers that control media hardware. The Media token resource is created at the m

[PATCH] saa7146: Create a device name before it's used

2014-09-24 Thread Lubomir Rintel
request_irq() uses it, tries to create a procfs file with an empty name otherwise. Link: https://bugzilla.kernel.org/show_bug.cgi?id=83771 Signed-off-by: Lubomir Rintel --- drivers/media/common/saa7146/saa7146_core.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drive

Re: [PATCH v4 3/4] tc90522: add driver for Toshiba TC90522 quad demodulator

2014-09-24 Thread Akihiro TSUKADA
> Btw, please check if your driver is handling it well, as the valid > values for interleave are 0, 1, 2, 4 (actually, dib8000 also > supports interleaving equal to 8, if sound_broadcast). I have no info on how to set time interleaving parameters, although I can read them as a part of TMCC info. I

Re: [patch] [media] hackrf: harmless off by one in debug code

2014-09-24 Thread Antti Palosaari
Acked-by: Antti Palosaari Reviewed-by: Antti Palosaari Antti On 09/24/2014 01:36 PM, Dan Carpenter wrote: My static checker complains that "i" could be one element beyond the end of the array. Signed-off-by: Dan Carpenter diff --git a/drivers/media/usb/hackrf/hackrf.c b/drivers/media/usb/

[GIT PULL for v3.17] media fixes

2014-09-24 Thread Mauro Carvalho Chehab
Hi Linus, Please pull from: git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media tags/media/v3.17-rc7 For some last time fixes: - a regression detected on Kernel 3.16 related to VBI Teletext application breakage on drivers using videobuf2 (https://bugzil

[patch] [media] hackrf: harmless off by one in debug code

2014-09-24 Thread Dan Carpenter
My static checker complains that "i" could be one element beyond the end of the array. Signed-off-by: Dan Carpenter diff --git a/drivers/media/usb/hackrf/hackrf.c b/drivers/media/usb/hackrf/hackrf.c index 328b5ba..fd1fa41 100644 --- a/drivers/media/usb/hackrf/hackrf.c +++ b/drivers/media/usb/ha

Re: [PATCH] [media] videobuf-dma-contig: replace vm_iomap_memory() with remap_pfn_range().

2014-09-24 Thread Hans Verkuil
On 09/24/2014 05:29 AM, chen.f...@freescale.com wrote: Thanks a lot, Hans. I know the reason that you use vm_iomap_memory() instead of remap_pfn_range(). But according to my analysis, the sanity check is not suitable for v4l2 buffers mapping. You can check the code logic to see this. The l

Re: [PATCH v4 3/4] tc90522: add driver for Toshiba TC90522 quad demodulator

2014-09-24 Thread Mauro Carvalho Chehab
Em Wed, 24 Sep 2014 12:00:53 +0900 Akihiro TSUKADA escreveu: > > Hi, > > On 2014年09月24日 05:07, Mauro Carvalho Chehab wrote: > > I applied this series, as we're discussing it already for a long time, > > and it seems in a good shape... > > thanks for your reviews and advices. > > >> +static in

Re: [PATCH 1/1] media: Set entity->links NULL in cleanup

2014-09-24 Thread Sakari Ailus
Hi Laurent, Oops. this got buried in my inbox... Laurent Pinchart wrote: On Thursday 17 July 2014 14:53:49 Sakari Ailus wrote: On Thu, Jul 17, 2014 at 01:43:09PM +0200, Laurent Pinchart wrote: On Tuesday 27 May 2014 16:27:49 Sakari Ailus wrote: Calling media_entity_cleanup() on a cleaned-up

[GIT PULL for 3.18] mem2mem changes

2014-09-24 Thread Kamil Debski
The following changes since commit c0aaf696d45e2a72048a56441e81dad78659c698: [media] coda: coda-bit: Include "" (2014-09-21 16:43:28 -0300) are available in the git repository at: ssh://linuxtv/git/kdebski/media_tree_2.git for-v3.18-2 for you to fetch changes up to 242b5f7029ab613008a3c2bcc

Re: [STLinux Kernel] [PATCH 1/3] media: st-rc: move to using reset_control_get_optional

2014-09-24 Thread Maxime Coquelin
Hi Srini, Peter, On 09/24/2014 10:12 AM, Srinivas Kandagatla wrote: > Hi Pete, > > On 23/09/14 19:02, Peter Griffin wrote: >> Hi Srini, >> >> On Mon, 22 Sep 2014, Srinivas Kandagatla wrote: >> >>> This patch fixes a compilation error while building with the >>> random kernel configuration. >>> >>

Re: [STLinux Kernel] [PATCH 1/3] media: st-rc: move to using reset_control_get_optional

2014-09-24 Thread Srinivas Kandagatla
Hi Pete, On 23/09/14 19:02, Peter Griffin wrote: Hi Srini, On Mon, 22 Sep 2014, Srinivas Kandagatla wrote: This patch fixes a compilation error while building with the random kernel configuration. drivers/media/rc/st_rc.c: In function 'st_rc_probe': drivers/media/rc/st_rc.c:281:2: error: imp