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-gemtek-pci.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-gemtek-pci.c')
-rw-r--r-- | drivers/media/radio/radio-gemtek-pci.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/media/radio/radio-gemtek-pci.c b/drivers/media/radio/radio-gemtek-pci.c index d65fd287bde..1f57f731c12 100644 --- a/drivers/media/radio/radio-gemtek-pci.c +++ b/drivers/media/radio/radio-gemtek-pci.c | |||
@@ -205,7 +205,7 @@ static int vidioc_g_tuner(struct file *file, void *priv, | |||
205 | struct v4l2_tuner *v) | 205 | struct v4l2_tuner *v) |
206 | { | 206 | { |
207 | struct video_device *dev = video_devdata(file); | 207 | struct video_device *dev = video_devdata(file); |
208 | struct gemtek_pci_card *card = dev->priv; | 208 | struct gemtek_pci_card *card = video_get_drvdata(dev); |
209 | 209 | ||
210 | if (v->index > 0) | 210 | if (v->index > 0) |
211 | return -EINVAL; | 211 | return -EINVAL; |
@@ -233,7 +233,7 @@ static int vidioc_s_frequency(struct file *file, void *priv, | |||
233 | struct v4l2_frequency *f) | 233 | struct v4l2_frequency *f) |
234 | { | 234 | { |
235 | struct video_device *dev = video_devdata(file); | 235 | struct video_device *dev = video_devdata(file); |
236 | struct gemtek_pci_card *card = dev->priv; | 236 | struct gemtek_pci_card *card = video_get_drvdata(dev); |
237 | 237 | ||
238 | if ( (f->frequency < GEMTEK_PCI_RANGE_LOW) || | 238 | if ( (f->frequency < GEMTEK_PCI_RANGE_LOW) || |
239 | (f->frequency > GEMTEK_PCI_RANGE_HIGH) ) | 239 | (f->frequency > GEMTEK_PCI_RANGE_HIGH) ) |
@@ -248,7 +248,7 @@ static int vidioc_g_frequency(struct file *file, void *priv, | |||
248 | struct v4l2_frequency *f) | 248 | struct v4l2_frequency *f) |
249 | { | 249 | { |
250 | struct video_device *dev = video_devdata(file); | 250 | struct video_device *dev = video_devdata(file); |
251 | struct gemtek_pci_card *card = dev->priv; | 251 | struct gemtek_pci_card *card = video_get_drvdata(dev); |
252 | 252 | ||
253 | f->type = V4L2_TUNER_RADIO; | 253 | f->type = V4L2_TUNER_RADIO; |
254 | f->frequency = card->current_frequency; | 254 | f->frequency = card->current_frequency; |
@@ -273,7 +273,7 @@ static int vidioc_g_ctrl(struct file *file, void *priv, | |||
273 | struct v4l2_control *ctrl) | 273 | struct v4l2_control *ctrl) |
274 | { | 274 | { |
275 | struct video_device *dev = video_devdata(file); | 275 | struct video_device *dev = video_devdata(file); |
276 | struct gemtek_pci_card *card = dev->priv; | 276 | struct gemtek_pci_card *card = video_get_drvdata(dev); |
277 | 277 | ||
278 | switch (ctrl->id) { | 278 | switch (ctrl->id) { |
279 | case V4L2_CID_AUDIO_MUTE: | 279 | case V4L2_CID_AUDIO_MUTE: |
@@ -293,7 +293,7 @@ static int vidioc_s_ctrl(struct file *file, void *priv, | |||
293 | struct v4l2_control *ctrl) | 293 | struct v4l2_control *ctrl) |
294 | { | 294 | { |
295 | struct video_device *dev = video_devdata(file); | 295 | struct video_device *dev = video_devdata(file); |
296 | struct gemtek_pci_card *card = dev->priv; | 296 | struct gemtek_pci_card *card = video_get_drvdata(dev); |
297 | 297 | ||
298 | switch (ctrl->id) { | 298 | switch (ctrl->id) { |
299 | case V4L2_CID_AUDIO_MUTE: | 299 | case V4L2_CID_AUDIO_MUTE: |
@@ -442,7 +442,7 @@ static int __devinit gemtek_pci_probe( struct pci_dev *pci_dev, const struct pci | |||
442 | } | 442 | } |
443 | 443 | ||
444 | card->videodev = devradio; | 444 | card->videodev = devradio; |
445 | devradio->priv = card; | 445 | video_set_drvdata(devradio, card); |
446 | gemtek_pci_mute( card ); | 446 | gemtek_pci_mute( card ); |
447 | 447 | ||
448 | printk( KERN_INFO "Gemtek PCI Radio (rev. %d) found at 0x%04x-0x%04x.\n", | 448 | printk( KERN_INFO "Gemtek PCI Radio (rev. %d) found at 0x%04x-0x%04x.\n", |