aboutsummaryrefslogtreecommitdiff
path: root/drivers/staging/comedi/drivers/pcmda12.c
diff options
context:
space:
mode:
authorH Hartley Sweeten <hartleys@visionengravers.com>2012-05-01 17:03:48 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-05-02 15:53:43 -0700
commit2d2111ea2cf25cc60f7027130ceb34af2d03745d (patch)
treebb177d25af51dd771f146bc8cd909335c92ce1c0 /drivers/staging/comedi/drivers/pcmda12.c
parentd210267741fb2a8b6d741d9040703683a39087f4 (diff)
staging: comedi: fix build errors caused by module_init/module_exit refactor
A couple build errors were introduced with the module_init/module_exit refactor. The struct comedi_driver variable was being accessed directly in the attach and detach routines. Instead of doing this, access the variable indirectly using the driver pointer in struct comedi_device. Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com> Cc: Ian Abbott <abbotti@mev.co.uk> Cc: Mori Hess <fmhess@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/comedi/drivers/pcmda12.c')
-rw-r--r--drivers/staging/comedi/drivers/pcmda12.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/staging/comedi/drivers/pcmda12.c b/drivers/staging/comedi/drivers/pcmda12.c
index 4846d984fb4..a82b343755f 100644
--- a/drivers/staging/comedi/drivers/pcmda12.c
+++ b/drivers/staging/comedi/drivers/pcmda12.c
@@ -172,10 +172,10 @@ static int pcmda12_attach(struct comedi_device *dev,
iobase = it->options[0];
printk(KERN_INFO
- "comedi%d: %s: io: %lx %s ", dev->minor, driver.driver_name,
+ "comedi%d: %s: io: %lx %s ", dev->minor, dev->driver->driver_name,
iobase, it->options[1] ? "simultaneous xfer mode enabled" : "");
- if (!request_region(iobase, IOSIZE, driver.driver_name)) {
+ if (!request_region(iobase, IOSIZE, dev->driver->driver_name)) {
printk("I/O port conflict\n");
return -EIO;
}
@@ -230,7 +230,7 @@ static int pcmda12_attach(struct comedi_device *dev,
static int pcmda12_detach(struct comedi_device *dev)
{
printk(KERN_INFO
- "comedi%d: %s: remove\n", dev->minor, driver.driver_name);
+ "comedi%d: %s: remove\n", dev->minor, dev->driver->driver_name);
if (dev->iobase)
release_region(dev->iobase, IOSIZE);
return 0;