staging: comedi: adv_pci1723: move comedi_pci_enable() into the attach
authorH Hartley Sweeten <hartleys@visionengravers.com>
Thu, 19 Jul 2012 01:30:48 +0000 (18:30 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 19 Jul 2012 23:19:41 +0000 (16:19 -0700)
commitcc04c8a5fc82bd284f7f791869a7f9c0bfb528b5
tree193fcc8c2d7938ad4e2babfd1e8a88681c454399
parent3dbd666ca4e3c6e6d19101781a62555d0210ff57
staging: comedi: adv_pci1723: move comedi_pci_enable() into the attach

Use pci_is_enabled() in the "find pci device" function to determine if
the found pci device is not in use and move the comedi_pci_enable() call
into the attach.

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/adv_pci1723.c