/* This unregisters the passed device. Future open calls will be met with errors.  */
void video_unregister_device(struct video_device *vdev)
/* This unregisters the passed device. Future open calls will be met with errors.  */
void video_unregister_device(struct video_device *vdev)
{
	if (!vdev || !video_is_registered(vdev))
		return;
	mutex_lock(&videodev_lock);
	clear_bit(V4L2_FL_REGISTERED, &vdev->flags);
	mutex_unlock(&videodev_lock);
	device_unregister(&vdev->dev);
}