linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/7] [media] si470x: cleanup define namespace
@ 2015-06-24 10:49 Mauro Carvalho Chehab
  2015-06-24 10:49 ` [PATCH 2/7] [media] tuner-i2c: be consistent with I2C declaration Mauro Carvalho Chehab
                   ` (5 more replies)
  0 siblings, 6 replies; 9+ messages in thread
From: Mauro Carvalho Chehab @ 2015-06-24 10:49 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Hans Verkuil,
	Fabio Estevam

Some architectures already use CHIPID defines:

	drivers/media/radio/si470x/radio-si470x.h:57:0: warning: "CHIPID" redefined [enabled by default]
	drivers/media/radio/si470x/radio-si470x.h:57:0: warning: "CHIPID" redefined [enabled by default]
	drivers/media/radio/si470x/radio-si470x.h:57:0: warning: "CHIPID" redefined [enabled by default]

So, use SI_foo namespace to avoid conflicts.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

diff --git a/drivers/media/radio/si470x/radio-si470x-i2c.c b/drivers/media/radio/si470x/radio-si470x-i2c.c
index 49fe8453e218..471d6a8ae8a4 100644
--- a/drivers/media/radio/si470x/radio-si470x-i2c.c
+++ b/drivers/media/radio/si470x/radio-si470x-i2c.c
@@ -384,14 +384,14 @@ static int si470x_i2c_probe(struct i2c_client *client,
 		goto err_radio;
 	}
 	dev_info(&client->dev, "DeviceID=0x%4.4hx ChipID=0x%4.4hx\n",
-			radio->registers[DEVICEID], radio->registers[CHIPID]);
-	if ((radio->registers[CHIPID] & CHIPID_FIRMWARE) < RADIO_FW_VERSION) {
+			radio->registers[DEVICEID], radio->registers[SI_CHIPID]);
+	if ((radio->registers[SI_CHIPID] & SI_CHIPID_FIRMWARE) < RADIO_FW_VERSION) {
 		dev_warn(&client->dev,
 			"This driver is known to work with "
 			"firmware version %hu,\n", RADIO_FW_VERSION);
 		dev_warn(&client->dev,
 			"but the device has firmware version %hu.\n",
-			radio->registers[CHIPID] & CHIPID_FIRMWARE);
+			radio->registers[SI_CHIPID] & SI_CHIPID_FIRMWARE);
 		version_warning = 1;
 	}
 
diff --git a/drivers/media/radio/si470x/radio-si470x-usb.c b/drivers/media/radio/si470x/radio-si470x-usb.c
index 57f0bc3b60e7..091d793f6583 100644
--- a/drivers/media/radio/si470x/radio-si470x-usb.c
+++ b/drivers/media/radio/si470x/radio-si470x-usb.c
@@ -686,14 +686,14 @@ static int si470x_usb_driver_probe(struct usb_interface *intf,
 		goto err_ctrl;
 	}
 	dev_info(&intf->dev, "DeviceID=0x%4.4hx ChipID=0x%4.4hx\n",
-			radio->registers[DEVICEID], radio->registers[CHIPID]);
-	if ((radio->registers[CHIPID] & CHIPID_FIRMWARE) < RADIO_FW_VERSION) {
+			radio->registers[DEVICEID], radio->registers[SI_CHIPID]);
+	if ((radio->registers[SI_CHIPID] & SI_CHIPID_FIRMWARE) < RADIO_FW_VERSION) {
 		dev_warn(&intf->dev,
 			"This driver is known to work with "
 			"firmware version %hu,\n", RADIO_FW_VERSION);
 		dev_warn(&intf->dev,
 			"but the device has firmware version %hu.\n",
-			radio->registers[CHIPID] & CHIPID_FIRMWARE);
+			radio->registers[SI_CHIPID] & SI_CHIPID_FIRMWARE);
 		version_warning = 1;
 	}
 
diff --git a/drivers/media/radio/si470x/radio-si470x.h b/drivers/media/radio/si470x/radio-si470x.h
index 4b7660470e2f..6c0ca900702e 100644
--- a/drivers/media/radio/si470x/radio-si470x.h
+++ b/drivers/media/radio/si470x/radio-si470x.h
@@ -54,10 +54,10 @@
 #define DEVICEID_PN		0xf000	/* bits 15..12: Part Number */
 #define DEVICEID_MFGID		0x0fff	/* bits 11..00: Manufacturer ID */
 
