V4L/DVB (5306): Add support for VIDIOC_G_CHIP_IDENT
[firefly-linux-kernel-4.4.55.git] / drivers / media / video / videodev.c
index 5c9f2116d7bf52bbff5db53182a18da50257736f..fdfef0b53315d0426e048def4454336d444056a2 100644 (file)
@@ -1532,6 +1532,16 @@ static int __video_do_ioctl(struct inode *inode, struct file *file,
                break;
        }
 #endif
+       case VIDIOC_G_CHIP_IDENT:
+       {
+               struct v4l2_chip_ident *p=arg;
+               if (!vfd->vidioc_g_chip_ident)
+                       break;
+               ret=vfd->vidioc_g_chip_ident(file, fh, p);
+               if (!ret)
+                       dbgarg (cmd, "chip_ident=%u, revision=0x%x\n", p->ident, p->revision);
+               break;
+       }
        } /* switch */
 
        if (vfd->debug & V4L2_DEBUG_IOCTL_ARG) {