summaryrefslogtreecommitdiff
path: root/drivers/media/radio/radio-rtrack2.c
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2008-08-23 14:24:07 +0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2008-10-12 15:36:54 +0400
commit601e9444f249d219009ec05674268d90f6f1cdcb (patch)
tree42d58813872e340e03a40b74922ea89dfdcf0c55 /drivers/media/radio/radio-rtrack2.c
parente138c592b50370621653fd962b2bc3f4e25dfe78 (diff)
downloadlinux-601e9444f249d219009ec05674268d90f6f1cdcb.tar.xz
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-rtrack2.c')
-rw-r--r--drivers/media/radio/radio-rtrack2.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/media/radio/radio-rtrack2.c b/drivers/media/radio/radio-rtrack2.c
index 8fe820da73e8..4234f7ed0fc3 100644
--- a/drivers/media/radio/radio-rtrack2.c
+++ b/drivers/media/radio/radio-rtrack2.c
@@ -155,7 +155,7 @@ static int vidioc_g_tuner(struct file *file, void *priv,
struct v4l2_tuner *v)
{
struct video_device *dev = video_devdata(file);
- struct rt_device *rt = dev->priv;
+ struct rt_device *rt = video_get_drvdata(dev);
if (v->index > 0)
return -EINVAL;
@@ -175,7 +175,7 @@ static int vidioc_s_frequency(struct file *file, void *priv,
struct v4l2_frequency *f)
{
struct video_device *dev = video_devdata(file);
- struct rt_device *rt = dev->priv;
+ struct rt_device *rt = video_get_drvdata(dev);
rt->curfreq = f->frequency;
rt_setfreq(rt, rt->curfreq);
@@ -186,7 +186,7 @@ static int vidioc_g_frequency(struct file *file, void *priv,
struct v4l2_frequency *f)
{
struct video_device *dev = video_devdata(file);
- struct rt_device *rt = dev->priv;
+ struct rt_device *rt = video_get_drvdata(dev);
f->type = V4L2_TUNER_RADIO;
f->frequency = rt->curfreq;
@@ -212,7 +212,7 @@ static int vidioc_g_ctrl(struct file *file, void *priv,
struct v4l2_control *ctrl)
{
struct video_device *dev = video_devdata(file);
- struct rt_device *rt = dev->priv;
+ struct rt_device *rt = video_get_drvdata(dev);
switch (ctrl->id) {
case V4L2_CID_AUDIO_MUTE:
@@ -232,7 +232,7 @@ static int vidioc_s_ctrl(struct file *file, void *priv,
struct v4l2_control *ctrl)
{
struct video_device *dev = video_devdata(file);
- struct rt_device *rt = dev->priv;
+ struct rt_device *rt = video_get_drvdata(dev);
switch (ctrl->id) {
case V4L2_CID_AUDIO_MUTE:
@@ -342,7 +342,7 @@ static int __init rtrack2_init(void)
return -EBUSY;
}
- rtrack2_radio.priv=&rtrack2_unit;
+ video_set_drvdata(&rtrack2_radio, &rtrack2_unit);
spin_lock_init(&lock);
if (video_register_device(&rtrack2_radio, VFL_TYPE_RADIO, radio_nr) < 0) {