Commit 7ffb0a85 authored by H Hartley Sweeten's avatar H Hartley Sweeten Committed by Greg Kroah-Hartman

staging: comedi: acl7225b: cleanup dev->board_name usage

The comedi core initializes the dev->board_name before calling the
driver (*attach) function. There is not reason to reinitialize it
in the driver.

Use the dev->board_name when doing the request_resource() instead
of the open-coded string.
Signed-off-by: default avatarH Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 894ab190
......@@ -74,9 +74,8 @@ static int acl7225b_attach(struct comedi_device *dev,
iobase = it->options[0];
iorange = board->io_range;
if (!request_region(iobase, iorange, "acl7225b"))
if (!request_region(iobase, iorange, dev->board_name))
return -EIO;
dev->board_name = board->name;
dev->iobase = iobase;
dev->irq = 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment