staging: comedi: usbdux: pass comedi_device pointer to usbdux_alloc_usb_buffers()
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Wed, 24 Jul 2013 21:16:04 +0000 (14:16 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 25 Jul 2013 20:15:36 +0000 (13:15 -0700)
For aesthetic reasons, pass the comedi_device pointer to this function
instead of the private data pointer.

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

index 5980b8e366949f03cc4f7ac586d5da1848b636f4..c3fbfdc6fc5c4e5243d776537e0874c653ecb724 100644 (file)
@@ -1729,8 +1729,9 @@ static int usbdux_pwm_config(struct comedi_device *dev,
 /* end of PWM */
 /*****************************************************************/
 
-static int usbdux_alloc_usb_buffers(struct usbdux_private *devpriv)
+static int usbdux_alloc_usb_buffers(struct comedi_device *dev)
 {
+       struct usbdux_private *devpriv = dev->private;
        struct urb *urb;
        int i;
 
@@ -1909,7 +1910,7 @@ static int usbdux_auto_attach(struct comedi_device *dev,
                devpriv->num_out_buffers = NUMOFOUTBUFFERSFULL;
        }
 
-       ret = usbdux_alloc_usb_buffers(devpriv);
+       ret = usbdux_alloc_usb_buffers(dev);
        if (ret)
                return ret;