staging: comedi: addi_apci_16xx: simplify PCI bar reading
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Fri, 18 Jan 2013 17:44:11 +0000 (10:44 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 18 Jan 2013 20:57:23 +0000 (12:57 -0800)
commitebea8c69d323acfc13f85b067a8608ec10794638
treeb6ee6d799ab854f9db586a666c800eb3fc4b10eb
parent046e0d10bda65c2b096627765b302b3123beee47
staging: comedi: addi_apci_16xx: simplify PCI bar reading

The boards supported by this driver do not have an eeprom. Knowing
this information allows simplifying the code that reads the PCI
bars to get the iobase addresses.

The only 'iobase' actually used by this driver is found in PCI
bar 0. Don't bother reading the other PCI bars.

Also, since 'dw_AiBase' is not ioremap'ed we can remove the check
and iounmap in the detach.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/comedi/drivers/addi_apci_16xx.c