aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2009-12-10 08:51:38 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-12-15 21:17:57 -0500
commit46b21094cee16bc7e531d7d6cd66fb5ea05065d4 (patch)
tree0076c71aef1f1092934a7536ab18dfccffb13907 /drivers/media
parent50462eb065e12f45851a9959a90d46b758944552 (diff)
V4L/DVB (13556): v4l: Remove unneeded video_device::minor assignments
Now that the video_device registration is tested using video_is_registered(), drivers don't need to initialize the video_device::minor field to -1 anymore. Remove those unneeded assignments. [mchehab.redhat.com: removed tm6000 changes as tm6000 is not ready yet for submission even on staging] Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/video/arv.c1
-rw-r--r--drivers/media/video/au0828/au0828-video.c1
-rw-r--r--drivers/media/video/bt8xx/bttv-driver.c2
-rw-r--r--drivers/media/video/cafe_ccic.c1
-rw-r--r--drivers/media/video/cpia2/cpia2_v4l.c1
-rw-r--r--drivers/media/video/cx231xx/cx231xx-video.c3
-rw-r--r--drivers/media/video/cx23885/cx23885-417.c1
-rw-r--r--drivers/media/video/cx23885/cx23885-video.c2
-rw-r--r--drivers/media/video/cx88/cx88-blackbird.c1
-rw-r--r--drivers/media/video/cx88/cx88-video.c2
-rw-r--r--drivers/media/video/davinci/vpfe_capture.c1
-rw-r--r--drivers/media/video/davinci/vpif_display.c1
-rw-r--r--drivers/media/video/em28xx/em28xx-video.c4
-rw-r--r--drivers/media/video/et61x251/et61x251_core.c1
-rw-r--r--drivers/media/video/gspca/gspca.c1
-rw-r--r--drivers/media/video/meye.c1
-rw-r--r--drivers/media/video/omap24xxcam.c2
-rw-r--r--drivers/media/video/ov511.c1
-rw-r--r--drivers/media/video/pwc/pwc-if.c1
-rw-r--r--drivers/media/video/s2255drv.c1
-rw-r--r--drivers/media/video/saa5246a.c1
-rw-r--r--drivers/media/video/saa7134/saa7134-empress.c1
-rw-r--r--drivers/media/video/saa7134/saa7134-video.c2
-rw-r--r--drivers/media/video/sn9c102/sn9c102_core.c1
-rw-r--r--drivers/media/video/soc_camera.c4
-rw-r--r--drivers/media/video/stk-webcam.c1
-rw-r--r--drivers/media/video/stradis.c2
-rw-r--r--drivers/media/video/stv680.c1
-rw-r--r--drivers/media/video/usbvideo/vicam.c1
-rw-r--r--drivers/media/video/usbvision/usbvision-video.c4
-rw-r--r--drivers/media/video/uvc/uvc_driver.c1
-rw-r--r--drivers/media/video/vino.c1
-rw-r--r--drivers/media/video/vivi.c1
-rw-r--r--drivers/media/video/w9968cf.c1
-rw-r--r--drivers/media/video/zc0301/zc0301_core.c1
-rw-r--r--drivers/media/video/zoran/zoran_driver.c1
-rw-r--r--drivers/media/video/zr364xx.c1
37 files changed, 1 insertions, 53 deletions
diff --git a/drivers/media/video/arv.c b/drivers/media/video/arv.c
index 0ec807d82795..a356d6bd3131 100644
--- a/drivers/media/video/arv.c
+++ b/drivers/media/video/arv.c
@@ -767,7 +767,6 @@ static struct video_device ar_template = {
767 .name = "Colour AR VGA", 767 .name = "Colour AR VGA",
768 .fops = &ar_fops, 768 .fops = &ar_fops,
769 .release = ar_release, 769 .release = ar_release,
770 .minor = -1,
771}; 770};
772 771
773#define ALIGN4(x) ((((int)(x)) & 0x3) == 0) 772#define ALIGN4(x) ((((int)(x)) & 0x3) == 0)
diff --git a/drivers/media/video/au0828/au0828-video.c b/drivers/media/video/au0828/au0828-video.c
index 13a8a1db5349..dc67bc40f36f 100644
--- a/drivers/media/video/au0828/au0828-video.c
+++ b/drivers/media/video/au0828/au0828-video.c
@@ -1570,7 +1570,6 @@ static const struct video_device au0828_video_template = {
1570 .fops = &au0828_v4l_fops, 1570 .fops = &au0828_v4l_fops,
1571 .release = video_device_release, 1571 .release = video_device_release,
1572 .ioctl_ops = &video_ioctl_ops, 1572 .ioctl_ops = &video_ioctl_ops,
1573 .minor = -1,
1574 .tvnorms = V4L2_STD_NTSC_M, 1573 .tvnorms = V4L2_STD_NTSC_M,
1575 .current_norm = V4L2_STD_NTSC_M, 1574 .current_norm = V4L2_STD_NTSC_M,
1576}; 1575};
diff --git a/drivers/media/video/bt8xx/bttv-driver.c b/drivers/media/video/bt8xx/bttv-driver.c
index dcad2f7a995c..410260a1c364 100644
--- a/drivers/media/video/bt8xx/bttv-driver.c
+++ b/drivers/media/video/bt8xx/bttv-driver.c
@@ -3398,7 +3398,6 @@ static const struct v4l2_ioctl_ops bttv_ioctl_ops = {
3398 3398
3399static struct video_device bttv_video_template = { 3399static struct video_device bttv_video_template = {
3400 .fops = &bttv_fops, 3400 .fops = &bttv_fops,
3401 .minor = -1,
3402 .ioctl_ops = &bttv_ioctl_ops, 3401 .ioctl_ops = &bttv_ioctl_ops,
3403 .tvnorms = BTTV_NORMS, 3402 .tvnorms = BTTV_NORMS,
3404 .current_norm = V4L2_STD_PAL, 3403 .current_norm = V4L2_STD_PAL,
@@ -3642,7 +3641,6 @@ static const struct v4l2_ioctl_ops radio_ioctl_ops = {
3642 3641
3643static struct video_device radio_template = { 3642static struct video_device radio_template = {
3644 .fops = &radio_fops, 3643 .fops = &radio_fops,
3645 .minor = -1,
3646 .ioctl_ops = &radio_ioctl_ops, 3644 .ioctl_ops = &radio_ioctl_ops,
3647}; 3645};
3648 3646
diff --git a/drivers/media/video/cafe_ccic.c b/drivers/media/video/cafe_ccic.c
index 10230cb3d210..7bb9c1ec7819 100644
--- a/drivers/media/video/cafe_ccic.c
+++ b/drivers/media/video/cafe_ccic.c
@@ -1723,7 +1723,6 @@ static const struct v4l2_ioctl_ops cafe_v4l_ioctl_ops = {
1723 1723
1724static struct video_device cafe_v4l_template = { 1724static struct video_device cafe_v4l_template = {
1725 .name = "cafe", 1725 .name = "cafe",
1726 .minor = -1, /* Get one dynamically */
1727 .tvnorms = V4L2_STD_NTSC_M, 1726 .tvnorms = V4L2_STD_NTSC_M,
1728 .current_norm = V4L2_STD_NTSC_M, /* make mplayer happy */ 1727 .current_norm = V4L2_STD_NTSC_M, /* make mplayer happy */
1729 1728
diff --git a/drivers/media/video/cpia2/cpia2_v4l.c b/drivers/media/video/cpia2/cpia2_v4l.c
index f8952af30a3c..30d39b15fd4b 100644
--- a/drivers/media/video/cpia2/cpia2_v4l.c
+++ b/drivers/media/video/cpia2/cpia2_v4l.c
@@ -1926,7 +1926,6 @@ static const struct v4l2_file_operations fops_template = {
1926static struct video_device cpia2_template = { 1926static struct video_device cpia2_template = {
1927 /* I could not find any place for the old .initialize initializer?? */ 1927 /* I could not find any place for the old .initialize initializer?? */
1928 .name= "CPiA2 Camera", 1928 .name= "CPiA2 Camera",
1929 .minor= -1,
1930 .fops= &fops_template, 1929 .fops= &fops_template,
1931 .release= video_device_release, 1930 .release= video_device_release,
1932}; 1931};
diff --git a/drivers/media/video/cx231xx/cx231xx-video.c b/drivers/media/video/cx231xx/cx231xx-video.c
index 552dff5d6f1d..d4f546f11d74 100644
--- a/drivers/media/video/cx231xx/cx231xx-video.c
+++ b/drivers/media/video/cx231xx/cx231xx-video.c
@@ -2277,7 +2277,6 @@ static const struct video_device cx231xx_video_template = {
2277 .fops = &cx231xx_v4l_fops, 2277 .fops = &cx231xx_v4l_fops,
2278 .release = video_device_release, 2278 .release = video_device_release,
2279 .ioctl_ops = &video_ioctl_ops, 2279 .ioctl_ops = &video_ioctl_ops,
2280 .minor = -1,
2281 .tvnorms = V4L2_STD_ALL, 2280 .tvnorms = V4L2_STD_ALL,
2282 .current_norm = V4L2_STD_PAL, 2281 .current_norm = V4L2_STD_PAL,
2283}; 2282};
@@ -2312,7 +2311,6 @@ static struct video_device cx231xx_radio_template = {
2312 .name = "cx231xx-radio", 2311 .name = "cx231xx-radio",
2313 .fops = &radio_fops, 2312 .fops = &radio_fops,
2314 .ioctl_ops = &radio_ioctl_ops, 2313 .ioctl_ops = &radio_ioctl_ops,
2315 .minor = -1,
2316}; 2314};
2317 2315
2318/******************************** usb interface ******************************/ 2316/******************************** usb interface ******************************/
@@ -2328,7 +2326,6 @@ static struct video_device *cx231xx_vdev_init(struct cx231xx *dev,
2328 return NULL; 2326 return NULL;
2329 2327
2330 *vfd = *template; 2328 *vfd = *template;
2331 vfd->minor = -1;
2332 vfd->v4l2_dev = &dev->v4l2_dev; 2329 vfd->v4l2_dev = &dev->v4l2_dev;
2333 vfd->release = video_device_release; 2330 vfd->release = video_device_release;
2334 vfd->debug = video_debug; 2331 vfd->debug = video_debug;
diff --git a/drivers/media/video/cx23885/cx23885-417.c b/drivers/media/video/cx23885/cx23885-417.c
index 272c60a993b5..88c0d2481118 100644
--- a/drivers/media/video/cx23885/cx23885-417.c
+++ b/drivers/media/video/cx23885/cx23885-417.c
@@ -1721,7 +1721,6 @@ static struct video_device cx23885_mpeg_template = {
1721 .name = "cx23885", 1721 .name = "cx23885",
1722 .fops = &mpeg_fops, 1722 .fops = &mpeg_fops,
1723 .ioctl_ops = &mpeg_ioctl_ops, 1723 .ioctl_ops = &mpeg_ioctl_ops,
1724 .minor = -1,
1725 .tvnorms = CX23885_NORMS, 1724 .tvnorms = CX23885_NORMS,
1726 .current_norm = V4L2_STD_NTSC_M, 1725 .current_norm = V4L2_STD_NTSC_M,
1727}; 1726};
diff --git a/drivers/media/video/cx23885/cx23885-video.c b/drivers/media/video/cx23885/cx23885-video.c
index e8ca8bb384d2..8934d61cf660 100644
--- a/drivers/media/video/cx23885/cx23885-video.c
+++ b/drivers/media/video/cx23885/cx23885-video.c
@@ -318,7 +318,6 @@ static struct video_device *cx23885_vdev_init(struct cx23885_dev *dev,
318 if (NULL == vfd) 318 if (NULL == vfd)
319 return NULL; 319 return NULL;
320 *vfd = *template; 320 *vfd = *template;
321 vfd->minor = -1;
322 vfd->v4l2_dev = &dev->v4l2_dev; 321 vfd->v4l2_dev = &dev->v4l2_dev;
323 vfd->release = video_device_release; 322 vfd->release = video_device_release;
324 snprintf(vfd->name, sizeof(vfd->name), "%s %s (%s)", 323 snprintf(vfd->name, sizeof(vfd->name), "%s %s (%s)",
@@ -1430,7 +1429,6 @@ static struct video_device cx23885_vbi_template;
1430static struct video_device cx23885_video_template = { 1429static struct video_device cx23885_video_template = {
1431 .name = "cx23885-video", 1430 .name = "cx23885-video",
1432 .fops = &video_fops, 1431 .fops = &video_fops,
1433 .minor = -1,
1434 .ioctl_ops = &video_ioctl_ops, 1432 .ioctl_ops = &video_ioctl_ops,
1435 .tvnorms = CX23885_NORMS, 1433 .tvnorms = CX23885_NORMS,
1436 .current_norm = V4L2_STD_NTSC_M, 1434 .current_norm = V4L2_STD_NTSC_M,
diff --git a/drivers/media/video/cx88/cx88-blackbird.c b/drivers/media/video/cx88/cx88-blackbird.c
index 03e592e016fe..6fe30e6c4262 100644
--- a/drivers/media/video/cx88/cx88-blackbird.c
+++ b/drivers/media/video/cx88/cx88-blackbird.c
@@ -1210,7 +1210,6 @@ static struct video_device cx8802_mpeg_template = {
1210 .name = "cx8802", 1210 .name = "cx8802",
1211 .fops = &mpeg_fops, 1211 .fops = &mpeg_fops,
1212 .ioctl_ops = &mpeg_ioctl_ops, 1212 .ioctl_ops = &mpeg_ioctl_ops,
1213 .minor = -1,
1214 .tvnorms = CX88_NORMS, 1213 .tvnorms = CX88_NORMS,
1215 .current_norm = V4L2_STD_NTSC_M, 1214 .current_norm = V4L2_STD_NTSC_M,
1216}; 1215};
diff --git a/drivers/media/video/cx88/cx88-video.c b/drivers/media/video/cx88/cx88-video.c
index 0013cb4d756a..48c450f4a85a 100644
--- a/drivers/media/video/cx88/cx88-video.c
+++ b/drivers/media/video/cx88/cx88-video.c
@@ -1722,7 +1722,6 @@ static struct video_device cx8800_vbi_template;
1722static struct video_device cx8800_video_template = { 1722static struct video_device cx8800_video_template = {
1723 .name = "cx8800-video", 1723 .name = "cx8800-video",
1724 .fops = &video_fops, 1724 .fops = &video_fops,
1725 .minor = -1,
1726 .ioctl_ops = &video_ioctl_ops, 1725 .ioctl_ops = &video_ioctl_ops,
1727 .tvnorms = CX88_NORMS, 1726 .tvnorms = CX88_NORMS,
1728 .current_norm = V4L2_STD_NTSC_M, 1727 .current_norm = V4L2_STD_NTSC_M,
@@ -1758,7 +1757,6 @@ static const struct v4l2_ioctl_ops radio_ioctl_ops = {
1758static struct video_device cx8800_radio_template = { 1757static struct video_device cx8800_radio_template = {
1759 .name = "cx8800-radio", 1758 .name = "cx8800-radio",
1760 .fops = &radio_fops, 1759 .fops = &radio_fops,
1761 .minor = -1,
1762 .ioctl_ops = &radio_ioctl_ops, 1760 .ioctl_ops = &radio_ioctl_ops,
1763}; 1761};
1764 1762
diff --git a/drivers/media/video/davinci/vpfe_capture.c b/drivers/media/video/davinci/vpfe_capture.c
index 1e8579438ef5..f2d3c9b6df10 100644
--- a/drivers/media/video/davinci/vpfe_capture.c
+++ b/drivers/media/video/davinci/vpfe_capture.c
@@ -1967,7 +1967,6 @@ static __init int vpfe_probe(struct platform_device *pdev)
1967 vfd->release = video_device_release; 1967 vfd->release = video_device_release;
1968 vfd->fops = &vpfe_fops; 1968 vfd->fops = &vpfe_fops;
1969 vfd->ioctl_ops = &vpfe_ioctl_ops; 1969 vfd->ioctl_ops = &vpfe_ioctl_ops;
1970 vfd->minor = -1;
1971 vfd->tvnorms = 0; 1970 vfd->tvnorms = 0;
1972 vfd->current_norm = V4L2_STD_PAL; 1971 vfd->current_norm = V4L2_STD_PAL;
1973 vfd->v4l2_dev = &vpfe_dev->v4l2_dev; 1972 vfd->v4l2_dev = &vpfe_dev->v4l2_dev;
diff --git a/drivers/media/video/davinci/vpif_display.c b/drivers/media/video/davinci/vpif_display.c
index d14cfb200ed0..dfddef7228dd 100644
--- a/drivers/media/video/davinci/vpif_display.c
+++ b/drivers/media/video/davinci/vpif_display.c
@@ -1347,7 +1347,6 @@ static const struct v4l2_file_operations vpif_fops = {
1347static struct video_device vpif_video_template = { 1347static struct video_device vpif_video_template = {
1348 .name = "vpif", 1348 .name = "vpif",
1349 .fops = &vpif_fops, 1349 .fops = &vpif_fops,
1350 .minor = -1,
1351 .ioctl_ops = &vpif_ioctl_ops, 1350 .ioctl_ops = &vpif_ioctl_ops,
1352 .tvnorms = DM646X_V4L2_STD, 1351 .tvnorms = DM646X_V4L2_STD,
1353 .current_norm = V4L2_STD_625_50, 1352 .current_norm = V4L2_STD_625_50,
diff --git a/drivers/media/video/em28xx/em28xx-video.c b/drivers/media/video/em28xx/em28xx-video.c
index 0408727b79c6..849b18c94037 100644
--- a/drivers/media/video/em28xx/em28xx-video.c
+++ b/drivers/media/video/em28xx/em28xx-video.c
@@ -2405,8 +2405,6 @@ static const struct video_device em28xx_video_template = {
2405 .release = video_device_release, 2405 .release = video_device_release,
2406 .ioctl_ops = &video_ioctl_ops, 2406 .ioctl_ops = &video_ioctl_ops,
2407 2407
2408 .minor = -1,
2409
2410 .tvnorms = V4L2_STD_ALL, 2408 .tvnorms = V4L2_STD_ALL,
2411 .current_norm = V4L2_STD_PAL, 2409 .current_norm = V4L2_STD_PAL,
2412}; 2410};
@@ -2441,7 +2439,6 @@ static struct video_device em28xx_radio_template = {
2441 .name = "em28xx-radio", 2439 .name = "em28xx-radio",
2442 .fops = &radio_fops, 2440 .fops = &radio_fops,
2443 .ioctl_ops = &radio_ioctl_ops, 2441 .ioctl_ops = &radio_ioctl_ops,
2444 .minor = -1,
2445}; 2442};
2446 2443
2447/******************************** usb interface ******************************/ 2444/******************************** usb interface ******************************/
@@ -2459,7 +2456,6 @@ static struct video_device *em28xx_vdev_init(struct em28xx *dev,
2459 return NULL; 2456 return NULL;
2460 2457
2461 *vfd = *template; 2458 *vfd = *template;
2462 vfd->minor = -1;
2463 vfd->v4l2_dev = &dev->v4l2_dev; 2459 vfd->v4l2_dev = &dev->v4l2_dev;
2464 vfd->release = video_device_release; 2460 vfd->release = video_device_release;
2465 vfd->debug = video_debug; 2461 vfd->debug = video_debug;
diff --git a/drivers/media/video/et61x251/et61x251_core.c b/drivers/media/video/et61x251/et61x251_core.c
index f561a1c86791..e6c23d509862 100644
--- a/drivers/media/video/et61x251/et61x251_core.c
+++ b/drivers/media/video/et61x251/et61x251_core.c
@@ -2587,7 +2587,6 @@ et61x251_usb_probe(struct usb_interface* intf, const struct usb_device_id* id)
2587 2587
2588 strcpy(cam->v4ldev->name, "ET61X[12]51 PC Camera"); 2588 strcpy(cam->v4ldev->name, "ET61X[12]51 PC Camera");
2589 cam->v4ldev->fops = &et61x251_fops; 2589 cam->v4ldev->fops = &et61x251_fops;
2590 cam->v4ldev->minor = video_nr[dev_nr];
2591 cam->v4ldev->release = video_device_release; 2590 cam->v4ldev->release = video_device_release;
2592 cam->v4ldev->parent = &udev->dev; 2591 cam->v4ldev->parent = &udev->dev;
2593 video_set_drvdata(cam->v4ldev, cam); 2592 video_set_drvdata(cam->v4ldev, cam);
diff --git a/drivers/media/video/gspca/gspca.c b/drivers/media/video/gspca/gspca.c
index 6af4f233bf52..9724e65d6485 100644
--- a/drivers/media/video/gspca/gspca.c
+++ b/drivers/media/video/gspca/gspca.c
@@ -1989,7 +1989,6 @@ static struct video_device gspca_template = {
1989 .fops = &dev_fops, 1989 .fops = &dev_fops,
1990 .ioctl_ops = &dev_ioctl_ops, 1990 .ioctl_ops = &dev_ioctl_ops,
1991 .release = gspca_release, 1991 .release = gspca_release,
1992 .minor = -1,
1993}; 1992};
1994 1993
1995/* 1994/*
diff --git a/drivers/media/video/meye.c b/drivers/media/video/meye.c
index 01e1eefcf1eb..6ffa64cd1c6d 100644
--- a/drivers/media/video/meye.c
+++ b/drivers/media/video/meye.c
@@ -1681,7 +1681,6 @@ static struct video_device meye_template = {
1681 .fops = &meye_fops, 1681 .fops = &meye_fops,
1682 .ioctl_ops = &meye_ioctl_ops, 1682 .ioctl_ops = &meye_ioctl_ops,
1683 .release = video_device_release, 1683 .release = video_device_release,
1684 .minor = -1,
1685}; 1684};
1686 1685
1687#ifdef CONFIG_PM 1686#ifdef CONFIG_PM
diff --git a/drivers/media/video/omap24xxcam.c b/drivers/media/video/omap24xxcam.c
index 34eb96594333..71e08be7960c 100644
--- a/drivers/media/video/omap24xxcam.c
+++ b/drivers/media/video/omap24xxcam.c
@@ -1660,7 +1660,6 @@ static int omap24xxcam_device_register(struct v4l2_int_device *s)
1660 1660
1661 strlcpy(vfd->name, CAM_NAME, sizeof(vfd->name)); 1661 strlcpy(vfd->name, CAM_NAME, sizeof(vfd->name));
1662 vfd->fops = &omap24xxcam_fops; 1662 vfd->fops = &omap24xxcam_fops;
1663 vfd->minor = -1;
1664 vfd->ioctl_ops = &omap24xxcam_ioctl_fops; 1663 vfd->ioctl_ops = &omap24xxcam_ioctl_fops;
1665 1664
1666 omap24xxcam_hwinit(cam); 1665 omap24xxcam_hwinit(cam);
@@ -1671,7 +1670,6 @@ static int omap24xxcam_device_register(struct v4l2_int_device *s)
1671 1670
1672 if (video_register_device(vfd, VFL_TYPE_GRABBER, video_nr) < 0) { 1671 if (video_register_device(vfd, VFL_TYPE_GRABBER, video_nr) < 0) {
1673 dev_err(cam->dev, "could not register V4L device\n"); 1672 dev_err(cam->dev, "could not register V4L device\n");
1674 vfd->minor = -1;
1675 rval = -EBUSY; 1673 rval = -EBUSY;
1676 goto err; 1674 goto err;
1677 } 1675 }
diff --git a/drivers/media/video/ov511.c b/drivers/media/video/ov511.c
index 939ae8bf58d5..c71865dcf48e 100644
--- a/drivers/media/video/ov511.c
+++ b/drivers/media/video/ov511.c
@@ -4674,7 +4674,6 @@ static struct video_device vdev_template = {
4674 .name = "OV511 USB Camera", 4674 .name = "OV511 USB Camera",
4675 .fops = &ov511_fops, 4675 .fops = &ov511_fops,
4676 .release = video_device_release, 4676 .release = video_device_release,
4677 .minor = -1,
4678}; 4677};
4679 4678
4680/**************************************************************************** 4679/****************************************************************************
diff --git a/drivers/media/video/pwc/pwc-if.c b/drivers/media/video/pwc/pwc-if.c
index 819cf4e7c581..d0e2b57f1747 100644
--- a/drivers/media/video/pwc/pwc-if.c
+++ b/drivers/media/video/pwc/pwc-if.c
@@ -169,7 +169,6 @@ static struct video_device pwc_template = {
169 .name = "Philips Webcam", /* Filled in later */ 169 .name = "Philips Webcam", /* Filled in later */
170 .release = video_device_release, 170 .release = video_device_release,
171 .fops = &pwc_fops, 171 .fops = &pwc_fops,
172 .minor = -1,
173}; 172};
174 173
175/***************************************************************************/ 174/***************************************************************************/
diff --git a/drivers/media/video/s2255drv.c b/drivers/media/video/s2255drv.c
index f6a4929867db..fb742f1ae711 100644
--- a/drivers/media/video/s2255drv.c
+++ b/drivers/media/video/s2255drv.c
@@ -1816,7 +1816,6 @@ static struct video_device template = {
1816 .name = "s2255v", 1816 .name = "s2255v",
1817 .fops = &s2255_fops_v4l, 1817 .fops = &s2255_fops_v4l,
1818 .ioctl_ops = &s2255_ioctl_ops, 1818 .ioctl_ops = &s2255_ioctl_ops,
1819 .minor = -1,
1820 .release = video_device_release, 1819 .release = video_device_release,
1821 .tvnorms = S2255_NORMS, 1820 .tvnorms = S2255_NORMS,
1822 .current_norm = V4L2_STD_NTSC_M, 1821 .current_norm = V4L2_STD_NTSC_M,
diff --git a/drivers/media/video/saa5246a.c b/drivers/media/video/saa5246a.c
index b624a4c01fdc..5ab6a0f901c0 100644
--- a/drivers/media/video/saa5246a.c
+++ b/drivers/media/video/saa5246a.c
@@ -1036,7 +1036,6 @@ static struct video_device saa_template =
1036 .name = "saa5246a", 1036 .name = "saa5246a",
1037 .fops = &saa_fops, 1037 .fops = &saa_fops,
1038 .release = video_device_release, 1038 .release = video_device_release,
1039 .minor = -1,
1040}; 1039};
1041 1040
1042static int saa5246a_g_chip_ident(struct v4l2_subdev *sd, struct v4l2_dbg_chip_ident *chip) 1041static int saa5246a_g_chip_ident(struct v4l2_subdev *sd, struct v4l2_dbg_chip_ident *chip)
diff --git a/drivers/media/video/saa7134/saa7134-empress.c b/drivers/media/video/saa7134/saa7134-empress.c
index df56241b30a4..7dfecfc6017c 100644
--- a/drivers/media/video/saa7134/saa7134-empress.c
+++ b/drivers/media/video/saa7134/saa7134-empress.c
@@ -481,7 +481,6 @@ static const struct v4l2_ioctl_ops ts_ioctl_ops = {
481static struct video_device saa7134_empress_template = { 481static struct video_device saa7134_empress_template = {
482 .name = "saa7134-empress", 482 .name = "saa7134-empress",
483 .fops = &ts_fops, 483 .fops = &ts_fops,
484 .minor = -1,
485 .ioctl_ops = &ts_ioctl_ops, 484 .ioctl_ops = &ts_ioctl_ops,
486 485
487 .tvnorms = SAA7134_NORMS, 486 .tvnorms = SAA7134_NORMS,
diff --git a/drivers/media/video/saa7134/saa7134-video.c b/drivers/media/video/saa7134/saa7134-video.c
index 9d26b1bd732e..cb732640ac4a 100644
--- a/drivers/media/video/saa7134/saa7134-video.c
+++ b/drivers/media/video/saa7134/saa7134-video.c
@@ -2495,7 +2495,6 @@ struct video_device saa7134_video_template = {
2495 .name = "saa7134-video", 2495 .name = "saa7134-video",
2496 .fops = &video_fops, 2496 .fops = &video_fops,
2497 .ioctl_ops = &video_ioctl_ops, 2497 .ioctl_ops = &video_ioctl_ops,
2498 .minor = -1,
2499 .tvnorms = SAA7134_NORMS, 2498 .tvnorms = SAA7134_NORMS,
2500 .current_norm = V4L2_STD_PAL, 2499 .current_norm = V4L2_STD_PAL,
2501}; 2500};
@@ -2504,7 +2503,6 @@ struct video_device saa7134_radio_template = {
2504 .name = "saa7134-radio", 2503 .name = "saa7134-radio",
2505 .fops = &radio_fops, 2504 .fops = &radio_fops,
2506 .ioctl_ops = &radio_ioctl_ops, 2505 .ioctl_ops = &radio_ioctl_ops,
2507 .minor = -1,
2508}; 2506};
2509 2507
2510int saa7134_video_init1(struct saa7134_dev *dev) 2508int saa7134_video_init1(struct saa7134_dev *dev)
diff --git a/drivers/media/video/sn9c102/sn9c102_core.c b/drivers/media/video/sn9c102/sn9c102_core.c
index 4cf41a8d44ed..cbf8087b286f 100644
--- a/drivers/media/video/sn9c102/sn9c102_core.c
+++ b/drivers/media/video/sn9c102/sn9c102_core.c
@@ -3329,7 +3329,6 @@ sn9c102_usb_probe(struct usb_interface* intf, const struct usb_device_id* id)
3329 3329
3330 strcpy(cam->v4ldev->name, "SN9C1xx PC Camera"); 3330 strcpy(cam->v4ldev->name, "SN9C1xx PC Camera");
3331 cam->v4ldev->fops = &sn9c102_fops; 3331 cam->v4ldev->fops = &sn9c102_fops;
3332 cam->v4ldev->minor = video_nr[dev_nr];
3333 cam->v4ldev->release = video_device_release; 3332 cam->v4ldev->release = video_device_release;
3334 cam->v4ldev->parent = &udev->dev; 3333 cam->v4ldev->parent = &udev->dev;
3335 3334
diff --git a/drivers/media/video/soc_camera.c b/drivers/media/video/soc_camera.c
index 95fdeb23c2c1..804c675f2cb9 100644
--- a/drivers/media/video/soc_camera.c
+++ b/drivers/media/video/soc_camera.c
@@ -1268,7 +1268,6 @@ static int video_dev_create(struct soc_camera_device *icd)
1268 vdev->fops = &soc_camera_fops; 1268 vdev->fops = &soc_camera_fops;
1269 vdev->ioctl_ops = &soc_camera_ioctl_ops; 1269 vdev->ioctl_ops = &soc_camera_ioctl_ops;
1270 vdev->release = video_device_release; 1270 vdev->release = video_device_release;
1271 vdev->minor = -1;
1272 vdev->tvnorms = V4L2_STD_UNKNOWN; 1271 vdev->tvnorms = V4L2_STD_UNKNOWN;
1273 1272
1274 icd->vdev = vdev; 1273 icd->vdev = vdev;
@@ -1291,8 +1290,7 @@ static int soc_camera_video_start(struct soc_camera_device *icd)
1291 !icd->ops->set_bus_param) 1290 !icd->ops->set_bus_param)
1292 return -EINVAL; 1291 return -EINVAL;
1293 1292
1294 ret = video_register_device(icd->vdev, VFL_TYPE_GRABBER, 1293 ret = video_register_device(icd->vdev, VFL_TYPE_GRABBER, -1);
1295 icd->vdev->minor);
1296 if (ret < 0) { 1294 if (ret < 0) {
1297 dev_err(&icd->dev, "video_register_device failed: %d\n", ret); 1295 dev_err(&icd->dev, "video_register_device failed: %d\n", ret);
1298 return ret; 1296 return ret;
diff --git a/drivers/media/video/stk-webcam.c b/drivers/media/video/stk-webcam.c
index 6590b9299315..f07a0f6b71c4 100644
--- a/drivers/media/video/stk-webcam.c
+++ b/drivers/media/video/stk-webcam.c
@@ -1307,7 +1307,6 @@ static void stk_v4l_dev_release(struct video_device *vd)
1307 1307
1308static struct video_device stk_v4l_data = { 1308static struct video_device stk_v4l_data = {
1309 .name = "stkwebcam", 1309 .name = "stkwebcam",
1310 .minor = -1,
1311 .tvnorms = V4L2_STD_UNKNOWN, 1310 .tvnorms = V4L2_STD_UNKNOWN,
1312 .current_norm = V4L2_STD_UNKNOWN, 1311 .current_norm = V4L2_STD_UNKNOWN,
1313 .fops = &v4l_stk_fops, 1312 .fops = &v4l_stk_fops,
diff --git a/drivers/media/video/stradis.c b/drivers/media/video/stradis.c
index c8909056215c..a057824e7ebc 100644
--- a/drivers/media/video/stradis.c
+++ b/drivers/media/video/stradis.c
@@ -1921,7 +1921,6 @@ static const struct v4l2_file_operations saa_fops = {
1921static struct video_device saa_template = { 1921static struct video_device saa_template = {
1922 .name = "SAA7146A", 1922 .name = "SAA7146A",
1923 .fops = &saa_fops, 1923 .fops = &saa_fops,
1924 .minor = -1,
1925 .release = video_device_release_empty, 1924 .release = video_device_release_empty,
1926}; 1925};
1927 1926
@@ -1972,7 +1971,6 @@ static int __devinit configure_saa7146(struct pci_dev *pdev, int num)
1972 1971
1973 saa->id = pdev->device; 1972 saa->id = pdev->device;
1974 saa->irq = pdev->irq; 1973 saa->irq = pdev->irq;
1975 saa->video_dev.minor = -1;
1976 saa->saa7146_adr = pci_resource_start(pdev, 0); 1974 saa->saa7146_adr = pci_resource_start(pdev, 0);
1977 pci_read_config_byte(pdev, PCI_CLASS_REVISION, &saa->revision); 1975 pci_read_config_byte(pdev, PCI_CLASS_REVISION, &saa->revision);
1978 1976
diff --git a/drivers/media/video/stv680.c b/drivers/media/video/stv680.c
index b54222232cd3..5938ad8702ef 100644
--- a/drivers/media/video/stv680.c
+++ b/drivers/media/video/stv680.c
@@ -1405,7 +1405,6 @@ static struct video_device stv680_template = {
1405 .name = "STV0680 USB camera", 1405 .name = "STV0680 USB camera",
1406 .fops = &stv680_fops, 1406 .fops = &stv680_fops,
1407 .release = video_device_release, 1407 .release = video_device_release,
1408 .minor = -1,
1409}; 1408};
1410 1409
1411static int stv680_probe (struct usb_interface *intf, const struct usb_device_id *id) 1410static int stv680_probe (struct usb_interface *intf, const struct usb_device_id *id)
diff --git a/drivers/media/video/usbvideo/vicam.c b/drivers/media/video/usbvideo/vicam.c
index b75143ee5dd8..6030410c6677 100644
--- a/drivers/media/video/usbvideo/vicam.c
+++ b/drivers/media/video/usbvideo/vicam.c
@@ -796,7 +796,6 @@ static const struct v4l2_file_operations vicam_fops = {
796static struct video_device vicam_template = { 796static struct video_device vicam_template = {
797 .name = "ViCam-based USB Camera", 797 .name = "ViCam-based USB Camera",
798 .fops = &vicam_fops, 798 .fops = &vicam_fops,
799 .minor = -1,
800 .release = video_device_release_empty, 799 .release = video_device_release_empty,
801}; 800};
802 801
diff --git a/drivers/media/video/usbvision/usbvision-video.c b/drivers/media/video/usbvision/usbvision-video.c
index e89b855fd282..1054546db908 100644
--- a/drivers/media/video/usbvision/usbvision-video.c
+++ b/drivers/media/video/usbvision/usbvision-video.c
@@ -1328,7 +1328,6 @@ static struct video_device usbvision_video_template = {
1328 .ioctl_ops = &usbvision_ioctl_ops, 1328 .ioctl_ops = &usbvision_ioctl_ops,
1329 .name = "usbvision-video", 1329 .name = "usbvision-video",
1330 .release = video_device_release, 1330 .release = video_device_release,
1331 .minor = -1,
1332 .tvnorms = USBVISION_NORMS, 1331 .tvnorms = USBVISION_NORMS,
1333 .current_norm = V4L2_STD_PAL 1332 .current_norm = V4L2_STD_PAL
1334}; 1333};
@@ -1362,7 +1361,6 @@ static struct video_device usbvision_radio_template = {
1362 .fops = &usbvision_radio_fops, 1361 .fops = &usbvision_radio_fops,
1363 .name = "usbvision-radio", 1362 .name = "usbvision-radio",
1364 .release = video_device_release, 1363 .release = video_device_release,
1365 .minor = -1,
1366 .ioctl_ops = &usbvision_radio_ioctl_ops, 1364 .ioctl_ops = &usbvision_radio_ioctl_ops,
1367 1365
1368 .tvnorms = USBVISION_NORMS, 1366 .tvnorms = USBVISION_NORMS,
@@ -1382,7 +1380,6 @@ static struct video_device usbvision_vbi_template=
1382 .fops = &usbvision_vbi_fops, 1380 .fops = &usbvision_vbi_fops,
1383 .release = video_device_release, 1381 .release = video_device_release,
1384 .name = "usbvision-vbi", 1382 .name = "usbvision-vbi",
1385 .minor = -1,
1386}; 1383};
1387 1384
1388 1385
@@ -1404,7 +1401,6 @@ static struct video_device *usbvision_vdev_init(struct usb_usbvision *usbvision,
1404 return NULL; 1401 return NULL;
1405 } 1402 }
1406 *vdev = *vdev_template; 1403 *vdev = *vdev_template;
1407// vdev->minor = -1;
1408 vdev->v4l2_dev = &usbvision->v4l2_dev; 1404 vdev->v4l2_dev = &usbvision->v4l2_dev;
1409 snprintf(vdev->name, sizeof(vdev->name), "%s", name); 1405 snprintf(vdev->name, sizeof(vdev->name), "%s", name);
1410 video_set_drvdata(vdev, usbvision); 1406 video_set_drvdata(vdev, usbvision);
diff --git a/drivers/media/video/uvc/uvc_driver.c b/drivers/media/video/uvc/uvc_driver.c
index c31bc50113bc..391cccca7ffc 100644
--- a/drivers/media/video/uvc/uvc_driver.c
+++ b/drivers/media/video/uvc/uvc_driver.c
@@ -1651,7 +1651,6 @@ static int uvc_register_video(struct uvc_device *dev,
1651 * get another one. 1651 * get another one.
1652 */ 1652 */
1653 vdev->parent = &dev->intf->dev; 1653 vdev->parent = &dev->intf->dev;
1654 vdev->minor = -1;
1655 vdev->fops = &uvc_fops; 1654 vdev->fops = &uvc_fops;
1656 vdev->release = uvc_release; 1655 vdev->release = uvc_release;
1657 strlcpy(vdev->name, dev->name, sizeof vdev->name); 1656 strlcpy(vdev->name, dev->name, sizeof vdev->name);
diff --git a/drivers/media/video/vino.c b/drivers/media/video/vino.c
index b034a81d2b1c..a15d1e7cbed8 100644
--- a/drivers/media/video/vino.c
+++ b/drivers/media/video/vino.c
@@ -4068,7 +4068,6 @@ static struct video_device vdev_template = {
4068 .fops = &vino_fops, 4068 .fops = &vino_fops,
4069 .ioctl_ops = &vino_ioctl_ops, 4069 .ioctl_ops = &vino_ioctl_ops,
4070 .tvnorms = V4L2_STD_NTSC | V4L2_STD_PAL | V4L2_STD_SECAM, 4070 .tvnorms = V4L2_STD_NTSC | V4L2_STD_PAL | V4L2_STD_SECAM,
4071 .minor = -1,
4072}; 4071};
4073 4072
4074static void vino_module_cleanup(int stage) 4073static void vino_module_cleanup(int stage)
diff --git a/drivers/media/video/vivi.c b/drivers/media/video/vivi.c
index ce197e4cc589..37632a064966 100644
--- a/drivers/media/video/vivi.c
+++ b/drivers/media/video/vivi.c
@@ -1296,7 +1296,6 @@ static struct video_device vivi_template = {
1296 .name = "vivi", 1296 .name = "vivi",
1297 .fops = &vivi_fops, 1297 .fops = &vivi_fops,
1298 .ioctl_ops = &vivi_ioctl_ops, 1298 .ioctl_ops = &vivi_ioctl_ops,
1299 .minor = -1,
1300 .release = video_device_release, 1299 .release = video_device_release,
1301 1300
1302 .tvnorms = V4L2_STD_525_60, 1301 .tvnorms = V4L2_STD_525_60,
diff --git a/drivers/media/video/w9968cf.c b/drivers/media/video/w9968cf.c
index 3af6d6b31865..d807eea91757 100644
--- a/drivers/media/video/w9968cf.c
+++ b/drivers/media/video/w9968cf.c
@@ -3487,7 +3487,6 @@ w9968cf_usb_probe(struct usb_interface* intf, const struct usb_device_id* id)
3487 3487
3488 strcpy(cam->v4ldev->name, symbolic(camlist, mod_id)); 3488 strcpy(cam->v4ldev->name, symbolic(camlist, mod_id));
3489 cam->v4ldev->fops = &w9968cf_fops; 3489 cam->v4ldev->fops = &w9968cf_fops;
3490 cam->v4ldev->minor = video_nr[dev_nr];
3491 cam->v4ldev->release = video_device_release; 3490 cam->v4ldev->release = video_device_release;
3492 video_set_drvdata(cam->v4ldev, cam); 3491 video_set_drvdata(cam->v4ldev, cam);
3493 cam->v4ldev->v4l2_dev = &cam->v4l2_dev; 3492 cam->v4ldev->v4l2_dev = &cam->v4l2_dev;
diff --git a/drivers/media/video/zc0301/zc0301_core.c b/drivers/media/video/zc0301/zc0301_core.c
index 524eb754c97d..e44e4b5f3e50 100644
--- a/drivers/media/video/zc0301/zc0301_core.c
+++ b/drivers/media/video/zc0301/zc0301_core.c
@@ -1988,7 +1988,6 @@ zc0301_usb_probe(struct usb_interface* intf, const struct usb_device_id* id)
1988 1988
1989 strcpy(cam->v4ldev->name, "ZC0301[P] PC Camera"); 1989 strcpy(cam->v4ldev->name, "ZC0301[P] PC Camera");
1990 cam->v4ldev->fops = &zc0301_fops; 1990 cam->v4ldev->fops = &zc0301_fops;
1991 cam->v4ldev->minor = video_nr[dev_nr];
1992 cam->v4ldev->release = video_device_release; 1991 cam->v4ldev->release = video_device_release;
1993 cam->v4ldev->parent = &udev->dev; 1992 cam->v4ldev->parent = &udev->dev;
1994 video_set_drvdata(cam->v4ldev, cam); 1993 video_set_drvdata(cam->v4ldev, cam);
diff --git a/drivers/media/video/zoran/zoran_driver.c b/drivers/media/video/zoran/zoran_driver.c
index e9f72ca458f1..2ddffed019ee 100644
--- a/drivers/media/video/zoran/zoran_driver.c
+++ b/drivers/media/video/zoran/zoran_driver.c
@@ -3387,6 +3387,5 @@ struct video_device zoran_template __devinitdata = {
3387 .ioctl_ops = &zoran_ioctl_ops, 3387 .ioctl_ops = &zoran_ioctl_ops,
3388 .release = &zoran_vdev_release, 3388 .release = &zoran_vdev_release,
3389 .tvnorms = V4L2_STD_NTSC | V4L2_STD_PAL | V4L2_STD_SECAM, 3389 .tvnorms = V4L2_STD_NTSC | V4L2_STD_PAL | V4L2_STD_SECAM,
3390 .minor = -1
3391}; 3390};
3392 3391
diff --git a/drivers/media/video/zr364xx.c b/drivers/media/video/zr364xx.c
index 69ea6df62ab2..f0eae83e3d89 100644
--- a/drivers/media/video/zr364xx.c
+++ b/drivers/media/video/zr364xx.c
@@ -1455,7 +1455,6 @@ static struct video_device zr364xx_template = {
1455 .fops = &zr364xx_fops, 1455 .fops = &zr364xx_fops,
1456 .ioctl_ops = &zr364xx_ioctl_ops, 1456 .ioctl_ops = &zr364xx_ioctl_ops,
1457 .release = video_device_release, 1457 .release = video_device_release,
1458 .minor = -1,
1459}; 1458};
1460 1459
1461 1460