summaryrefslogtreecommitdiffstats
path: root/include/linux/iio/trigger.h
diff options
context:
space:
mode:
authorLars-Peter Clausen <lars@metafoo.de>2012-04-26 13:35:01 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-04-29 21:23:49 -0400
commit7cbb753701d11f3c71e8543e1ae0fc0772edac06 (patch)
tree53954c72751f1842d8565aff3a1ca1b71826603a /include/linux/iio/trigger.h
parent5d4a6789d5957a6388ea86c811d7c09bbe5f8ebd (diff)
downloadlinux-7cbb753701d11f3c71e8543e1ae0fc0772edac06.tar.bz2
staging:iio: Streamline API function naming
Currently we use two different naming schemes in the IIO API, iio_verb_object and iio_object_verb. E.g iio_device_register and iio_allocate_device. This patches renames instances of the later to the former. The patch also renames allocate to alloc as this seems to be the preferred form throughout the kernel. In particular the following renames are performed by the patch: iio_put_device -> iio_device_put iio_allocate_device -> iio_device_alloc iio_free_device -> iio_device_free iio_get_trigger -> iio_trigger_get iio_put_trigger -> iio_trigger_put iio_allocate_trigger -> iio_trigger_alloc iio_free_trigger -> iio_trigger_free The conversion was done with the following coccinelle patch with manual fixes to comments and documentation. <smpl> @@ @@ -iio_put_device +iio_device_put @@ @@ -iio_allocate_device +iio_device_alloc @@ @@ -iio_free_device +iio_device_free @@ @@ -iio_get_trigger +iio_trigger_get @@ @@ -iio_put_trigger +iio_trigger_put @@ @@ -iio_allocate_trigger +iio_trigger_alloc @@ @@ -iio_free_trigger +iio_trigger_free </smpl> Signed-off-by: Lars-Peter Clausen <lars@metafoo.de> Acked-by: Jonathan Cameron <jic23@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/iio/trigger.h')
-rw-r--r--include/linux/iio/trigger.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/linux/iio/trigger.h b/include/linux/iio/trigger.h
index 1cfca231db8f..a9819940a84c 100644
--- a/include/linux/iio/trigger.h
+++ b/include/linux/iio/trigger.h
@@ -78,13 +78,13 @@ static inline struct iio_trigger *to_iio_trigger(struct device *d)
return container_of(d, struct iio_trigger, dev);
};
-static inline void iio_put_trigger(struct iio_trigger *trig)
+static inline void iio_trigger_put(struct iio_trigger *trig)
{
module_put(trig->ops->owner);
put_device(&trig->dev);
};
-static inline void iio_get_trigger(struct iio_trigger *trig)
+static inline void iio_trigger_get(struct iio_trigger *trig)
{
get_device(&trig->dev);
__module_get(trig->ops->owner);
@@ -113,7 +113,7 @@ void iio_trigger_poll_chained(struct iio_trigger *trig, s64 time);
irqreturn_t iio_trigger_generic_data_rdy_poll(int irq, void *private);
-__printf(1, 2) struct iio_trigger *iio_allocate_trigger(const char *fmt, ...);
-void iio_free_trigger(struct iio_trigger *trig);
+__printf(1, 2) struct iio_trigger *iio_trigger_alloc(const char *fmt, ...);
+void iio_trigger_free(struct iio_trigger *trig);
#endif /* _IIO_TRIGGER_H_ */