diff options
Diffstat (limited to 'drivers/media/video/v4l2-dev.c')
-rw-r--r-- | drivers/media/video/v4l2-dev.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/media/video/v4l2-dev.c b/drivers/media/video/v4l2-dev.c index 0ca7ec9ca902..9e89bf617790 100644 --- a/drivers/media/video/v4l2-dev.c +++ b/drivers/media/video/v4l2-dev.c | |||
@@ -410,7 +410,7 @@ static int __video_register_device(struct video_device *vdev, int type, int nr, | |||
410 | int minor_offset = 0; | 410 | int minor_offset = 0; |
411 | int minor_cnt = VIDEO_NUM_DEVICES; | 411 | int minor_cnt = VIDEO_NUM_DEVICES; |
412 | const char *name_base; | 412 | const char *name_base; |
413 | void *priv = video_get_drvdata(vdev); | 413 | void *priv = vdev->dev.p; |
414 | 414 | ||
415 | /* A minor value of -1 marks this video device as never | 415 | /* A minor value of -1 marks this video device as never |
416 | having been registered */ | 416 | having been registered */ |
@@ -536,9 +536,9 @@ static int __video_register_device(struct video_device *vdev, int type, int nr, | |||
536 | 536 | ||
537 | /* Part 4: register the device with sysfs */ | 537 | /* Part 4: register the device with sysfs */ |
538 | memset(&vdev->dev, 0, sizeof(vdev->dev)); | 538 | memset(&vdev->dev, 0, sizeof(vdev->dev)); |
539 | /* The memset above cleared the device's drvdata, so | 539 | /* The memset above cleared the device's device_private, so |
540 | put back the copy we made earlier. */ | 540 | put back the copy we made earlier. */ |
541 | video_set_drvdata(vdev, priv); | 541 | vdev->dev.p = priv; |
542 | vdev->dev.class = &video_class; | 542 | vdev->dev.class = &video_class; |
543 | vdev->dev.devt = MKDEV(VIDEO_MAJOR, vdev->minor); | 543 | vdev->dev.devt = MKDEV(VIDEO_MAJOR, vdev->minor); |
544 | if (vdev->parent) | 544 | if (vdev->parent) |