staging: iio: remove now defunct header definitions and add some statics
authorJonathan Cameron <jic23@cam.ac.uk>
Tue, 30 Aug 2011 11:32:48 +0000 (12:32 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 6 Sep 2011 22:59:10 +0000 (15:59 -0700)
Now we have combined all chrdevs into one, some bits and bobs are only
needed in industrialio-core.c and don't need to be in the core header.

Also remove some unused defines.

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/iio/iio_core.h
drivers/staging/iio/industrialio-core.c

index a27fa05d6609acf8822b4abe24a6c9337ee97fa1..433952bb843a0a8e4c1217134f51622838592d03 100644 (file)
 #ifndef _IIO_CORE_H_
 #define _IIO_CORE_H_
 
-/**
- * iio_device_get_chrdev_minor() - get an unused minor number
- **/
-int iio_device_get_chrdev_minor(void);
-void iio_device_free_chrdev_minor(int val);
-
-
 /**
  * iio_put() - internal module reference count reduce
  **/
@@ -30,8 +23,6 @@ void iio_put(void);
  **/
 void iio_get(void);
 
-extern dev_t iio_devt;
-
 int __iio_add_chan_devattr(const char *postfix,
                           const char *group,
                           struct iio_chan_spec const *chan,
index e55edfa5586d39efbc5c91bdafd86b079e322391..de918782d3bca39ec72c9bd33eda8051f5cd47e1 100644 (file)
@@ -27,9 +27,6 @@
 #include "iio_core_trigger.h"
 #include "chrdev.h"
 
-#define IIO_ID_PREFIX "device"
-#define IIO_ID_FORMAT IIO_ID_PREFIX "%d"
-
 /* IDR to assign each registered device a unique id*/
 static DEFINE_IDA(iio_ida);
 /* IDR to allocate character device minor numbers */
@@ -37,7 +34,7 @@ static DEFINE_IDA(iio_chrdev_ida);
 /* Lock used to protect both of the above */
 static DEFINE_SPINLOCK(iio_ida_lock);
 
-dev_t iio_devt;
+static dev_t iio_devt;
 
 #define IIO_DEV_MAX 256
 struct bus_type iio_bus_type = {
@@ -276,7 +273,7 @@ static const struct file_operations iio_event_chrdev_fileops = {
        .llseek = noop_llseek,
 };
 
-int iio_device_get_chrdev_minor(void)
+static int iio_device_get_chrdev_minor(void)
 {
        int ret;
 
@@ -287,7 +284,7 @@ int iio_device_get_chrdev_minor(void)
                return -ENOMEM;
 }
 
-void iio_device_free_chrdev_minor(int val)
+static void iio_device_free_chrdev_minor(int val)
 {
        iio_free_ida_val(&iio_chrdev_ida, val);
 }
This page took 0.126451 seconds and 5 git commands to generate.