[PATCH 25/53] staging: comedi: usbdux: pass comedi_device pointer to usbdux_alloc_usb_buffers()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



For aesthetic reasons, pass the comedi_device pointer to this function
instead of the private data pointer.

Signed-off-by: H Hartley Sweeten <hsweeten@xxxxxxxxxxxxxxxxxxx>
Cc: Ian Abbott <abbotti@xxxxxxxxx>
Cc: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxx>
---
 drivers/staging/comedi/drivers/usbdux.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/comedi/drivers/usbdux.c b/drivers/staging/comedi/drivers/usbdux.c
index 5980b8e..c3fbfdc 100644
--- a/drivers/staging/comedi/drivers/usbdux.c
+++ b/drivers/staging/comedi/drivers/usbdux.c
@@ -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;
 
-- 
1.8.3.2

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel




[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux