The patch number 10359 was added via Jean-Francois Moine <moin...@free.fr>
to http://linuxtv.org/hg/v4l-dvb master development tree.

Kernel patches in this development tree may be modified to be backward
compatible with older kernels. Compatibility modifications will be
removed before inclusion into the mainstream Kernel

If anyone has any objections, please let us know by sending a message to:
        Linux Media Mailing List <linux-me...@vger.kernel.org>

------

merge: v4l-dvb


---

 linux/drivers/media/dvb/dvb-usb/dib0700_devices.c |    8 +++++++-
 linux/drivers/media/dvb/dvb-usb/dvb-usb-ids.h     |    1 +
 linux/drivers/media/video/ivtv/ivtv-driver.c      |    4 +++-
 linux/drivers/media/video/pvrusb2/pvrusb2-hdw.c   |    6 +++++-
 linux/drivers/media/video/v4l2-subdev.c           |    6 ++++++
 linux/include/media/v4l2-device.h                 |    8 ++++----
 linux/include/media/v4l2-subdev.h                 |    3 +++
 7 files changed, 29 insertions(+), 7 deletions(-)

diff -r 110be1ddb768 -r f708d34bc38b 
linux/drivers/media/dvb/dvb-usb/dib0700_devices.c
--- a/linux/drivers/media/dvb/dvb-usb/dib0700_devices.c Tue Jan 13 20:06:19 
2009 +0100
+++ b/linux/drivers/media/dvb/dvb-usb/dib0700_devices.c Wed Jan 14 20:50:43 
2009 +0100
@@ -1394,6 +1394,8 @@ struct usb_device_id dib0700_usb_id_tabl
 /* 40 */{ USB_DEVICE(USB_VID_PINNACLE,  USB_PID_PINNACLE_PCTV801E) },
        { USB_DEVICE(USB_VID_PINNACLE,  USB_PID_PINNACLE_PCTV801E_SE) },
        { USB_DEVICE(USB_VID_TERRATEC,  USB_PID_TERRATEC_CINERGY_T_EXPRESS) },
+       { USB_DEVICE(USB_VID_TERRATEC,
+                       USB_PID_TERRATEC_CINERGY_DT_XS_DIVERSITY_2) },
        { 0 }           /* Terminating entry */
 };
 MODULE_DEVICE_TABLE(usb, dib0700_usb_id_table);
@@ -1659,7 +1661,7 @@ struct dvb_usb_device_properties dib0700
                        }
                },
 
-               .num_device_descs = 4,
+               .num_device_descs = 5,
                .devices = {
                        {   "DiBcom STK7070PD reference design",
                                { &dib0700_usb_id_table[17], NULL },
@@ -1675,6 +1677,10 @@ struct dvb_usb_device_properties dib0700
                        },
                        {   "Hauppauge Nova-TD-500 (84xxx)",
                                { &dib0700_usb_id_table[36], NULL },
+                               { NULL },
+                       },
+                       {  "Terratec Cinergy DT USB XS Diversity",
+                               { &dib0700_usb_id_table[43], NULL },
                                { NULL },
                        }
                }
diff -r 110be1ddb768 -r f708d34bc38b 
linux/drivers/media/dvb/dvb-usb/dvb-usb-ids.h
--- a/linux/drivers/media/dvb/dvb-usb/dvb-usb-ids.h     Tue Jan 13 20:06:19 
2009 +0100
+++ b/linux/drivers/media/dvb/dvb-usb/dvb-usb-ids.h     Wed Jan 14 20:50:43 
2009 +0100
@@ -162,6 +162,7 @@
 #define USB_PID_AVERMEDIA_A309                         0xa309
 #define USB_PID_TECHNOTREND_CONNECT_S2400               0x3006
 #define USB_PID_TERRATEC_CINERGY_DT_XS_DIVERSITY       0x005a
+#define USB_PID_TERRATEC_CINERGY_DT_XS_DIVERSITY_2     0x0081
 #define USB_PID_TERRATEC_CINERGY_HT_USB_XE             0x0058
 #define USB_PID_TERRATEC_CINERGY_HT_EXPRESS            0x0060
 #define USB_PID_TERRATEC_CINERGY_T_EXPRESS             0x0062
diff -r 110be1ddb768 -r f708d34bc38b 
linux/drivers/media/video/ivtv/ivtv-driver.c
--- a/linux/drivers/media/video/ivtv/ivtv-driver.c      Tue Jan 13 20:06:19 
2009 +0100
+++ b/linux/drivers/media/video/ivtv/ivtv-driver.c      Wed Jan 14 20:50:43 
2009 +0100
@@ -953,8 +953,10 @@ static int __devinit ivtv_probe(struct p
        itv->instance = atomic_inc_return(&ivtv_instance) - 1;
 
        retval = v4l2_device_register(&dev->dev, &itv->device);
-       if (retval)
+       if (retval) {
+               kfree(itv);
                return retval;
+       }
        /* "ivtv + PCI ID" is a bit of a mouthful, so use
           "ivtv + instance" instead. */
        snprintf(itv->device.name, sizeof(itv->device.name),
diff -r 110be1ddb768 -r f708d34bc38b 
linux/drivers/media/video/pvrusb2/pvrusb2-hdw.c
--- a/linux/drivers/media/video/pvrusb2/pvrusb2-hdw.c   Tue Jan 13 20:06:19 
2009 +0100
+++ b/linux/drivers/media/video/pvrusb2/pvrusb2-hdw.c   Wed Jan 14 20:50:43 
2009 +0100
@@ -3747,7 +3747,11 @@ void pvr2_hdw_device_reset(struct pvr2_h
        int ret;
        pvr2_trace(PVR2_TRACE_INIT,"Performing a device reset...");
        ret = usb_lock_device_for_reset(hdw->usb_dev,NULL);
-       if (ret == 1) {
+#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 29)
+       /* Due to the API changes, the ret value for success changed */
+       ret = ret != 1;
+#endif
+       if (ret == 0) {
                ret = usb_reset_device(hdw->usb_dev);
                usb_unlock_device(hdw->usb_dev);
        } else {
diff -r 110be1ddb768 -r f708d34bc38b linux/drivers/media/video/v4l2-subdev.c
--- a/linux/drivers/media/video/v4l2-subdev.c   Tue Jan 13 20:06:19 2009 +0100
+++ b/linux/drivers/media/video/v4l2-subdev.c   Wed Jan 14 20:50:43 2009 +0100
@@ -33,6 +33,12 @@ int v4l2_subdev_command(struct v4l2_subd
                return v4l2_subdev_call(sd, core, g_ctrl, arg);
        case VIDIOC_S_CTRL:
                return v4l2_subdev_call(sd, core, s_ctrl, arg);
+       case VIDIOC_G_EXT_CTRLS:
+               return v4l2_subdev_call(sd, core, g_ext_ctrls, arg);
+       case VIDIOC_S_EXT_CTRLS:
+               return v4l2_subdev_call(sd, core, s_ext_ctrls, arg);
+       case VIDIOC_TRY_EXT_CTRLS:
+               return v4l2_subdev_call(sd, core, try_ext_ctrls, arg);
        case VIDIOC_QUERYMENU:
                return v4l2_subdev_call(sd, core, queryctrl, arg);
        case VIDIOC_LOG_STATUS:
diff -r 110be1ddb768 -r f708d34bc38b linux/include/media/v4l2-device.h
--- a/linux/include/media/v4l2-device.h Tue Jan 13 20:06:19 2009 +0100
+++ b/linux/include/media/v4l2-device.h Wed Jan 14 20:50:43 2009 +0100
@@ -94,16 +94,16 @@ void v4l2_device_unregister_subdev(struc
 /* Call the specified callback for all subdevs matching grp_id (if 0, then
    match them all). Ignore any errors. Note that you cannot add or delete
    a subdev while walking the subdevs list. */
-#define v4l2_device_call_all(dev, grp_id, o, f, args...)               \
+#define v4l2_device_call_all(dev, grpid, o, f, args...)                \
        __v4l2_device_call_subdevs(dev,                                 \
-                       !(grp_id) || sd->grp_id == (grp_id), o, f , ##args)
+                       !(grpid) || sd->grp_id == (grpid), o, f , ##args)
 
 /* Call the specified callback for all subdevs matching grp_id (if 0, then
    match them all). If the callback returns an error other than 0 or
    -ENOIOCTLCMD, then return with that error code. Note that you cannot
    add or delete a subdev while walking the subdevs list. */
-#define v4l2_device_call_until_err(dev, grp_id, o, f, args...)                 
\
+#define v4l2_device_call_until_err(dev, grpid, o, f, args...)          \
        __v4l2_device_call_subdevs_until_err(dev,                       \
-                      !(grp_id) || sd->grp_id == (grp_id), o, f , ##args)
+                      !(grpid) || sd->grp_id == (grpid), o, f , ##args)
 
 #endif
diff -r 110be1ddb768 -r f708d34bc38b linux/include/media/v4l2-subdev.h
--- a/linux/include/media/v4l2-subdev.h Tue Jan 13 20:06:19 2009 +0100
+++ b/linux/include/media/v4l2-subdev.h Wed Jan 14 20:50:43 2009 +0100
@@ -78,6 +78,9 @@ struct v4l2_subdev_core_ops {
        int (*queryctrl)(struct v4l2_subdev *sd, struct v4l2_queryctrl *qc);
        int (*g_ctrl)(struct v4l2_subdev *sd, struct v4l2_control *ctrl);
        int (*s_ctrl)(struct v4l2_subdev *sd, struct v4l2_control *ctrl);
+       int (*g_ext_ctrls)(struct v4l2_subdev *sd, struct v4l2_ext_controls 
*ctrls);
+       int (*s_ext_ctrls)(struct v4l2_subdev *sd, struct v4l2_ext_controls 
*ctrls);
+       int (*try_ext_ctrls)(struct v4l2_subdev *sd, struct v4l2_ext_controls 
*ctrls);
        int (*querymenu)(struct v4l2_subdev *sd, struct v4l2_querymenu *qm);
        long (*ioctl)(struct v4l2_subdev *sd, unsigned int cmd, void *arg);
 #ifdef CONFIG_VIDEO_ADV_DEBUG


---

Patch is available at: 
http://linuxtv.org/hg/v4l-dvb/rev/f708d34bc38bccaa19a06c22dfb611a02219f7af

_______________________________________________
linuxtv-commits mailing list
linuxtv-commits@linuxtv.org
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linuxtv-commits

Reply via email to