Re: [media] drivers:media:radio: wl128x: FM Driver Common sources

2012-07-13 Thread Dan Carpenter
On Fri, Jul 13, 2012 at 01:17:11PM -0500, halli manjunatha wrote: > On Fri, Jul 13, 2012 at 6:51 AM, Dan Carpenter > wrote: > > > > Hello Manjunatha Halli, > > > > The patch e8454ff7b9a4: "[media] drivers:media:radio: wl128x: FM > > Driver Common

re: [media] drivers:media:radio: wl128x: FM Driver Common sources

2012-07-13 Thread Dan Carpenter
memcpy() and the overwrite part of the data on the next line? regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

[media] tvp5150: signedness bug in tvp5150_selmux()

2012-07-12 Thread Dan Carpenter
tvp5150_read() returns negative error codes so this needs to be an int for the error handling to work. Signed-off-by: Dan Carpenter diff --git a/drivers/media/video/tvp5150.c b/drivers/media/video/tvp5150.c index 0d897cb..a751b6c 100644 --- a/drivers/media/video/tvp5150.c +++ b/drivers/media

Re: [patch -resend] [media] az6007: precedence bug in az6007_i2c_xfer()

2012-06-28 Thread Dan Carpenter
On Wed, Jun 27, 2012 at 10:11:00AM -0300, Mauro Carvalho Chehab wrote: > Em 27-06-2012 06:06, Dan Carpenter escreveu: > > The intent here was to test that the flag was clear but the '!' has > > higher precedence than the '&'. I2C_M_RD is 0x1 so the curren

[patch -resend] [media] az6007: precedence bug in az6007_i2c_xfer()

2012-06-27 Thread Dan Carpenter
The intent here was to test that the flag was clear but the '!' has higher precedence than the '&'. I2C_M_RD is 0x1 so the current code is equivalent to "&& (!sgs[i].flags) ..." Signed-off-by: Dan Carpenter --- I sent this originally on Wed, 25 Jan 20

[patch] [media] drxk: fix a '&' vs '|' bug

2012-06-26 Thread Dan Carpenter
IQM_AF_CLKNEG_CLKNEGDATA__M is 0x2 and IQM_AF_CLKNEG_CLKNEGDATA_CLK_ADC_DATA_POS is 0. (clkNeg | 0x2) is never equal to zero so the condition can never be true. I consulted with Ralph Metzler and the '|' should be changed to a '&'. Signed-off-by: Dan Carpenter CC: Ralp

Re: [PATCH 0/12] struct i2c_algo_bit_data cleanup on several drivers

2012-06-18 Thread Dan Carpenter
On Mon, Jun 18, 2012 at 06:00:52PM -0300, Ezequiel Garcia wrote: > On Mon, Jun 18, 2012 at 5:56 PM, Dan Carpenter > wrote: > > On Mon, Jun 18, 2012 at 04:23:14PM -0300, Ezequiel Garcia wrote: > >> Hi Mauro, > >> > >> This patchset cleans the i2c part of som

Re: [PATCH 0/12] struct i2c_algo_bit_data cleanup on several drivers

2012-06-18 Thread Dan Carpenter
On Mon, Jun 18, 2012 at 04:23:14PM -0300, Ezequiel Garcia wrote: > Hi Mauro, > > This patchset cleans the i2c part of some drivers. > This issue was recently reported by Dan Carpenter [1], > and revealed wrong (and harmless) usage of struct i2c_algo_bit. > How is this harmles

Re: V4L/DVB (12730): Add conexant cx25821 driver

2012-06-16 Thread Dan Carpenter
x23885/cx23885-i2c.c:321 cx23885_i2c_register() error: memcpy() '&cx23885_i2c_algo_template' too small (24 vs 64) drivers/media/video/cx231xx/cx231xx-i2c.c:503 cx231xx_i2c_register() error: memcpy() '&cx231xx_algo' too small (24 vs 64) regards, dan carpenter -- To unsubscribe fr

re: V4L/DVB (12730): Add conexant cx25821 driver

2012-06-16 Thread Dan Carpenter
cx25821_i2c_algo_template is a i2c_algorithm struct. They are different sizes and the function pointers don't line up at all. I don't see how this can work at all. regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

linux-media@vger.kernel.org

