diff -upr gspcav1-20071224.orig/gspca_core.c gspcav1-20071224/gspca_core.c --- gspcav1-20071224.orig/gspca_core.c 2007-12-24 17:56:47.000000000 +0100 +++ gspcav1-20071224/gspca_core.c 2009-02-01 09:59:56.000000000 +0100 @@ -51,10 +51,11 @@ static const char gspca_version[] = GSPC #include #include #include -#include +#include #include #include #include +#include /* only on 2.6.x */ #include #include @@ -2606,9 +2607,7 @@ static struct file_operations spca5xx_fo .llseek = no_llseek, }; static struct video_device spca50x_template = { - .owner = THIS_MODULE, .name = "GSPCA USB Camera", - .type = VID_TYPE_CAPTURE, #if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,23) .hardware = VID_HARDWARE_GSPCA, #endif @@ -2765,24 +2764,7 @@ static DEVICE_ATTR(pictsetting, S_IRUGO, static int spca50x_create_sysfs(struct video_device *vdev) { - int rc = 0; - rc = video_device_create_file(vdev, &dev_attr_stream_id); - if (rc) - goto err_stream_id; - rc = video_device_create_file(vdev, &dev_attr_model); - if (rc) - goto err_model; - rc = video_device_create_file(vdev, &dev_attr_pictsetting); - if (rc) - goto err_pictsetting; return 0; - err_pictsetting: - video_device_remove_file(vdev, &dev_attr_pictsetting); - err_model: - video_device_remove_file(vdev, &dev_attr_model); - err_stream_id: - video_device_remove_file(vdev, &dev_attr_stream_id); - return rc; } #endif @@ -4298,7 +4280,6 @@ spca5xx_probe(struct usb_interface *intf if (!spca50x->vdev) goto error; memcpy(spca50x->vdev, &spca50x_template, sizeof (spca50x_template)); - spca50x->vdev->dev = &dev->dev; video_set_drvdata(spca50x->vdev, spca50x); PDEBUG(2, "setting video device = %p, spca50x = %p", spca50x->vdev, spca50x);