[PATCH 40/77] staging: comedi: usbduxsigma: remove tidy_up() from (*auto_attach)
H Hartley Sweeten
hsweeten at visionengravers.com
Thu May 23 19:55:28 UTC 2013
Comedi drivers do not need to cleanup allocations during the
(*auto_attach). If the (*auto_attach) fails the (*detach) will
automatically be called to handle the cleanup.
Signed-off-by: H Hartley Sweeten <hsweeten at visionengravers.com>
Cc: Ian Abbott <abbotti at mev.co.uk>
Cc: Greg Kroah-Hartman <gregkh at linuxfoundation.org>
---
drivers/staging/comedi/drivers/usbduxsigma.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/staging/comedi/drivers/usbduxsigma.c b/drivers/staging/comedi/drivers/usbduxsigma.c
index bdbcc48..b879965 100644
--- a/drivers/staging/comedi/drivers/usbduxsigma.c
+++ b/drivers/staging/comedi/drivers/usbduxsigma.c
@@ -1834,10 +1834,8 @@ static int usbduxsigma_auto_attach(struct comedi_device *dev,
}
ret = usbduxsigma_alloc_usb_buffers(dev);
- if (ret) {
- tidy_up(devpriv);
+ if (ret)
return ret;
- }
ret = comedi_load_firmware(dev, &usb->dev, FIRMWARE,
usbduxsigma_firmware_upload, 0);
--
1.8.1.4
More information about the devel
mailing list