-#define CHIPID			1	/* Chip ID */
-#define CHIPID_REV		0xfc00	/* bits 15..10: Chip Version */
-#define CHIPID_DEV		0x0200	/* bits 09..09: Device */
-#define CHIPID_FIRMWARE		0x01ff	/* bits 08..00: Firmware Version */
+#define SI_CHIPID		1	/* Chip ID */
+#define SI_CHIPID_REV		0xfc00	/* bits 15..10: Chip Version */
+#define SI_CHIPID_DEV		0x0200	/* bits 09..09: Device */
+#define SI_CHIPID_FIRMWARE	0x01ff	/* bits 08..00: Firmware Version */
 
 #define POWERCFG		2	/* Power Configuration */
 #define POWERCFG_DSMUTE		0x8000	/* bits 15..15: Softmute Disable */
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 2/7] [media] tuner-i2c: be consistent with I2C declaration
  2015-06-24 10:49 [PATCH 1/7] [media] si470x: cleanup define namespace Mauro Carvalho Chehab
@ 2015-06-24 10:49 ` Mauro Carvalho Chehab
  2015-06-24 10:49 ` [PATCH 3/7] [media] use CONFIG_PM_SLEEP for suspend/resume Mauro Carvalho Chehab
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 9+ messages in thread
From: Mauro Carvalho Chehab @ 2015-06-24 10:49 UTC (permalink / raw)
  To: Linux Media Mailing List; +Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab

On alpha, gcc warns a log about signed/unsigned ballance, with
produces 3185 warnings. Ok, this is bogus, but it indicates that
the declaration at V4L2 side is not consistent with the one at
I2C.

With this trivial patch, the number of errors reduce to 2959
warnings. Still too much, but it is 7.1% less. So let's do it.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

diff --git a/drivers/media/tuners/tuner-i2c.h b/drivers/media/tuners/tuner-i2c.h
index 18f005634c67..bda67a5a76f2 100644
--- a/drivers/media/tuners/tuner-i2c.h
+++ b/drivers/media/tuners/tuner-i2c.h
@@ -33,7 +33,8 @@ struct tuner_i2c_props {
 	char *name;
 };
 
