diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-04-30 22:18:08 +0000 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-04-30 22:18:08 +0000 |
commit | 0ea260891398ca8c39e7b6a524839125c0894ad9 (patch) | |
tree | cc13a88175326c83db142bef6b85c82ab0db681b /linux/drivers/media/dvb | |
parent | 761fb9dc928dfb9fa78fe3ed6e9269c1fdcbc9b1 (diff) | |
download | mediapointer-dvb-s2-0ea260891398ca8c39e7b6a524839125c0894ad9.tar.gz mediapointer-dvb-s2-0ea260891398ca8c39e7b6a524839125c0894ad9.tar.bz2 |
remove driver_data direct access of struct device
From: Greg Kroah-Hartman <gregkh@suse.de>
In the near future, the driver core is going to not allow direct access
to the driver_data pointer in struct device. Instead, the functions
dev_get_drvdata() and dev_set_drvdata() should be used. These functions
have been around since the beginning, so are backwards compatible with
all older kernel versions.
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'linux/drivers/media/dvb')
-rw-r--r-- | linux/drivers/media/dvb/firewire/firedtv-1394.c | 4 | ||||
-rw-r--r-- | linux/drivers/media/dvb/firewire/firedtv-dvb.c | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/linux/drivers/media/dvb/firewire/firedtv-1394.c b/linux/drivers/media/dvb/firewire/firedtv-1394.c index 4e207658c..2b6eeeab5 100644 --- a/linux/drivers/media/dvb/firewire/firedtv-1394.c +++ b/linux/drivers/media/dvb/firewire/firedtv-1394.c @@ -225,7 +225,7 @@ fail_free: static int node_remove(struct device *dev) { - struct firedtv *fdtv = dev->driver_data; + struct firedtv *fdtv = dev_get_drvdata(dev); fdtv_dvb_unregister(fdtv); @@ -242,7 +242,7 @@ static int node_remove(struct device *dev) static int node_update(struct unit_directory *ud) { - struct firedtv *fdtv = ud->device.driver_data; + struct firedtv *fdtv = dev_get_drvdata(&ud->device); if (fdtv->isochannel >= 0) cmp_establish_pp_connection(fdtv, fdtv->subunit, diff --git a/linux/drivers/media/dvb/firewire/firedtv-dvb.c b/linux/drivers/media/dvb/firewire/firedtv-dvb.c index 9d308dd32..5742fde79 100644 --- a/linux/drivers/media/dvb/firewire/firedtv-dvb.c +++ b/linux/drivers/media/dvb/firewire/firedtv-dvb.c @@ -268,7 +268,7 @@ struct firedtv *fdtv_alloc(struct device *dev, if (!fdtv) return NULL; - dev->driver_data = fdtv; + dev_set_drvdata(dev, fdtv); fdtv->device = dev; fdtv->isochannel = -1; fdtv->voltage = 0xff; |