diff options
author | H Hartley Sweeten <hsweeten@visionengravers.com> | 2013-04-09 23:26:22 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-04-11 19:47:52 (GMT) |
commit | f5e610fb054d9b4cb45ca2c5af83e8ec8a937823 (patch) | |
tree | 123fd103d010f14e08f30bdf338e3c8d55fae282 /drivers | |
parent | 2028bdc44353c8be96ae6b05813920d9989b6535 (diff) | |
download | linux-fsl-qoriq-f5e610fb054d9b4cb45ca2c5af83e8ec8a937823.tar.xz |
staging: comedi: pcmad: cleanup dev->board_name usage
This legacy driver does no additional probing so the dev->board_name
will already be properly initialized by the comedi core before calling
the (*attach) function.
Remove the unnecessary initialization of dev->board_name and use it
when requesting the resources instead of the open-coded strings.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/staging/comedi/drivers/pcmad.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/staging/comedi/drivers/pcmad.c b/drivers/staging/comedi/drivers/pcmad.c index 13e8421..130e929 100644 --- a/drivers/staging/comedi/drivers/pcmad.c +++ b/drivers/staging/comedi/drivers/pcmad.c @@ -111,7 +111,7 @@ static int pcmad_attach(struct comedi_device *dev, struct comedi_devconfig *it) iobase = it->options[0]; printk(KERN_INFO "comedi%d: pcmad: 0x%04lx ", dev->minor, iobase); - if (!request_region(iobase, PCMAD_SIZE, "pcmad")) { + if (!request_region(iobase, PCMAD_SIZE, dev->board_name)) { printk(KERN_CONT "I/O port conflict\n"); return -EIO; } @@ -127,8 +127,6 @@ static int pcmad_attach(struct comedi_device *dev, struct comedi_devconfig *it) return -ENOMEM; dev->private = devpriv; - dev->board_name = board->name; - s = &dev->subdevices[0]; s->type = COMEDI_SUBD_AI; s->subdev_flags = SDF_READABLE | AREF_GROUND; |