-static inline int tuner_i2c_xfer_send(struct tuner_i2c_props *props, char *buf, int len)
+static inline int tuner_i2c_xfer_send(struct tuner_i2c_props *props,
+				      unsigned char *buf, int len)
 {
 	struct i2c_msg msg = { .addr = props->addr, .flags = 0,
 			       .buf = buf, .len = len };
@@ -42,7 +43,8 @@ static inline int tuner_i2c_xfer_send(struct tuner_i2c_props *props, char *buf,
 	return (ret == 1) ? len : ret;
 }
 
-static inline int tuner_i2c_xfer_recv(struct tuner_i2c_props *props, char *buf, int len)
+static inline int tuner_i2c_xfer_recv(struct tuner_i2c_props *props,
+				      unsigned char *buf, int len)
 {
 	struct i2c_msg msg = { .addr = props->addr, .flags = I2C_M_RD,
 			       .buf = buf, .len = len };
@@ -52,8 +54,8 @@ static inline int tuner_i2c_xfer_recv(struct tuner_i2c_props *props, char *buf,
 }
 
 static inline int tuner_i2c_xfer_send_recv(struct tuner_i2c_props *props,
-					   char *obuf, int olen,
-					   char *ibuf, int ilen)
+					   unsigned char *obuf, int olen,
+					   unsigned char *ibuf, int ilen)
 {
 	struct i2c_msg msg[2] = { { .addr = props->addr, .flags = 0,
 				    .buf = obuf, .len = olen },
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 3/7] [media] use CONFIG_PM_SLEEP for suspend/resume
  2015-06-24 10:49 [PATCH 1/7] [media] si470x: cleanup define namespace Mauro Carvalho Chehab
  2015-06-24 10:49 ` [PATCH 2/7] [media] tuner-i2c: be consistent with I2C declaration Mauro Carvalho Chehab
@ 2015-06-24 10:49 ` Mauro Carvalho Chehab
  2015-06-24 11:02   ` Maxime Coquelin
  2015-06-24 10:49 ` [PATCH 4/7] [media] saa7134: fix page size on some archs Mauro Carvalho Chehab
                   ` (3 subsequent siblings)
  5 siblings, 1 reply; 9+ messages in thread
From: Mauro Carvalho Chehab @ 2015-06-24 10:49 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab,
	Srinivas Kandagatla, Maxime Coquelin, Patrice Chotard,
	linux-arm-kernel, kernel

Using CONFIG_PM_SLEEP suppress the warnings when the driver is
compiled without PM sleep functions:

drivers/media/rc/st_rc.c:338:12: warning: ‘st_rc_suspend’ defined but not used [-Wunused-function]
drivers/media/rc/st_rc.c:359:12: warning: ‘st_rc_resume’ defined but not used [-Wunused-function]

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

diff --git a/drivers/media/rc/st_rc.c b/drivers/media/rc/st_rc.c
index 979b40561b3a..37d040158dff 100644
--- a/drivers/media/rc/st_rc.c
+++ b/drivers/media/rc/st_rc.c
@@ -334,7 +334,7 @@ err:
 	return ret;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int st_rc_suspend(struct device *dev)
 {
 	struct st_rc_device *rc_dev = dev_get_drvdata(dev);
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 4/7] [media] saa7134: fix page size on some archs
  2015-06-24 10:49 [PATCH 1/7] [media] si470x: cleanup define namespace Mauro Carvalho Chehab
  2015-06-24 10:49 ` [PATCH 2/7] [media] tuner-i2c: be consistent with I2C declaration Mauro Carvalho Chehab
  2015-06-24 10:49 ` [PATCH 3/7] [media] use CONFIG_PM_SLEEP for suspend/resume Mauro Carvalho Chehab
@ 2015-06-24 10:49 ` Mauro Carvalho Chehab
  2015-06-24 10:49 ` [PATCH 5/7] [media] omap3isp: remove unused var Mauro Carvalho Chehab
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 9+ messages in thread
From: Mauro Carvalho Chehab @ 2015-06-24 10:49 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Hans Verkuil

On some archs, like tile, the PAGE_SIZE is not 4K. In the case
of tile arch, it can be either 16KB or 64KB.

Due to that, a warning is produced:
	drivers/media/pci/saa7134/saa7134.h:678:43: warning: large integer implicitly truncated to unsigned type [-Woverflow]

This is actually an error, as it will write trach to the DMA size
registers. The logic at saa7134-ts already does the right thing:

	saa_writeb(SAA7134_TS_DMA0, ((dev->ts.nr_packets-1)&0xff));
	saa_writeb(SAA7134_TS_DMA1, (((dev->ts.nr_packets-1)>>8)&0xff));
	/* TSNOPIT=0, TSCOLAP=0 */
	saa_writeb(SAA7134_TS_DMA2,
		((((dev->ts.nr_packets-1)>>16)&0x3f) | 0x00));

So, fix the driver to take larger page sizes into account.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

diff --git a/drivers/media/pci/saa7134/saa7134-go7007.c b/drivers/media/pci/saa7134/saa7134-go7007.c
index da7c4be4bed2..8a2abb34186b 100644
--- a/drivers/media/pci/saa7134/saa7134-go7007.c
+++ b/drivers/media/pci/saa7134/saa7134-go7007.c
@@ -289,9 +289,9 @@ static int saa7134_go7007_stream_start(struct go7007 *go)
 
 	/* Set up transfer block size */
 	saa_writeb(SAA7134_TS_PARALLEL_SERIAL, 128 - 1);
-	saa_writeb(SAA7134_TS_DMA0, (PAGE_SIZE >> 7) - 1);
-	saa_writeb(SAA7134_TS_DMA1, 0);
-	saa_writeb(SAA7134_TS_DMA2, 0);
+	saa_writeb(SAA7134_TS_DMA0, ((PAGE_SIZE >> 7) - 1) & 0xff);
+	saa_writeb(SAA7134_TS_DMA1, (PAGE_SIZE >> 15) & 0xff);
+	saa_writeb(SAA7134_TS_DMA2, (PAGE_SIZE >> 31) & 0x3f);
 
 	/* Enable video streaming mode */
 	saa_writeb(SAA7134_GPIO_GPSTATUS2, GPIO_COMMAND_VIDEO);
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 5/7] [media] omap3isp: remove unused var
  2015-06-24 10:49 [PATCH 1/7] [media] si470x: cleanup define namespace Mauro Carvalho Chehab
                   ` (2 preceding siblings ...)
  2015-06-24 10:49 ` [PATCH 4/7] [media] saa7134: fix page size on some archs Mauro Carvalho Chehab
@ 2015-06-24 10:49 ` Mauro Carvalho Chehab
  2015-06-25 21:52   ` Laurent Pinchart
  2015-06-24 10:49 ` [PATCH 6/7] [media] lmedm04: use u32 instead of u64 for relative stats Mauro Carvalho Chehab
  2015-06-24 10:49 ` [PATCH 7/7] [media] lmedm04: fix the range for relative measurements Mauro Carvalho Chehab
  5 siblings, 1 reply; 9+ messages in thread
From: Mauro Carvalho Chehab @ 2015-06-24 10:49 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Laurent Pinchart

drivers/media/platform/omap3isp/isppreview.c:932:6: warning: variable ‘features’ set but not used [-Wunused-but-set-variable]

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

diff --git a/drivers/media/platform/omap3isp/isppreview.c b/drivers/media/platform/omap3isp/isppreview.c
index 15cb254ccc39..13803270d104 100644
--- a/drivers/media/platform/omap3isp/isppreview.c
+++ b/drivers/media/platform/omap3isp/isppreview.c
@@ -929,14 +929,10 @@ static void preview_setup_hw(struct isp_prev_device *prev, u32 update,
 			     u32 active)
 {
 	unsigned int i;
-	u32 features;
 
 	if (update == 0)
 		return;
 
-	features = (prev->params.params[0].features & active)
-		 | (prev->params.params[1].features & ~active);
-
 	for (i = 0; i < ARRAY_SIZE(update_attrs); i++) {
 		const struct preview_update *attr = &update_attrs[i];
 		struct prev_params *params;
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 6/7] [media] lmedm04: use u32 instead of u64 for relative stats
  2015-06-24 10:49 [PATCH 1/7] [media] si470x: cleanup define namespace Mauro Carvalho Chehab
                   ` (3 preceding siblings ...)
  2015-06-24 10:49 ` [PATCH 5/7] [media] omap3isp: remove unused var Mauro Carvalho Chehab
@ 2015-06-24 10:49 ` Mauro Carvalho Chehab
  2015-06-24 10:49 ` [PATCH 7/7] [media] lmedm04: fix the range for relative measurements Mauro Carvalho Chehab
  5 siblings, 0 replies; 9+ messages in thread
From: Mauro Carvalho Chehab @ 2015-06-24 10:49 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Malcolm Priestley

Cleanup this sparse warning:
	drivers/media/usb/dvb-usb-v2/lmedm04.c:302 lme2510_update_stats() warn: should '((255 - st->signal_sn - 161) * 3) << 8' be a 64 bit type?

Both c_tmp and s_tmp actually stores a u16 stat. Using a u64 data
there is a waste, specially on u32 archs, as 64 ints there are more
expensive.

So, change the types to u32 and do the typecast only when storing
the result.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

diff --git a/drivers/media/usb/dvb-usb-v2/lmedm04.c b/drivers/media/usb/dvb-usb-v2/lmedm04.c
index 57fb184184bf..fcef2a33ef3d 100644
--- a/drivers/media/usb/dvb-usb-v2/lmedm04.c
+++ b/drivers/media/usb/dvb-usb-v2/lmedm04.c
@@ -262,7 +262,7 @@ static void lme2510_update_stats(struct dvb_usb_adapter *adap)
 	struct lme2510_state *st = adap_to_priv(adap);
 	struct dvb_frontend *fe = adap->fe[0];
 	struct dtv_frontend_properties *c;
-	u64 s_tmp = 0, c_tmp = 0;
+	u32 s_tmp = 0, c_tmp = 0;
 
 	if (!fe)
 		return;
@@ -309,11 +309,11 @@ static void lme2510_update_stats(struct dvb_usb_adapter *adap)
 
 	c->strength.len = 1;
 	c->strength.stat[0].scale = FE_SCALE_RELATIVE;
-	c->strength.stat[0].uvalue = s_tmp;
+	c->strength.stat[0].uvalue = (u64)s_tmp;
 
 	c->cnr.len = 1;
 	c->cnr.stat[0].scale = FE_SCALE_RELATIVE;
-	c->cnr.stat[0].uvalue = c_tmp;
+	c->cnr.stat[0].uvalue = (u64)c_tmp;
 }
 
 static void lme2510_int_response(struct urb *lme_urb)
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 7/7] [media] lmedm04: fix the range for relative measurements
  2015-06-24 10:49 [PATCH 1/7] [media] si470x: cleanup define namespace Mauro Carvalho Chehab
                   ` (4 preceding siblings ...)
  2015-06-24 10:49 ` [PATCH 6/7] [media] lmedm04: use u32 instead of u64 for relative stats Mauro Carvalho Chehab
@ 2015-06-24 10:49 ` Mauro Carvalho Chehab
  5 siblings, 0 replies; 9+ messages in thread
From: Mauro Carvalho Chehab @ 2015-06-24 10:49 UTC (permalink / raw)
  To: Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Mauro Carvalho Chehab, Malcolm Priestley

Relative measurements are typically between 0 and 0xffff. However,
for some tuners (TUNER_S7395 and TUNER_S0194), the range were from
0 to 0xff00, with means that 100% is never archived.
Also, TUNER_RS2000 uses a more complex math.

So, create a macro that does the conversion using bit operations
and use it for all conversions.

The code is also easier to read with is a bonus.

While here, remove a bogus comment.

Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

diff --git a/drivers/media/usb/dvb-usb-v2/lmedm04.c b/drivers/media/usb/dvb-usb-v2/lmedm04.c
index fcef2a33ef3d..befcf97662ca 100644
--- a/drivers/media/usb/dvb-usb-v2/lmedm04.c
+++ b/drivers/media/usb/dvb-usb-v2/lmedm04.c
@@ -257,6 +257,9 @@ static int lme2510_enable_pid(struct dvb_usb_device *d, u8 index, u16 pid_out)
 	return ret;
 }
 
+/* Convert range from 0x00-0xff to 0x0000-0xffff */
+#define reg_to_16bits(x)	((x) | ((x) << 8)
+
 static void lme2510_update_stats(struct dvb_usb_adapter *adap)
 {
 	struct lme2510_state *st = adap_to_priv(adap);
@@ -288,23 +291,17 @@ static void lme2510_update_stats(struct dvb_usb_adapter *adap)
 
 	switch (st->tuner_config) {
 	case TUNER_LG:
-		s_tmp = 0xff - st->signal_level;
-		s_tmp |= s_tmp << 8;
-
-		c_tmp = 0xff - st->signal_sn;
-		c_tmp |= c_tmp << 8;
+		s_tmp = reg_to_16bits(0xff - st->signal_level);
+		c_tmp = reg_to_16bits(0xff - st->signal_sn);
 		break;
-	/* fall through */
 	case TUNER_S7395:
 	case TUNER_S0194:
 		s_tmp = 0xffff - (((st->signal_level * 2) << 8) * 5 / 4);
-
-		c_tmp = ((0xff - st->signal_sn - 0xa1) * 3) << 8;
+		c_tmp = reg_to_16bits((0xff - st->signal_sn - 0xa1) * 3);
 		break;
 	case TUNER_RS2000:
-		s_tmp = st->signal_level * 0xffff / 0xff;
-
-		c_tmp = st->signal_sn * 0xffff / 0x7f;
+		s_tmp = reg_to_16bits(st->signal_level);
+		c_tmp = reg_to_16bits(st->signal_sn);
 	}
 
 	c->strength.len = 1;
-- 
2.4.3


^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [PATCH 3/7] [media] use CONFIG_PM_SLEEP for suspend/resume
  2015-06-24 10:49 ` [PATCH 3/7] [media] use CONFIG_PM_SLEEP for suspend/resume Mauro Carvalho Chehab
@ 2015-06-24 11:02   ` Maxime Coquelin
  0 siblings, 0 replies; 9+ messages in thread
From: Maxime Coquelin @ 2015-06-24 11:02 UTC (permalink / raw)
  To: Mauro Carvalho Chehab, Linux Media Mailing List
  Cc: Mauro Carvalho Chehab, Srinivas Kandagatla, Patrice Chotard,
	linux-arm-kernel, kernel



On 06/24/2015 12:49 PM, Mauro Carvalho Chehab wrote:
> Using CONFIG_PM_SLEEP suppress the warnings when the driver is
> compiled without PM sleep functions:
>
> drivers/media/rc/st_rc.c:338:12: warning: ‘st_rc_suspend’ defined but not used [-Wunused-function]
> drivers/media/rc/st_rc.c:359:12: warning: ‘st_rc_resume’ defined but not used [-Wunused-function]
>
> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>
>
> diff --git a/drivers/media/rc/st_rc.c b/drivers/media/rc/st_rc.c
> index 979b40561b3a..37d040158dff 100644
> --- a/drivers/media/rc/st_rc.c
> +++ b/drivers/media/rc/st_rc.c
> @@ -334,7 +334,7 @@ err:
>   	return ret;
>   }
>   
> -#ifdef CONFIG_PM
> +#ifdef CONFIG_PM_SLEEP
>   static int st_rc_suspend(struct device *dev)
>   {
>   	struct st_rc_device *rc_dev = dev_get_drvdata(dev);
Acked-by: Maxime Coquelin <maxime.coquelin@st.com>

Thanks!
Maxime

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH 5/7] [media] omap3isp: remove unused var
  2015-06-24 10:49 ` [PATCH 5/7] [media] omap3isp: remove unused var Mauro Carvalho Chehab
@ 2015-06-25 21:52   ` Laurent Pinchart
  0 siblings, 0 replies; 9+ messages in thread
From: Laurent Pinchart @ 2015-06-25 21:52 UTC (permalink / raw)
  To: Mauro Carvalho Chehab; +Cc: Linux Media Mailing List, Mauro Carvalho Chehab

Hi Mauro,

On Wednesday 24 June 2015 07:49:09 Mauro Carvalho Chehab wrote:
> drivers/media/platform/omap3isp/isppreview.c:932:6: warning: variable
> ‘features’ set but not used [-Wunused-but-set-variable]
> 
> Signed-off-by: Mauro Carvalho Chehab <mchehab@osg.samsung.com>

Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

On a side note, I'd appreciate if you could wait a couple of days for review 
before committing patches to the media_tree master branch.

Or maybe process pending pull requests for the same driver before fast-
tracking your own patches ;-)

