diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2008-08-23 06:24:07 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2008-10-12 07:36:54 -0400 |
commit | 601e9444f249d219009ec05674268d90f6f1cdcb (patch) | |
tree | 42d58813872e340e03a40b74922ea89dfdcf0c55 /drivers/media/radio/radio-sf16fmi.c | |
parent | e138c592b50370621653fd962b2bc3f4e25dfe78 (diff) |
V4L/DVB (8786): v4l2: remove the priv field, use dev_get_drvdata instead
Remove the priv field and let video_get/set_drvdata use dev_get_drvdata
and dev_set_drvdata instead.
Convert all drivers that still used priv directly.
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/radio/radio-sf16fmi.c')
-rw-r--r-- | drivers/media/radio/radio-sf16fmi.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/media/radio/radio-sf16fmi.c b/drivers/media/radio/radio-sf16fmi.c index 6d865a7a91ec..810c366b73b0 100644 --- a/drivers/media/radio/radio-sf16fmi.c +++ b/drivers/media/radio/radio-sf16fmi.c | |||
@@ -148,7 +148,7 @@ static int vidioc_g_tuner(struct file *file, void *priv, | |||
148 | { | 148 | { |
149 | int mult; | 149 | int mult; |
150 | struct video_device *dev = video_devdata(file); | 150 | struct video_device *dev = video_devdata(file); |
151 | struct fmi_device *fmi = dev->priv; | 151 | struct fmi_device *fmi = video_get_drvdata(dev); |
152 | 152 | ||
153 | if (v->index > 0) | 153 | if (v->index > 0) |
154 | return -EINVAL; | 154 | return -EINVAL; |
@@ -177,7 +177,7 @@ static int vidioc_s_frequency(struct file *file, void *priv, | |||
177 | struct v4l2_frequency *f) | 177 | struct v4l2_frequency *f) |
178 | { | 178 | { |
179 | struct video_device *dev = video_devdata(file); | 179 | struct video_device *dev = video_devdata(file); |
180 | struct fmi_device *fmi = dev->priv; | 180 | struct fmi_device *fmi = video_get_drvdata(dev); |
181 | 181 | ||
182 | if (!(fmi->flags & V4L2_TUNER_CAP_LOW)) | 182 | if (!(fmi->flags & V4L2_TUNER_CAP_LOW)) |
183 | f->frequency *= 1000; | 183 | f->frequency *= 1000; |
@@ -195,7 +195,7 @@ static int vidioc_g_frequency(struct file *file, void *priv, | |||
195 | struct v4l2_frequency *f) | 195 | struct v4l2_frequency *f) |
196 | { | 196 | { |
197 | struct video_device *dev = video_devdata(file); | 197 | struct video_device *dev = video_devdata(file); |
198 | struct fmi_device *fmi = dev->priv; | 198 | struct fmi_device *fmi = video_get_drvdata(dev); |
199 | 199 | ||
200 | f->type = V4L2_TUNER_RADIO; | 200 | f->type = V4L2_TUNER_RADIO; |
201 | f->frequency = fmi->curfreq; | 201 | f->frequency = fmi->curfreq; |
@@ -223,7 +223,7 @@ static int vidioc_g_ctrl(struct file *file, void *priv, | |||
223 | struct v4l2_control *ctrl) | 223 | struct v4l2_control *ctrl) |
224 | { | 224 | { |
225 | struct video_device *dev = video_devdata(file); | 225 | struct video_device *dev = video_devdata(file); |
226 | struct fmi_device *fmi = dev->priv; | 226 | struct fmi_device *fmi = video_get_drvdata(dev); |
227 | 227 | ||
228 | switch (ctrl->id) { | 228 | switch (ctrl->id) { |
229 | case V4L2_CID_AUDIO_MUTE: | 229 | case V4L2_CID_AUDIO_MUTE: |
@@ -237,7 +237,7 @@ static int vidioc_s_ctrl(struct file *file, void *priv, | |||
237 | struct v4l2_control *ctrl) | 237 | struct v4l2_control *ctrl) |
238 | { | 238 | { |
239 | struct video_device *dev = video_devdata(file); | 239 | struct video_device *dev = video_devdata(file); |
240 | struct fmi_device *fmi = dev->priv; | 240 | struct fmi_device *fmi = video_get_drvdata(dev); |
241 | 241 | ||
242 | switch (ctrl->id) { | 242 | switch (ctrl->id) { |
243 | case V4L2_CID_AUDIO_MUTE: | 243 | case V4L2_CID_AUDIO_MUTE: |
@@ -386,7 +386,7 @@ static int __init fmi_init(void) | |||
386 | fmi_unit.curvol = 0; | 386 | fmi_unit.curvol = 0; |
387 | fmi_unit.curfreq = 0; | 387 | fmi_unit.curfreq = 0; |
388 | fmi_unit.flags = V4L2_TUNER_CAP_LOW; | 388 | fmi_unit.flags = V4L2_TUNER_CAP_LOW; |
389 | fmi_radio.priv = &fmi_unit; | 389 | video_set_drvdata(&fmi_radio, &fmi_unit); |
390 | 390 | ||
391 | mutex_init(&lock); | 391 | mutex_init(&lock); |
392 | 392 | ||