From: Ian Abbott Date: Mon, 1 Sep 2014 11:03:39 +0000 (+0100) Subject: staging: comedi: amplc_pci230: set detach handler to comedi_pci_detach() X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=5668ddf083fd7db5b904fc8332f4b28748fe5eed;p=openwrt%2Fstaging%2Fblogic.git staging: comedi: amplc_pci230: set detach handler to comedi_pci_detach() Since the comedi driver's "detach`" handler `pci230_detach()` now merely calls `comedi_pci_detach()` with the same parameter, use `comedi_pci_detach()` itself as the "detach" handler. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/comedi/drivers/amplc_pci230.c b/drivers/staging/comedi/drivers/amplc_pci230.c index 39fa2f63f14a..35d7f0c9836f 100644 --- a/drivers/staging/comedi/drivers/amplc_pci230.c +++ b/drivers/staging/comedi/drivers/amplc_pci230.c @@ -2732,16 +2732,11 @@ static int pci230_auto_attach(struct comedi_device *dev, return pci230_attach_common(dev, pci_dev); } -static void pci230_detach(struct comedi_device *dev) -{ - comedi_pci_detach(dev); -} - static struct comedi_driver amplc_pci230_driver = { .driver_name = "amplc_pci230", .module = THIS_MODULE, .auto_attach = pci230_auto_attach, - .detach = pci230_detach, + .detach = comedi_pci_detach, }; static int amplc_pci230_pci_probe(struct pci_dev *dev,