All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] bt819: cleanup v4l2_subdev_notify() parameters
@ 2010-01-16 17:08 Németh Márton
  0 siblings, 0 replies; only message in thread
From: Németh Márton @ 2010-01-16 17:08 UTC (permalink / raw)
  To: Mike Bernson, Serguei Miridonov, Ronald Bultje; +Cc: V4L Mailing List

From: Márton Németh <nm127@freemail.hu>

The 3rd parameter v4l2_subdev_notify() is passed to the notify() callback
which is a pointer, see <media/v4l2-subdev.h> and <media/v4l2-device.h>.

This will remove the following sparse warning (see "make C=1"):
 * Using plain integer as NULL pointer

Signed-off-by: Márton Németh <nm127@freemail.hu>
---
diff -r 5bcdcc072b6d linux/drivers/media/video/bt819.c
--- a/linux/drivers/media/video/bt819.c	Sat Jan 16 07:25:43 2010 +0100
+++ b/linux/drivers/media/video/bt819.c	Sat Jan 16 18:04:27 2010 +0100
@@ -260,7 +260,7 @@
 		v4l2_err(sd, "no notify found!\n");

 	if (std & V4L2_STD_NTSC) {
-		v4l2_subdev_notify(sd, BT819_FIFO_RESET_LOW, 0);
+		v4l2_subdev_notify(sd, BT819_FIFO_RESET_LOW, NULL);
 		bt819_setbit(decoder, 0x01, 0, 1);
 		bt819_setbit(decoder, 0x01, 1, 0);
 		bt819_setbit(decoder, 0x01, 5, 0);
@@ -269,7 +269,7 @@
 		/* bt819_setbit(decoder, 0x1a,  5, 1); */
 		timing = &timing_data[1];
 	} else if (std & V4L2_STD_PAL) {
-		v4l2_subdev_notify(sd, BT819_FIFO_RESET_LOW, 0);
+		v4l2_subdev_notify(sd, BT819_FIFO_RESET_LOW, NULL);
 		bt819_setbit(decoder, 0x01, 0, 1);
 		bt819_setbit(decoder, 0x01, 1, 1);
 		bt819_setbit(decoder, 0x01, 5, 1);
@@ -294,7 +294,7 @@
 	bt819_write(decoder, 0x08, (timing->hscale >> 8) & 0xff);
 	bt819_write(decoder, 0x09, timing->hscale & 0xff);
 	decoder->norm = std;
-	v4l2_subdev_notify(sd, BT819_FIFO_RESET_HIGH, 0);
+	v4l2_subdev_notify(sd, BT819_FIFO_RESET_HIGH, NULL);
 	return 0;
 }

@@ -312,7 +312,7 @@
 		v4l2_err(sd, "no notify found!\n");

 	if (decoder->input != input) {
-		v4l2_subdev_notify(sd, BT819_FIFO_RESET_LOW, 0);
+		v4l2_subdev_notify(sd, BT819_FIFO_RESET_LOW, NULL);
 		decoder->input = input;
 		/* select mode */
 		if (decoder->input == 0) {
@@ -322,7 +322,7 @@
 			bt819_setbit(decoder, 0x0b, 6, 1);
 			bt819_setbit(decoder, 0x1a, 1, 0);
 		}
-		v4l2_subdev_notify(sd, BT819_FIFO_RESET_HIGH, 0);
+		v4l2_subdev_notify(sd, BT819_FIFO_RESET_HIGH, NULL);
 	}
 	return 0;
 }

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2010-01-16 17:08 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-01-16 17:08 [PATCH] bt819: cleanup v4l2_subdev_notify() parameters Németh Márton

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.