2012-06-10 Thread Dan Carpenter
On Sat, Jun 09, 2012 at 10:47:32AM +0300, Dan Carpenter wrote: > The test here is never true because '&' was used instead of '|'. It was > the same as: > > if (status & ((1<<16) & (1<<17)) ... > > Signed-off-by: Dan Carpenter

Re: [media] DRX-K: Initial check-in

2012-06-10 Thread Dan Carpenter
On Sun, Jun 10, 2012 at 09:42:22PM +0200, Ralph Metzler wrote: > Dan Carpenter writes: > > Hello Ralph Metzler, > > > > The patch 43dd07f758d8: "[media] DRX-K: Initial check-in" from Jul 3, > > 2011, leads to the following warning: > > d

re: Staging: solo6x10: New driver (staging) for Softlogic 6x10

2012-06-09 Thread Dan Carpenter
s/staging/media/solo6x10/tw28.c:362 tw2815_setup() warn: x |= 0 drivers/staging/media/solo6x10/tw28.c:367 tw2815_setup() warn: x |= 0 drivers/staging/media/solo6x10/tw28.c:373 tw2815_setup() warn: x |= 0 drivers/staging/media/solo6x10/tw28.c:383 tw2815_setup() warn: x |= 0 regards, dan carpenter --

linux-media@vger.kernel.org

2012-06-09 Thread Dan Carpenter
The test here is never true because '&' was used instead of '|'. It was the same as: if (status & ((1<<16) & (1<<17)) ... Signed-off-by: Dan Carpenter --- I don't have this hardware and this one really should be tested or checked by

re: [media] DRX-K: Initial check-in

2012-06-08 Thread Dan Carpenter
c:3847 SetDVBT() warn: x |= 0 drivers/media/dvb/frontends/drxk_hard.c:3888 SetDVBT() warn: x |= 0 drivers/media/dvb/frontends/drxk_hard.c:3915 SetDVBT() warn: x |= 0 drivers/media/dvb/frontends/drxk_hard.c:3931 SetDVBT() warn: x |= 0 regards, dan carpenter -- To unsubscribe from this list: send the

[patch] [media] videobuf-dma-contig: use gfp_t for GFP flags

2012-05-24 Thread Dan Carpenter
videobuf-dma-contig.c:47:65:got unsigned long Signed-off-by: Dan Carpenter diff --git a/drivers/media/video/videobuf-dma-contig.c b/drivers/media/video/videobuf-dma-contig.c index b6b5cc1..9b9a06f 100644 --- a/drivers/media/video/videobuf-dma-contig.c +++ b/drivers/media/video/videobuf-dma-contig.c

Re: [PATCH] lg2160: fix off-by-one error in lg216x_write_regs

2012-05-21 Thread Dan Carpenter
On Mon, May 21, 2012 at 11:58:06AM -0400, Michael Krufky wrote: > eeek! spelling error in dan's name! my apologies. I will correct > this in my tree before I ask Mauro to merge it. > Hehe. Also since you're redoing it, could you change the Thanks-to: to Reported-by:? reg

re: [media] v4l/dvb: fix compiler warnings

2012-05-21 Thread Dan Carpenter
ich is turned off by default because there are too many of them and they are mostly useless. And instead we got this warning which is turned on by default and usually indicates a nasty bug... Grrr... :P regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linu

re: [media] DVB: add support for the LG2160 ATSC-MH demodulator

2012-05-21 Thread Dan Carpenter
g2160_init)); The last element of the lg2160_init[] array looks useful. regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

bug report: null dereference in error handling in mantis_dvb_init()

2012-05-17 Thread Dan Carpenter
tend() was added but it can't handle NULL pointers. 252 dvb_frontend_detach(mantis->fe); 253 err4: regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

re: [media] cx23885-dvb: Remove a dirty hack that would require DVBv3

2012-05-15 Thread Dan Carpenter
L then we will oops in cx23885_dvb_set_frontend(). Also if "fe" is NULL we'll oops right here. 138 } 139 regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 1/2] staging: media: go7007: Adlink MPG24 board

2012-05-14 Thread Dan Carpenter
On Mon, May 14, 2012 at 01:25:43PM +0400, vol...@telros.ru wrote: > On Mon, May 14, 2012 at 12:04:15PM +0300, Dan Carpenter wrote: > > On Mon, May 14, 2012 at 12:09:18PM +0400, vol...@telros.ru wrote: > > > It`s very horrible to describe every changing... > > > &g

Re: [PATCH 1/2] staging: media: go7007: Adlink MPG24 board

2012-05-14 Thread Dan Carpenter
te commits by the way. Just use "git citool", highlight the lines you want, right click, and choose "commit selected lines". regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@v

Re: [PATCH 2/2] staging: media: go7007: Adlink MPG24 board

2012-05-13 Thread Dan Carpenter
wise > This patch as well has a lot of good stuff in it, but it needs to be broken up. regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 1/2] staging: media: go7007: Adlink MPG24 board

2012-05-13 Thread Dan Carpenter
example? That might have security implications and be good thing to know about. regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [patch] [media] gspca: passing wrong length parameter to reg_w()

2012-05-02 Thread Dan Carpenter
eanup. > Maybe the fix could have been > > reg_w(gspca_dev, 0x0010, reg10, sizeof reg10); > > but it is OK for me. > > Acked-by: Jean-Francois Moine <http://moinejf.free.fr> Thanks. regards, dan carpenter -- To unsubscribe from this list: send the line "u

[patch] [media] gspca: passing wrong length parameter to reg_w()

2012-05-01 Thread Dan Carpenter
This looks like a cut an paste error. This is a two byte array but we use 8 as a length parameter. Signed-off-by: Dan Carpenter --- This is a static checker fix. I don't own the hardware. diff --git a/drivers/media/video/gspca/conex.c b/drivers/media/video/gspca/conex.c index ea

Re: [patch] [media] ngene: remove an unneeded condition

2012-04-28 Thread Dan Carpenter
On Sat, Apr 28, 2012 at 04:57:35PM +0200, walter harms wrote: > > > Am 20.04.2012 15:15, schrieb Dan Carpenter: > > "stat" is always zero here. The condition used to be needed, but we > > shifted stuff around in 0f0b270f90 "[media] ngene: CXD2099AR Common

linux-media@vger.kernel.org

2012-04-22 Thread Dan Carpenter
0x0804. Signed-off-by: Dan Carpenter diff --git a/drivers/media/rc/fintek-cir.c b/drivers/media/rc/fintek-cir.c index 392d4be..fba611e 100644 --- a/drivers/media/rc/fintek-cir.c +++ b/drivers/media/rc/fintek-cir.c @@ -197,7 +197,7 @@ static int fintek_hw_detect(struct fintek_dev *fintek

Re: [PATCH] [Trivial] staging: go7007: Framesizes features

2012-04-21 Thread Dan Carpenter
correct anything, it just adds new features that weren't supported before. Don't put [Trivial] in the subject line. Trivial patches are things like spelling mistakes in comments. regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in

[patch] [media] ngene: remove an unneeded condition

2012-04-20 Thread Dan Carpenter
"stat" is always zero here. The condition used to be needed, but we shifted stuff around in 0f0b270f90 "[media] ngene: CXD2099AR Common Interface driver". This doesn't change how the code works, it's just a bit tidier. Signed-off-by: Dan Carpenter diff --git a

[patch] [media] saa7164: saa7164_vbi_stop_port() returns linux error codes

2012-04-19 Thread Dan Carpenter
The saa7164_vbi_stop_port() changes the SAA_ERR_ALREADY_STOPPED result code to -EIO before returning. Signed-off-by: Dan Carpenter diff --git a/drivers/media/video/saa7164/saa7164-vbi.c b/drivers/media/video/saa7164/saa7164-vbi.c index 273cf80..d8e6c8f 100644 --- a/drivers/media/video/saa7164

re: [media] fintek-cir: add support for newer chip version

2012-04-19 Thread Dan Carpenter
= LOGICAL_DEV_CIR_REV2; 202 else 203 fintek->logical_dev_cir = LOGICAL_DEV_CIR_REV1; 204 regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordo

Re: Subject: [PATCH] [Trivial] Staging: go7007: wis-tw2804 upstyle to v4l2

2012-04-19 Thread Dan Carpenter
t (in a separate patch) the format would be: printk(KERN_ERR "wis-tw2804: channel %d is not between 0 and 3!\n", *input); When people submit big patches there is a lot to complain about

Re: [PATCH] Staging: go7007: detector features - add new tuning option

2012-04-18 Thread Dan Carpenter
x) >> 4); > - go->modet_map[mbnum] = region; > - } > - clip_ptr = clip.next; > +static int RectToModetMap( > + struct go7007 *go, > + char Region, > + struct v4l2_rect *Rect, > + int Del

[patch] [media] pluto2: remove some dead code

2012-04-17 Thread Dan Carpenter
buf[] is a 4 character array. Perhaps this was some debugging code from back in the day? Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/pluto2/pluto2.c b/drivers/media/dvb/pluto2/pluto2.c index e1f20c2..f148b19 100644 --- a/drivers/media/dvb/pluto2/pluto2.c +++ b/drivers/media

re: [media] tda10071: NXP TDA10071 DVB-S/S2 driver

2012-04-17 Thread Dan Carpenter
ves the last 7 bytes of cmd.args unitialized. Btw, why are the sizes specified in hex instead of decimal here? 323 cmd.len = 0x07 + diseqc_cmd->msg_len; regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

[patch] [media] mxl111sf: remove an unused variable

2012-03-23 Thread Dan Carpenter
We don't use this any more after 3be5bb71fb "[media] mxl111sf: fix error on stream stop in mxl111sf_ep6_streaming_ctrl()" and it makes GCC complain. Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/dvb-usb/mxl111sf.c b/drivers/media/dvb/dvb-usb/mxl111sf.c index 8

[patch] [media] uvcvideo: remove unneeded access_ok() check

2012-03-20 Thread Dan Carpenter
copy_in_user() already checks for write permission, so we don't need to do it here. This was added in 1a5e4c867c "[media] uvcvideo: Implement compat_ioctl32 for custom ioctls". Signed-off-by: Dan Carpenter diff --git a/drivers/media/video/uvc/uvc_v4l2.c b/drivers/media/video

Re: go7007 patch for 3.2.11

2012-03-20 Thread Dan Carpenter
Also the patch has to apply against linux-next not 3.2.11. Probably that is explained in the link I sent... regards, dan carpenter signature.asc Description: Digital signature

Re: go7007 patch for 3.2.11

2012-03-20 Thread Dan Carpenter
h to yourself first and verify that it applies. Read Documentation/SubmittingPatches. There are bunch of tutorials on how to submit patches online as well. http://www.tuxradar.com/content/newbies-guide-hacking-linux-kernel regards, dan carpenter signature.asc Description: Digital signature

[patch] [media] gpio-ir-recv: a couple signedness bugs

2012-03-10 Thread Dan Carpenter
the type that gpio_get_value_cansleep() returns and we test for negative returns. Signed-off-by: Dan Carpenter diff --git a/drivers/media/rc/gpio-ir-recv.c b/drivers/media/rc/gpio-ir-recv.c index 6744479..0d87545 100644 --- a/drivers/media/rc/gpio-ir-recv.c +++ b/drivers/media/rc/gpio-ir-recv.c @@

Re: [PATCH] [media] dvb: negative value assigned to unsigned int in CDRXD().

2012-03-06 Thread Dan Carpenter
changelogs could you please write something about how this change will affect what the user sees. That way users know if it fixes something they care about and they will apply your patch. regards, dan carpenter signature.asc Description: Digital signature

Re: [PATCH 9/9] staging: easycap: Split easycap_delete() into several pieces

2012-02-24 Thread Dan Carpenter
On Fri, Feb 24, 2012 at 12:24:22PM -0300, Ezequiel Garcia wrote: > + /* Free video urbs */ > + free_video_urbs(peasycap); These comments aren't redundant. Could you remove them in a later patch? regards, dan carpenter signature.asc Description: Digital signature

Re: [PATCH 5/9] staging: easycap: Push video registration to easycap_register_video()

2012-02-24 Thread Dan Carpenter
slow you down. But it would have been better to return rc here. regards, dan carpenter signature.asc Description: Digital signature

[patch 2/2] [media] s2255drv: fix some endian bugs

2012-02-16 Thread Dan Carpenter
I don't have this hardware and I don't know the subsystem very well. So please review this patch carefully. The original code definitely looks buggy though. Sparse complains about some endian bugs where little endian bugs are treated as cpu endian. Signed-off-by: Dan Carpenter ---

[patch 1/2] [media] s2255drv: cleanup vidioc_enum_fmt_cap()

2012-02-16 Thread Dan Carpenter
"f" wasn't checked consistently, so static checkers complain. This function is always called with a valid "f" pointer, so I have removed the check. Also the indenting was messed up. Signed-off-by: Dan Carpenter diff --git a/drivers/media/video/s2255drv.c b/drivers/med

[patch] [media] az6007: precedence bug in az6007_i2c_xfer()

2012-01-25 Thread Dan Carpenter
The intent here was to test that the flag was clear but the '!' has higher precedence than the '&'. I2C_M_RD is 0x1 so the current code is equivalent to "&& (!sgs[i].flags) ..." Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/dvb-usb/az60

Re: [patch 2/2] [media] ds3000: off by one in ds3000_read_snr()

2012-01-21 Thread Dan Carpenter
On Thu, Jan 19, 2012 at 03:22:02PM +0300, Dan Carpenter wrote: > It's a good point. I will redo the patch. Sorry, I've decided to bail on this. The original code is buggy but I don't know what's going on well enough to fix it with any confidence. regards, dan car

Re: [patch 2/2] [media] ds3000: off by one in ds3000_read_snr()

2012-01-19 Thread Dan Carpenter
y is -1. > It's a good point. I will redo the patch. regards, dan carpenter signature.asc Description: Digital signature

Re: [patch 2/2] [media] ds3000: off by one in ds3000_read_snr()

2012-01-19 Thread Dan Carpenter
On Wed, Jan 18, 2012 at 06:06:46PM +0100, walter harms wrote: > > > Am 17.01.2012 08:30, schrieb Dan Carpenter: > > This is a static checker patch and I don't have the hardware to test > > this, so please review it carefully. The dvbs2_snr_tab[] array has 80 > >

[patch 2/2] [media] ds3000: off by one in ds3000_read_snr()

2012-01-16 Thread Dan Carpenter
st but use "snr_reading - 1" as the array offset. I've done the same thing here. Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/frontends/ds3000.c b/drivers/media/dvb/frontends/ds3000.c index af65d01..3f5ae0a 100644 --- a/drivers/media/dvb/frontends/ds3000.c +++ b/dr

linux-media@vger.kernel.org

2012-01-16 Thread Dan Carpenter
The intent here was to test if the FE_HAS_LOCK was set. The current test is equivalent to "if (status) { ..." Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/frontends/ds3000.c b/drivers/media/dvb/frontends/ds3000.c index 9387770..af65d01 100644 --- a/drivers/media/dvb

[patch] [media] tlg2300: fix up check_firmware() return

2012-01-15 Thread Dan Carpenter
e on error and zero on success. Signed-off-by: Dan Carpenter diff --git a/drivers/media/video/tlg2300/pd-main.c b/drivers/media/video/tlg2300/pd-main.c index 129f135..c096b3f 100644 --- a/drivers/media/video/tlg2300/pd-main.c +++ b/drivers/media/video/tlg2300/pd-main.c @@ -374,7 +374,7 @@ static i

[patch] [media] saa7164: remove duplicate initialization

2012-01-15 Thread Dan Carpenter
These were initialized twice by mistake. They were defined the same way both times so this doesn't change how the code works. Signed-off-by: Dan Carpenter diff --git a/drivers/media/video/saa7164/saa7164-cards.c b/drivers/media/video/saa7164/saa7164-cards.c index 971591d..5b72da5 100644

re: V4L/DVB (12892): DVB-API: add support for ISDB-T and ISDB-Tsb (version 5.1)

2012-01-13 Thread Dan Carpenter
MODULATION, 0, 0), + _DTV_CMD(DTV_ISDBT_LAYERC_SEGMENT_COUNT, 0, 0), + _DTV_CMD(DTV_ISDBT_LAYERC_TIME_INTERLEAVING, 0, 0), regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org Mo

[patch] [media] cx231xx: dereferencing NULL after allocation failure

2012-01-12 Thread Dan Carpenter
"dev" is NULL here so we should use "nr" instead of "dev->devno". Signed-off-by: Dan Carpenter diff --git a/drivers/media/video/cx231xx/cx231xx-cards.c b/drivers/media/video/cx231xx/cx231xx-cards.c index 919ed77..875a7ce 100644 --- a/drivers/media/video/cx23

[patch] [media] mb86a20s: fix off by one checks

2012-01-12 Thread Dan Carpenter
Clearly ">=" was intended here instead of ">". Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/frontends/mb86a20s.c b/drivers/media/dvb/frontends/mb86a20s.c index 38778a8..4e6f836 100644 --- a/drivers/media/dvb/frontends/mb86a20s.c +++ b/drivers/medi

[patch] [media] cx23885: handle errors from videobuf_dvb_get_frontend()

2012-01-10 Thread Dan Carpenter
The error handling in the original code wasn't complete so static checkers complained about a potential NULL deference. Signed-off-by: Dan Carpenter --- Compile tested only. I don't think there is anything else that needs to be done before returning, but it would be great if someone

linux-media@vger.kernel.org

2012-01-09 Thread Dan Carpenter
asn't a bool it would be a problem. The other difference between & and && is that && has orderring guarantees but that's also not a factor here. regards, dan carpenter signature.asc Description: Digital signature

Re: [patch -longterm v2] V4L/DVB: v4l2-ioctl: integer overflow in video_usercopy()

2012-01-05 Thread Dan Carpenter
On Thu, Jan 05, 2012 at 08:43:58AM -0800, Greg KH wrote: > On Thu, Jan 05, 2012 at 09:28:22AM +0300, Dan Carpenter wrote: > > If p->count is too high the multiplication could overflow and > > array_size would be lower than expected. Mauro and Hans Verkuil > > suggeste

[patch -longterm v2] V4L/DVB: v4l2-ioctl: integer overflow in video_usercopy()

2012-01-04 Thread Dan Carpenter
211 Signed-off-by: Dan Carpenter diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h index b59e78c..9e2088c 100644 --- a/include/linux/videodev2.h +++ b/include/linux/videodev2.h @@ -858,6 +858,7 @@ struct v4l2_querymenu { #define V4L2_CTRL_FLAG_NEXT_CTRL 0x8000 /* U

[patch -next] V4L/DVB: v4l2-ioctl: integer overflow in video_usercopy()

2012-01-04 Thread Dan Carpenter
-l 211 Cc: stable Signed-off-by: Dan Carpenter diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h index d2f981a..4942f81 100644 --- a/include/linux/videodev2.h +++ b/include/linux/videodev2.h @@ -1133,6 +1133,7 @@ struct v4l2_querymenu { #define V4L2_CTRL_FLAG_NEXT_C

[patch] [media] saa7134: use correct array offset

2012-01-04 Thread Dan Carpenter
Smatch complains that i can be one passed the end of the array if we don't hit the break statement. We should be using the "audio" here like we do in the other places. Signed-off-by: Dan Carpenter --- Compile tested only. Please review carefully. diff --git a/drivers/medi

linux-media@vger.kernel.org

2012-01-04 Thread Dan Carpenter
This is just a cleanup, it doesn't change how the code works. These are compound conditions and not bitwise operations so it should be && and not &. Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/frontends/af9013.c b/drivers/media/dvb/frontends/af9013.c index

Re: [patch -longterm] V4L/DVB: v4l2-ioctl: integer overflow in video_usercopy()

2012-01-04 Thread Dan Carpenter
On Tue, Jan 03, 2012 at 12:55:39PM -0800, Greg KH wrote: > Ok, can someone please send me the "accepted" version of this patch for > inclusion in the 2.6.32-stable tree? > Sorry for that. Holidays and all. I'll send a patch tomorrow. regards, dan carpenter s

re: [media] cx23885-dvb: Remove a dirty hack that would require DVBv3

2012-01-03 Thread Dan Carpenter
*/ 135 cx23885_dvb_set_frontend(fe->dvb.frontend); New dereference. 136 } 137 regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.

Re: [PATCH 12/15] module_param: make bool parameters really bool (drivers & misc)

2012-01-03 Thread Dan Carpenter
gt; +static bool noregister = 0; > +static bool probeonly = 0; > +static bool idonly = 0; > +static bool bailearly = 0; bailearly should be an int here. It's part of some ugly debug code where a value of 3 means bailout at point 3. Maybe we should just remove it instead... regards, dan carpenter signature.asc Description: Digital signature

[patch 2/2] [media] Staging: dt3155v4l: probe() always fails

2011-12-21 Thread Dan Carpenter
There were some curly braces missing so the probe() function always failed. Signed-off-by: Dan Carpenter diff --git a/drivers/staging/media/dt3155v4l/dt3155v4l.c b/drivers/staging/media/dt3155v4l/dt3155v4l.c index 25c6025..280c84e 100644 --- a/drivers/staging/media/dt3155v4l/dt3155v4l.c +++ b

[patch 1/2] [media] Staging: dt3155v4l: update to newer API

2011-12-21 Thread Dan Carpenter
ivers/staging/media/dt3155v4l/dt3155v4l.c:311:2: warning: (near initialization for ‘q_ops.start_streaming’) [enabled by default] Signed-off-by: Dan Carpenter --- Please double check that this is sufficient. I'm not very familiar with this code. diff --git a/drivers/staging/media

[patch -longterm] V4L/DVB: v4l2-ioctl: integer overflow in video_usercopy()

2011-12-14 Thread Dan Carpenter
On a 32bit system the multiplication here could overflow. p->count is used in some of the V4L drivers. Signed-off-by: Dan Carpenter --- This is a patch against the 2.6.32-longterm kernel. In the stock kernel, this code was totally rewritten and fixed in 2010 by d14e6d76ebf "[media]

[patch] [media] tm6000: using an uninitialized variable in debug code

2011-12-13 Thread Dan Carpenter
dprintk() dereferences "ir". I'm not sure why gcc doesn't complain about this. Signed-off-by: Dan Carpenter diff --git a/drivers/media/video/tm6000/tm6000-input.c b/drivers/media/video/tm6000/tm6000-input.c index 8d92527..7844607 100644 --- a/drivers/media/video/tm6000/

re: [media] tm6000: rewrite IR support

2011-12-13 Thread Dan Carpenter
324 int pipe, size; 325 int err = -ENOMEM; 326 327 if (!ir) Old check. 328 return -ENODEV; 329 regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media"

Re: [media] dib7090: add the reference board TFE7090E

2011-12-06 Thread Dan Carpenter
t. I should have seen that myself. > But I can make a patch in order to make sure that this code will > not be detected as an error. Don't do that if you don't want to. This is fixable on the static checker side of things. regards, dan carpenter signature.asc Description: Digital signature

[patch] [media] xc5000: unlock on error in xc_load_fw_and_init_tuner()

2011-11-30 Thread Dan Carpenter
We recently added locking to this function, but we missed an error path which needs an unlock. Signed-off-by: Dan Carpenter diff --git a/drivers/media/common/tuners/xc5000.c b/drivers/media/common/tuners/xc5000.c index 048f489..a3fcc59 100644 --- a/drivers/media/common/tuners/xc5000.c +++ b

re: [media] dib7090: add the reference board TFE7090E

2011-11-28 Thread Dan Carpenter
mp_pwm_normal); 1143 } 1144 } 1145 1146 if (state->rf_ramp[0] != 0) ^ This is the old dereference. 1147 dib0090_write_reg(state, 0x32, (3 << 11)); 1148

[patch v2] [media] saa7164: fix endian conversion in saa7164_bus_set()

2011-11-28 Thread Dan Carpenter
The msg->command field is 32 bits, and we should fill it with a call to cpu_to_le32(). The current code is broke on big endian systems. On little endian systems it truncates the 32 bit value to 16 bits which probably still works fine. Signed-off-by: Dan Carpenter --- v2: Mauro pointed out t

Re: [patch] [media] saa7164: fix endian conversion in saa7164_bus_set()

2011-11-26 Thread Dan Carpenter
missed and resend. regards, dan carpenter signature.asc Description: Digital signature

[patch 2/2] staging/media: lirc_imon: remove unused definitions

2011-11-24 Thread Dan Carpenter
We don't have these functions any more now we have module_usb_driver(). Signed-off-by: Dan Carpenter --- I don't know if this goes in through USB or the media tree. diff --git a/drivers/staging/media/lirc/lirc_imon.c b/drivers/staging/media/lirc/lirc_imon.c index f682180..c3eae4d 10

[patch 1/2] staging/media: lirc_imon: add a __user annotation

2011-11-24 Thread Dan Carpenter
(incompatible argument 2 (different address spaces)) lirc_imon.c:117:28:expected long ( *write )( ... ) lirc_imon.c:117:28:got long ( static [toplevel] * )( ... ) Signed-off-by: Dan Carpenter diff --git a/drivers/staging/media/lirc/lirc_imon.c b/drivers/staging/media/lirc/lirc_imon.c index

[patch] [media] saa7164: fix endian conversion in saa7164_bus_set()

2011-11-22 Thread Dan Carpenter
The msg->command field is 32 bits, and we should fill it with a call to cpu_to_le32(). The current code is broken on big endian systems, and on little endian systems it just truncates the 32 bit value to 16 bits. Signed-off-by: Dan Carpenter --- This is a static checker bug. I haven'

[patch] [media] radio: NUL terminate a user string

2011-11-22 Thread Dan Carpenter
We pass this to fm_tx_set_radio_text() which expects a NUL terminated string. Signed-off-by: Dan Carpenter diff --git a/drivers/media/radio/wl128x/fmdrv_v4l2.c b/drivers/media/radio/wl128x/fmdrv_v4l2.c index 4f5c43d..077d369 100644 --- a/drivers/media/radio/wl128x/fmdrv_v4l2.c +++ b/drivers

[patch] [media] pwc: unlock on error in pwc_ioctl()

2011-11-13 Thread Dan Carpenter
In 82dfdada40 "pwc: rework locking" we changed the locking so that we handle it ourselves instead of doing it at the vl42 layer. There were a couple ioctls, VIDIOCPWCSLED and VIDIOCPWCGLED, where we didn't unlock on the error path. Signed-off-by: Dan Carpenter diff --git a/driv

Re: [PATCH 1/1] rc: Fix input deadlock and transmit error in redrat3 driver

2011-11-08 Thread Dan Carpenter
rguments to unsigned as per 5588dc2 > This would be easier to review it you put the changes to enable and disable into one patch and the changes so that we now measure the buffer length in bytes instead of ints into a second patch. regards, dan carpenter signature.asc Description: Digital signature

[patch] [media] V4L: mt9t112: use after free in mt9t112_probe()

2011-11-07 Thread Dan Carpenter
priv gets dereferenced in mt9t112_set_params() so we should return before calling that. Signed-off-by: Dan Carpenter diff --git a/drivers/media/video/mt9t112.c b/drivers/media/video/mt9t112.c index 32114a3..7b34b11 100644 --- a/drivers/media/video/mt9t112.c +++ b/drivers/media/video/mt9t112.c

re: [media] V4L: soc-camera: make (almost) all client drivers re-usable outside of the framework

2011-11-07 Thread Dan Carpenter
2 so this doesn't work on 64 bit systems. regards, dan carpenter signature.asc Description: Digital signature

Re: [RESEND PATCH 4/14] staging/media/as102: checkpatch fixes

2011-10-29 Thread Dan Carpenter
> This shouldn't be an issue, I've also used patches saved directly form an > e-mail client > which didn't have this text appended and the patch didn't apply in same way. I get this error when I try apply them. patching file drivers/staging/media/as102/as10x_cmd.c pa

Re: [PATCH 1/14] staging/media/as102: initial import from Abilis

2011-10-18 Thread Dan Carpenter
e added to the Kernel > building system > before patch 13/14, as drivers/staging/Makefile wasn't touch on patch 1/14. Ah sorry. My bad. regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to

Re: [PATCH 1/14] staging/media/as102: initial import from Abilis

2011-10-18 Thread Dan Carpenter
ter to separate these two chunks out and put them at the end after you've fixed the compile errors in [PATCH 13/14]. regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

[patch] [media] av7110: wrong limiter in av7110_start_feed()

2011-10-17 Thread Dan Carpenter
ess than DMX_TS_PES_OTHER (20) in the caller function, but I changed it to less than or equal to DMX_TS_PES_PCR (4). Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/ttpci/av7110.c b/drivers/media/dvb/ttpci/av7110.c index 3d20719..abf6b55 100644 --- a/drivers/media/dvb/ttpci/av7110.c +++

Re: [PATCH 4/7] staging/as102: cleanup - formatting code

2011-10-16 Thread Dan Carpenter
s no need to get snarky about it. Julian was replying to problems that a specific patch introduced and everything he said was correct. Piotr was already going to redo the patches anyway. regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the b

[patch v2] Staging: cx25821: off by one in cx25821_vidioc_s_input()

2011-10-12 Thread Dan Carpenter
ot very helpful. Signed-off-by: Dan Carpenter --- v2: Use a define instead of the hard coded number 2 diff --git a/drivers/staging/cx25821/cx25821-video.c b/drivers/staging/cx25821/cx25821-video.c index 084fc08..4d6907c 100644 --- a/drivers/staging/cx25821/cx25821-video.c +++ b/drivers/staging/cx2

Re: [patch] Staging: cx25821: off by on in cx25821_vidioc_s_input()

2011-10-12 Thread Dan Carpenter
Never mind. I figured out what you meant. I've fixed my patch and I will send v2 this evening. regards, dan carpenter -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majord...@vger.kernel.org More majordomo info at http://

Re: [patch] Staging: cx25821: off by on in cx25821_vidioc_s_input()

2011-10-12 Thread Dan Carpenter
821_boards) and use it > here, > instead of a "2" magic number. You're right. The hard coded 2 is not helpful... Why not just an: if (i >= ARRAY_SIZE(cx25821_boards)) {... I'll send a patch to do that. regards, dan carpenter -- To unsubscribe from this lis

[patch] Staging: cx25821: off by on in cx25821_vidioc_s_input()

2011-10-07 Thread Dan Carpenter
If "i" is 2 then when we call cx25821_video_mux() we'd end up going past the end of the cx25821_boards[dev->board]->input[]. The INPUT() macro obfuscates what's going on in that function so it's a bit hard to follow. Signed-off-by: Dan Carpenter --- I don&#

[patch] [media] rc/ir-lirc-codec: cleanup __user tags

2011-10-05 Thread Dan Carpenter
level] * )( ... ) drivers/media/rc/ir-lirc-codec.c:160:23: warning: dereference of noderef expression drivers/media/rc/ir-lirc-codec.c:265:55: warning: dereference of noderef expression drivers/media/rc/ir-lirc-codec.c:269:23: warning: dereference of noderef expression Signed-off-by: Dan Carp

[patch] [media] dib9000: release a lock on error

2011-09-28 Thread Dan Carpenter
This lock should be released as well on the error path. Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/frontends/dib9000.c b/drivers/media/dvb/frontends/dib9000.c index e276b11..660f806 100644 --- a/drivers/media/dvb/frontends/dib9000.c +++ b/drivers/media/dvb/frontends/dib9000.c

[patch] [media] mxl111sf: fix a couple precedence bugs

2011-09-28 Thread Dan Carpenter
Negate has higher precedence than bitwise AND. I2C_M_RD is 0x1 so the original code is equivelent to just checking if (!msg->flags). Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/dvb-usb/mxl111sf-i2c.c b/drivers/media/dvb/dvb-usb/mxl111sf-i2c.c index a330987..2e8c288 100

[patch] [media] ddbridge: fix ddb_ioctl()

2011-08-09 Thread Dan Carpenter
in case this changes later. 6) In the default case where an ioctl is not implemented then returning -ENOTTY is more appropriate than returning -EFAULT. Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/ddbridge/ddbridge-core.c b/drivers/media/dvb/ddbridge/ddbridge-core.c index 573

[patch] [media] dib9000: return error code on failure

2011-08-06 Thread Dan Carpenter
The ret = -EIO needs to be before the goto. Signed-off-by: Dan Carpenter diff --git a/drivers/media/dvb/frontends/dib9000.c b/drivers/media/dvb/frontends/dib9000.c index a085588..01e6b0c 100644 --- a/drivers/media/dvb/frontends/dib9000.c +++ b/drivers/media/dvb/frontends/dib9000.c @@ -1167,8

<    1   2   3   4   5   6   7   8   >