staging: comedi: change type of num_subdevices parameter to comedi_alloc_subdevices
authorH Hartley Sweeten <hartleys@visionengravers.com>
Tue, 12 Jun 2012 18:57:27 +0000 (11:57 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 12 Jun 2012 21:40:51 +0000 (14:40 -0700)
The n_subdevices variable of struct comedi_device is an int type.
Change the type of the comedi_alloc_subdevices 'num_subdevices' from
an unsigned int to an int to match it.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbott@mev.co.uk>
Cc: Frank Mori Hess <fmhess@users.sourceforge.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/comedi/comedidev.h
drivers/staging/comedi/drivers.c

index bb98f82141a171c8029c619db73df09e2371ac76..e0f3915b0f63d573d18829fac413c00db5470f79 100644 (file)
@@ -292,7 +292,7 @@ static inline struct comedi_subdevice *comedi_get_write_subdevice(
        return info->device->write_subdev;
 }
 
-int comedi_alloc_subdevices(struct comedi_device *, unsigned int);
+int comedi_alloc_subdevices(struct comedi_device *, int);
 
 void comedi_device_detach(struct comedi_device *dev);
 int comedi_device_attach(struct comedi_device *dev,
index 541364782b5f692dfbb80d6d1cdc4f7e80da322f..979aa0e889973c6ce1f1ff639d62196da7ab5a6d 100644 (file)
@@ -56,10 +56,9 @@ static int poll_invalid(struct comedi_device *dev, struct comedi_subdevice *s);
 
 struct comedi_driver *comedi_drivers;
 
-int comedi_alloc_subdevices(struct comedi_device *dev,
-                           unsigned int num_subdevices)
+int comedi_alloc_subdevices(struct comedi_device *dev, int num_subdevices)
 {
-       unsigned i;
+       int i;
 
        dev->n_subdevices = num_subdevices;
        dev->subdevices =