> diff --git a/drivers/media/platform/omap3isp/isppreview.c
> b/drivers/media/platform/omap3isp/isppreview.c index
> 15cb254ccc39..13803270d104 100644
> --- a/drivers/media/platform/omap3isp/isppreview.c
> +++ b/drivers/media/platform/omap3isp/isppreview.c
> @@ -929,14 +929,10 @@ static void preview_setup_hw(struct isp_prev_device
> *prev, u32 update, u32 active)
>  {
>  	unsigned int i;
> -	u32 features;
> 
>  	if (update == 0)
>  		return;
> 
> -	features = (prev->params.params[0].features & active)
> -		 | (prev->params.params[1].features & ~active);
> -
>  	for (i = 0; i < ARRAY_SIZE(update_attrs); i++) {
>  		const struct preview_update *attr = &update_attrs[i];
>  		struct prev_params *params;

-- 
Regards,

Laurent Pinchart


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2015-06-25 21:52 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-06-24 10:49 [PATCH 1/7] [media] si470x: cleanup define namespace Mauro Carvalho Chehab
2015-06-24 10:49 ` [PATCH 2/7] [media] tuner-i2c: be consistent with I2C declaration Mauro Carvalho Chehab
2015-06-24 10:49 ` [PATCH 3/7] [media] use CONFIG_PM_SLEEP for suspend/resume Mauro Carvalho Chehab
2015-06-24 11:02   ` Maxime Coquelin
2015-06-24 10:49 ` [PATCH 4/7] [media] saa7134: fix page size on some archs Mauro Carvalho Chehab
2015-06-24 10:49 ` [PATCH 5/7] [media] omap3isp: remove unused var Mauro Carvalho Chehab
2015-06-25 21:52   ` Laurent Pinchart
2015-06-24 10:49 ` [PATCH 6/7] [media] lmedm04: use u32 instead of u64 for relative stats Mauro Carvalho Chehab
2015-06-24 10:49 ` [PATCH 7/7] [media] lmedm04: fix the range for relative measurements Mauro Carvalho Chehab

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).