All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH 0/5] Add kfifo based buffer implementation
@ 2010-12-19 20:33 Jonathan Cameron
  2010-12-19 20:33 ` [PATCH 1/5] staging:iio:buffering move the copy to user on rip down into implementations Jonathan Cameron
                   ` (5 more replies)
  0 siblings, 6 replies; 9+ messages in thread
From: Jonathan Cameron @ 2010-12-19 20:33 UTC (permalink / raw)
  To: linux-iio; +Cc: Michael.Hennerich, Jonathan Cameron

This set is an update of the proof of concept I wrote a while back.
This time around I've simply used a byte stream buffer rather than
variable record sizes.  The first patch pushes some of the
exiting buffer code down into the ring_sw implementation to
make it simpler to provide other implementations.

What you gain by picking kfifo:
* Clean fast code for the underlying buffer.

What you loose:
* Events - userspace has to 'know' how often to read the buffer
  so as to not loose data.

Obvious difference is it is a fifo rather than a ring buffer.

This buffer should also lend itself to a simple implementation
of a store_n function which should be useful for devices with
a hardware ring which we then want to feed into a software one.

Jonathan Cameron (5):
  staging:iio:buffering  move the copy to user on rip down into
    implementations
  staging:iio:kfifo buffer implementation
  staging:iio:lis3l02dq allow buffer implementation selection
  staging:iio: update example to handle case with no ring events
  staging:iio: buffer example - add lots more runtime parameters

 drivers/staging/iio/Documentation/generic_buffer.c |   63 +++++--
 drivers/staging/iio/Kconfig                        |    6 +
 drivers/staging/iio/Makefile                       |    1 +
 drivers/staging/iio/accel/Kconfig                  |   23 +++-
 drivers/staging/iio/accel/lis3l02dq.h              |   10 +
 drivers/staging/iio/accel/lis3l02dq_ring.c         |    9 +-
 drivers/staging/iio/industrialio-ring.c            |   23 +--
 drivers/staging/iio/kfifo_buf.c                    |  196 ++++++++++++++++++++
 drivers/staging/iio/kfifo_buf.h                    |   56 ++++++
 drivers/staging/iio/ring_generic.h                 |    2 +-
 drivers/staging/iio/ring_sw.c                      |   29 ++-
 drivers/staging/iio/ring_sw.h                      |    4 +-
 12 files changed, 363 insertions(+), 59 deletions(-)
 create mode 100644 drivers/staging/iio/kfifo_buf.c
 create mode 100644 drivers/staging/iio/kfifo_buf.h


^ permalink raw reply	[flat|nested] 9+ messages in thread

* [PATCH 1/5] staging:iio:buffering  move the copy to user on rip down into implementations
  2010-12-19 20:33 [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
@ 2010-12-19 20:33 ` Jonathan Cameron
  2010-12-19 20:33 ` [PATCH 2/5] staging:iio:kfifo buffer implementation Jonathan Cameron
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 9+ messages in thread
From: Jonathan Cameron @ 2010-12-19 20:33 UTC (permalink / raw)
  To: linux-iio; +Cc: Michael.Hennerich, Jonathan Cameron

The current interface is not as adaptable as it should be. Moving
this complexity into the implementations makes it easier to add
new implementations.

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
---
 drivers/staging/iio/industrialio-ring.c |   23 ++---------------------
 drivers/staging/iio/ring_generic.h      |    2 +-
 drivers/staging/iio/ring_sw.c           |   29 ++++++++++++++++++-----------
 drivers/staging/iio/ring_sw.h           |    4 ++--
 4 files changed, 23 insertions(+), 35 deletions(-)

diff --git a/drivers/staging/iio/industrialio-ring.c b/drivers/staging/iio/industrialio-ring.c
index 9a98fcd..40256e7 100644
--- a/drivers/staging/iio/industrialio-ring.c
+++ b/drivers/staging/iio/industrialio-ring.c
@@ -16,7 +16,6 @@
 #include <linux/kernel.h>
 #include <linux/device.h>
 #include <linux/fs.h>
-#include <linux/poll.h>
 #include <linux/cdev.h>
 #include <linux/slab.h>
 
@@ -98,31 +97,13 @@ static ssize_t iio_ring_rip_outer(struct file *filp, char __user *buf,
 				  size_t count, loff_t *f_ps)
 {
 	struct iio_ring_buffer *rb = filp->private_data;
-	int ret, dead_offset, copied;
+	int ret, dead_offset;
 	u8 *data;
 	/* rip lots must exist. */
 	if (!rb->access.rip_lots)
 		return -EINVAL;
-	copied = rb->access.rip_lots(rb, count, &data, &dead_offset);
+	ret = rb->access.rip_lots(rb, count, buf, &dead_offset);
 
-	if (copied <= 0) {
-		ret = copied;
-		goto error_ret;
-	}
-	if (copy_to_user(buf, data + dead_offset, copied))  {
-		ret =  -EFAULT;
-		goto error_free_data_cpy;
-	}
-	/* In clever ring buffer designs this may not need to be freed.
-	 * When such a design exists I'll add this to ring access funcs.
-	 */
-	kfree(data);
-
-	return copied;
-
-error_free_data_cpy:
-	kfree(data);
-error_ret:
 	return ret;
 }
 
diff --git a/drivers/staging/iio/ring_generic.h b/drivers/staging/iio/ring_generic.h
index 8ecb189..f21ac09 100644
--- a/drivers/staging/iio/ring_generic.h
+++ b/drivers/staging/iio/ring_generic.h
@@ -73,7 +73,7 @@ struct iio_ring_access_funcs {
 	int (*read_last)(struct iio_ring_buffer *ring, u8 *data);
 	int (*rip_lots)(struct iio_ring_buffer *ring,
 			size_t count,
-			u8 **data,
+			char __user *buf,
 			int *dead_offset);
 
 	int (*mark_param_change)(struct iio_ring_buffer *ring);
diff --git a/drivers/staging/iio/ring_sw.c b/drivers/staging/iio/ring_sw.c
index 52624ac..302278c 100644
--- a/drivers/staging/iio/ring_sw.c
+++ b/drivers/staging/iio/ring_sw.c
@@ -12,6 +12,7 @@
 #include <linux/module.h>
 #include <linux/device.h>
 #include <linux/workqueue.h>
+#include <linux/poll.h>
 #include "ring_sw.h"
 #include "trigger.h"
 
@@ -152,11 +153,12 @@ error_ret:
 }
 
 int iio_rip_sw_rb(struct iio_ring_buffer *r,
-		  size_t count, u8 **data, int *dead_offset)
+		  size_t count, char __user *buf, int *dead_offset)
 {
 	struct iio_sw_ring_buffer *ring = iio_to_sw_ring(r);
 
 	u8 *initial_read_p, *initial_write_p, *current_read_p, *end_read_p;
+	u8 *data;
 	int ret, max_copied;
 	int bytes_to_rip;
 
@@ -174,8 +176,8 @@ int iio_rip_sw_rb(struct iio_ring_buffer *r,
 	/* Limit size to whole of ring buffer */
 	bytes_to_rip = min((size_t)(ring->buf.bytes_per_datum*ring->buf.length), count);
 
-	*data = kmalloc(bytes_to_rip, GFP_KERNEL);
-	if (*data == NULL) {
+	data = kmalloc(bytes_to_rip, GFP_KERNEL);
+	if (data == NULL) {
 		ret = -ENOMEM;
 		goto error_ret;
 	}
@@ -204,30 +206,30 @@ int iio_rip_sw_rb(struct iio_ring_buffer *r,
 	if (initial_write_p >= initial_read_p + bytes_to_rip) {
 		/* write_p is greater than necessary, all is easy */
 		max_copied = bytes_to_rip;
-		memcpy(*data, initial_read_p, max_copied);
+		memcpy(data, initial_read_p, max_copied);
 		end_read_p = initial_read_p + max_copied;
 	} else if (initial_write_p > initial_read_p) {
 		/*not enough data to cpy */
 		max_copied = initial_write_p - initial_read_p;
-		memcpy(*data, initial_read_p, max_copied);
+		memcpy(data, initial_read_p, max_copied);
 		end_read_p = initial_write_p;
 	} else {
 		/* going through 'end' of ring buffer */
 		max_copied = ring->data
 			+ ring->buf.length*ring->buf.bytes_per_datum - initial_read_p;
-		memcpy(*data, initial_read_p, max_copied);
+		memcpy(data, initial_read_p, max_copied);
 		/* possible we are done if we align precisely with end */
 		if (max_copied == bytes_to_rip)
 			end_read_p = ring->data;
 		else if (initial_write_p
 			 > ring->data + bytes_to_rip - max_copied) {
 			/* enough data to finish */
-			memcpy(*data + max_copied, ring->data,
+			memcpy(data + max_copied, ring->data,
 			       bytes_to_rip - max_copied);
 			max_copied = bytes_to_rip;
 			end_read_p = ring->data + (bytes_to_rip - max_copied);
 		} else {  /* not enough data */
-			memcpy(*data + max_copied, ring->data,
+			memcpy(data + max_copied, ring->data,
 			       initial_write_p - ring->data);
 			max_copied += initial_write_p - ring->data;
 			end_read_p = initial_write_p;
@@ -264,11 +266,16 @@ int iio_rip_sw_rb(struct iio_ring_buffer *r,
 	while (ring->read_p != end_read_p)
 		ring->read_p = end_read_p;
 
-	return max_copied - *dead_offset;
-
+	ret = max_copied - *dead_offset;
+	
+	if (copy_to_user(buf, data + *dead_offset, ret))  {
+		ret =  -EFAULT;
+		goto error_free_data_cpy;
+	}
 error_free_data_cpy:
-	kfree(*data);
+	kfree(data);
 error_ret:
+
 	return ret;
 }
 EXPORT_SYMBOL(iio_rip_sw_rb);
diff --git a/drivers/staging/iio/ring_sw.h b/drivers/staging/iio/ring_sw.h
index ad03d83..13341c1 100644
--- a/drivers/staging/iio/ring_sw.h
+++ b/drivers/staging/iio/ring_sw.h
@@ -96,13 +96,13 @@ int iio_store_to_sw_rb(struct iio_ring_buffer *r, u8 *data, s64 timestamp);
  * iio_rip_sw_rb() - attempt to read data from the ring buffer
  * @r:			ring buffer instance
  * @count:		number of datum's to try and read
- * @data:		where the data will be stored.
+ * @buf:		userspace buffer into which data is copied
  * @dead_offset:	how much of the stored data was possibly invalidated by
  *			the end of the copy.
  **/
 int iio_rip_sw_rb(struct iio_ring_buffer *r,
 		  size_t count,
-		  u8 **data,
+		  char __user *buf,
 		  int *dead_offset);
 
 /**
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 2/5] staging:iio:kfifo buffer implementation
  2010-12-19 20:33 [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
  2010-12-19 20:33 ` [PATCH 1/5] staging:iio:buffering move the copy to user on rip down into implementations Jonathan Cameron
@ 2010-12-19 20:33 ` Jonathan Cameron
  2010-12-19 20:33 ` [PATCH 3/5] staging:iio:lis3l02dq allow buffer implementation selection Jonathan Cameron
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 9+ messages in thread
From: Jonathan Cameron @ 2010-12-19 20:33 UTC (permalink / raw)
  To: linux-iio; +Cc: Michael.Hennerich, Jonathan Cameron

A very simple use of a kfifo as an alternative for the ring_sw

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
---
 drivers/staging/iio/Kconfig     |    6 +
 drivers/staging/iio/Makefile    |    1 +
 drivers/staging/iio/kfifo_buf.c |  196 +++++++++++++++++++++++++++++++++++++++
 drivers/staging/iio/kfifo_buf.h |   56 +++++++++++
 4 files changed, 259 insertions(+), 0 deletions(-)

diff --git a/drivers/staging/iio/Kconfig b/drivers/staging/iio/Kconfig
index e2ac07d..f664a44 100644
--- a/drivers/staging/iio/Kconfig
+++ b/drivers/staging/iio/Kconfig
@@ -29,6 +29,12 @@ config IIO_SW_RING
 	  with the intention that some devices would be able to write
 	  in interrupt context.
 
+config IIO_KFIFO_BUF
+       select IIO_TRIGGER
+       tristate "Industrial I/O buffering based on kfifo"
+       help
+         Initial version of a kfifo buffer.       
+
 endif # IIO_RINGBUFFER
 
 config IIO_TRIGGER
diff --git a/drivers/staging/iio/Makefile b/drivers/staging/iio/Makefile
index f9b5fb2..bb5c95c 100644
--- a/drivers/staging/iio/Makefile
+++ b/drivers/staging/iio/Makefile
@@ -8,6 +8,7 @@ industrialio-$(CONFIG_IIO_RING_BUFFER) += industrialio-ring.o
 industrialio-$(CONFIG_IIO_TRIGGER) += industrialio-trigger.o
 
 obj-$(CONFIG_IIO_SW_RING) += ring_sw.o
+obj-$(CONFIG_IIO_KFIFO_BUF) += kfifo_buf.o
 
 obj-y += accel/
 obj-y += adc/
diff --git a/drivers/staging/iio/kfifo_buf.c b/drivers/staging/iio/kfifo_buf.c
new file mode 100644
index 0000000..811b39d
--- /dev/null
+++ b/drivers/staging/iio/kfifo_buf.c
@@ -0,0 +1,196 @@
+#include <linux/slab.h>
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/device.h>
+#include <linux/workqueue.h>
+#include <linux/kfifo.h>
+#include <linux/mutex.h>
+
+#include "kfifo_buf.h"
+
+static inline int __iio_allocate_kfifo(struct iio_kfifo *buf,
+				int bytes_per_datum, int length)
+{
+	if ((length == 0) || (bytes_per_datum == 0))
+		return -EINVAL;
+
+	__iio_update_ring_buffer(&buf->ring, bytes_per_datum, length);
+	return kfifo_alloc(&buf->kf, bytes_per_datum*length, GFP_KERNEL);
+}
+
+int iio_request_update_kfifo(struct iio_ring_buffer *r)
+{
+	int ret = 0;
+	struct iio_kfifo *buf = iio_to_kfifo(r);
+
+	mutex_lock(&buf->use_lock);
+	if (!buf->update_needed)
+		goto error_ret;
+	if (buf->use_count) {
+		ret = -EAGAIN;
+		goto error_ret;
+	}
+	kfifo_free(&buf->kf);
+	ret = __iio_allocate_kfifo(buf, buf->ring.bytes_per_datum,
+				buf->ring.length);
+error_ret:
+	mutex_unlock(&buf->use_lock);
+	return ret;
+}
+EXPORT_SYMBOL(iio_request_update_kfifo);
+
+void iio_mark_kfifo_in_use(struct iio_ring_buffer *r)
+{
+	struct iio_kfifo *buf = iio_to_kfifo(r);
+	mutex_lock(&buf->use_lock);
+	buf->use_count++;
+	mutex_unlock(&buf->use_lock);
+}
+EXPORT_SYMBOL(iio_mark_kfifo_in_use);
+
+void iio_unmark_kfifo_in_use(struct iio_ring_buffer *r)
+{
+	struct iio_kfifo *buf = iio_to_kfifo(r);
+	mutex_lock(&buf->use_lock);
+	buf->use_count--;
+	mutex_unlock(&buf->use_lock);
+}
+EXPORT_SYMBOL(iio_unmark_kfifo_in_use);
+
+int iio_get_length_kfifo(struct iio_ring_buffer *r)
+{
+	return r->length;
+}
+EXPORT_SYMBOL(iio_get_length_kfifo);
+
+static inline void __iio_init_kfifo(struct iio_kfifo *kf)
+{
+	mutex_init(&kf->use_lock);
+}
+
+static IIO_RING_ENABLE_ATTR;
+static IIO_RING_BYTES_PER_DATUM_ATTR;
+static IIO_RING_LENGTH_ATTR;
+
+static struct attribute *iio_kfifo_attributes[] = {
+	&dev_attr_length.attr,
+	&dev_attr_bytes_per_datum.attr,
+	&dev_attr_enable.attr,
+	NULL,
+};
+
+static struct attribute_group iio_kfifo_attribute_group = {
+	.attrs = iio_kfifo_attributes,
+};
+
+static const struct attribute_group *iio_kfifo_attribute_groups[] = {
+	&iio_kfifo_attribute_group,
+	NULL
+};
+
+static void iio_kfifo_release(struct device *dev)
+{
+	struct iio_ring_buffer *r = to_iio_ring_buffer(dev);
+	struct iio_kfifo *kf = iio_to_kfifo(r);
+	kfifo_free(&kf->kf);
+	kfree(kf);
+}
+
+static struct device_type iio_kfifo_type = {
+	.release = iio_kfifo_release,
+	.groups = iio_kfifo_attribute_groups,
+};
+
+struct iio_ring_buffer *iio_kfifo_allocate(struct iio_dev *indio_dev)
+{
+	struct iio_kfifo *kf;
+
+	kf = kzalloc(sizeof *kf, GFP_KERNEL);
+	if (!kf)
+		return 0;
+	iio_ring_buffer_init(&kf->ring, indio_dev);
+	__iio_init_kfifo(kf);
+	kf->ring.dev.type = &iio_kfifo_type;
+	device_initialize(&kf->ring.dev);
+	kf->ring.dev.parent = &indio_dev->dev;
+	kf->ring.dev.bus = &iio_bus_type;
+	dev_set_drvdata(&kf->ring.dev, (void *)&(kf->ring));
+
+	return &kf->ring;
+}
+EXPORT_SYMBOL(iio_kfifo_allocate);
+
+int iio_get_bytes_per_datum_kfifo(struct iio_ring_buffer *r)
+{
+	return r->bytes_per_datum;
+}
+EXPORT_SYMBOL(iio_get_bytes_per_datum_kfifo);
+
+int iio_set_bytes_per_datum_kfifo(struct iio_ring_buffer *r, size_t bpd)
+{
+	if (r->bytes_per_datum != bpd) {
+		r->bytes_per_datum = bpd;
+		if (r->access.mark_param_change)
+			r->access.mark_param_change(r);
+	}
+	return 0;
+}
+EXPORT_SYMBOL(iio_set_bytes_per_datum_kfifo);
+
+int iio_mark_update_needed_kfifo(struct iio_ring_buffer *r)
+{
+	struct iio_kfifo *kf = iio_to_kfifo(r);
+	kf->update_needed = true;
+	return 0;
+}
+EXPORT_SYMBOL(iio_mark_update_needed_kfifo);
+
+int iio_set_length_kfifo(struct iio_ring_buffer *r, int length)
+{
+	if (r->length != length) {
+		r->length = length;
+		if (r->access.mark_param_change)
+			r->access.mark_param_change(r);
+	}
+	return 0;
+}
+EXPORT_SYMBOL(iio_set_length_kfifo);
+
+void iio_kfifo_free(struct iio_ring_buffer *r)
+{
+	if (r)
+		iio_put_ring_buffer(r);
+}
+EXPORT_SYMBOL(iio_kfifo_free);
+
+int iio_store_to_kfifo(struct iio_ring_buffer *r, u8 *data, s64 timestamp)
+{
+	int ret;
+	struct iio_kfifo *kf = iio_to_kfifo(r);
+	u8 *datal = kmalloc(r->bytes_per_datum, GFP_KERNEL);
+	memcpy(datal, data, r->bytes_per_datum - sizeof(timestamp));
+	memcpy(datal + r->bytes_per_datum - sizeof(timestamp),
+		&timestamp, sizeof(timestamp));
+	ret = kfifo_in(&kf->kf, data, r->bytes_per_datum);
+	if (ret != r->bytes_per_datum) {
+		kfree(datal);
+		return -EBUSY;
+	}
+	kfree(datal);
+	return 0;
+}
+EXPORT_SYMBOL(iio_store_to_kfifo);
+
+int iio_rip_kfifo(struct iio_ring_buffer *r,
+		size_t count, char __user *buf, int *deadoffset)
+{
+	int ret, copied;
+	struct iio_kfifo *kf = iio_to_kfifo(r);
+
+	*deadoffset = 0;
+	ret = kfifo_to_user(&kf->kf, buf, r->bytes_per_datum*count, &copied);
+
+	return copied;
+}
+EXPORT_SYMBOL(iio_rip_kfifo);
+MODULE_LICENSE("GPL");
diff --git a/drivers/staging/iio/kfifo_buf.h b/drivers/staging/iio/kfifo_buf.h
new file mode 100644
index 0000000..8064383
--- /dev/null
+++ b/drivers/staging/iio/kfifo_buf.h
@@ -0,0 +1,56 @@
+
+#include <linux/kfifo.h>
+#include "iio.h"
+#include "ring_generic.h"
+
+struct iio_kfifo {
+	struct iio_ring_buffer ring;
+	struct kfifo kf;
+	int use_count;
+	int update_needed;
+	struct mutex use_lock;
+};
+
+#define iio_to_kfifo(r) container_of(r, struct iio_kfifo, ring)
+
+int iio_create_kfifo(struct iio_ring_buffer **r);
+int iio_init_kfifo(struct iio_ring_buffer *r, struct iio_dev *indio_dev);
+void iio_exit_kfifo(struct iio_ring_buffer *r);
+void iio_free_kfifo(struct iio_ring_buffer *r);
+void iio_mark_kfifo_in_use(struct iio_ring_buffer *r);
+void iio_unmark_kfifo_in_use(struct iio_ring_buffer *r);
+
+int iio_store_to_kfifo(struct iio_ring_buffer *r, u8 *data, s64 timestamp);
+int iio_rip_kfifo(struct iio_ring_buffer *r,
+		size_t count,
+		char __user *buf,
+		int *dead_offset);
+
+int iio_request_update_kfifo(struct iio_ring_buffer *r);
+int iio_mark_update_needed_kfifo(struct iio_ring_buffer *r);
+
+int iio_get_bytes_per_datum_kfifo(struct iio_ring_buffer *r);
+int iio_set_bytes_per_datum_kfifo(struct iio_ring_buffer *r, size_t bpd);
+int iio_get_length_kfifo(struct iio_ring_buffer *r);
+int iio_set_length_kfifo(struct iio_ring_buffer *r, int length);
+
+static inline void iio_kfifo_register_funcs(struct iio_ring_access_funcs *ra)
+{
+	ra->mark_in_use = &iio_mark_kfifo_in_use;
+	ra->unmark_in_use = &iio_unmark_kfifo_in_use;
+
+	ra->store_to = &iio_store_to_kfifo;
+	ra->rip_lots = &iio_rip_kfifo;
+
+	ra->mark_param_change = &iio_mark_update_needed_kfifo;
+	ra->request_update = &iio_request_update_kfifo;
+
+	ra->get_bytes_per_datum = &iio_get_bytes_per_datum_kfifo;
+	ra->set_bytes_per_datum = &iio_set_bytes_per_datum_kfifo;
+	ra->get_length = &iio_get_length_kfifo;
+	ra->set_length = &iio_set_length_kfifo;
+};
+
+struct iio_ring_buffer *iio_kfifo_allocate(struct iio_dev *indio_dev);
+void iio_kfifo_free(struct iio_ring_buffer *r);
+
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 3/5] staging:iio:lis3l02dq allow buffer implementation selection
  2010-12-19 20:33 [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
  2010-12-19 20:33 ` [PATCH 1/5] staging:iio:buffering move the copy to user on rip down into implementations Jonathan Cameron
  2010-12-19 20:33 ` [PATCH 2/5] staging:iio:kfifo buffer implementation Jonathan Cameron
@ 2010-12-19 20:33 ` Jonathan Cameron
  2010-12-19 20:33 ` [PATCH 4/5] staging:iio: update example to handle case with no ring events Jonathan Cameron
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 9+ messages in thread
From: Jonathan Cameron @ 2010-12-19 20:33 UTC (permalink / raw)
  To: linux-iio; +Cc: Michael.Hennerich, Jonathan Cameron

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
---
 drivers/staging/iio/accel/Kconfig          |   23 ++++++++++++++++++++++-
 drivers/staging/iio/accel/lis3l02dq.h      |   10 ++++++++++
 drivers/staging/iio/accel/lis3l02dq_ring.c |    9 +++++----
 3 files changed, 37 insertions(+), 5 deletions(-)

diff --git a/drivers/staging/iio/accel/Kconfig b/drivers/staging/iio/accel/Kconfig
index a34f1d3..7fbf87e 100644
--- a/drivers/staging/iio/accel/Kconfig
+++ b/drivers/staging/iio/accel/Kconfig
@@ -66,12 +66,33 @@ config LIS3L02DQ
 	tristate "ST Microelectronics LIS3L02DQ Accelerometer Driver"
 	depends on SPI
 	select IIO_TRIGGER if IIO_RING_BUFFER
-	select IIO_SW_RING if IIO_RING_BUFFER
+	depends on !IIO_RING_BUFFER || IIO_KFIFO_BUF || IIO_SW_RING
 	help
 	  Say yes here to build SPI support for the ST microelectronics
 	  accelerometer. The driver supplies direct access via sysfs files
 	  and an event interface via a character device.
 
+choice
+	prompt "Buffer type"
+       	depends on LIS3L02DQ
+
+config LIS3L02DQ_BUF_KFIFO
+       depends on IIO_KFIFO_BUF
+       bool "Simple FIFO"
+       help
+         Kfifo based FIFO.  Does not provide any events so it is up
+	 to userspace to ensure it reads often enough that data is not
+	 lost.
+
+config LIS3L02DQ_BUF_RING_SW
+       depends on IIO_SW_RING
+       bool "IIO Software Ring"
+       help
+         Original IIO ring buffer implementation.  Provides simple
+	 buffer events, half full etc.
+
+endchoice
+
 config SCA3000
 	depends on IIO_RING_BUFFER
 	depends on SPI
diff --git a/drivers/staging/iio/accel/lis3l02dq.h b/drivers/staging/iio/accel/lis3l02dq.h
index 6e73055..579b3a2 100644
--- a/drivers/staging/iio/accel/lis3l02dq.h
+++ b/drivers/staging/iio/accel/lis3l02dq.h
@@ -196,6 +196,16 @@ ssize_t lis3l02dq_read_accel_from_ring(struct device *dev,
 int lis3l02dq_configure_ring(struct iio_dev *indio_dev);
 void lis3l02dq_unconfigure_ring(struct iio_dev *indio_dev);
 
+#ifdef CONFIG_LIS3L02DQ_BUF_RING_SW
+#define lis3l02dq_free_buf iio_sw_rb_free
+#define lis3l02dq_alloc_buf iio_sw_rb_allocate
+#define lis3l02dq_register_buf_funcs iio_ring_sw_register_funcs
+#endif
+#ifdef CONFIG_LIS3L02DQ_BUF_KFIFO
+#define lis3l02dq_free_buf iio_kfifo_free
+#define lis3l02dq_alloc_buf iio_kfifo_allocate
+#define lis3l02dq_register_buf_funcs iio_kfifo_register_funcs
+#endif
 #else /* CONFIG_IIO_RING_BUFFER */
 
 static inline void lis3l02dq_remove_trigger(struct iio_dev *indio_dev)
diff --git a/drivers/staging/iio/accel/lis3l02dq_ring.c b/drivers/staging/iio/accel/lis3l02dq_ring.c
index 1fd088a..2c461a3 100644
--- a/drivers/staging/iio/accel/lis3l02dq_ring.c
+++ b/drivers/staging/iio/accel/lis3l02dq_ring.c
@@ -13,6 +13,7 @@
 #include "../iio.h"
 #include "../sysfs.h"
 #include "../ring_sw.h"
+#include "../kfifo_buf.h"
 #include "accel.h"
 #include "../trigger.h"
 #include "lis3l02dq.h"
@@ -484,7 +485,7 @@ void lis3l02dq_remove_trigger(struct iio_dev *indio_dev)
 void lis3l02dq_unconfigure_ring(struct iio_dev *indio_dev)
 {
 	kfree(indio_dev->pollfunc);
-	iio_sw_rb_free(indio_dev->ring);
+	lis3l02dq_free_buf(indio_dev->ring);
 }
 
 int lis3l02dq_configure_ring(struct iio_dev *indio_dev)
@@ -495,13 +496,13 @@ int lis3l02dq_configure_ring(struct iio_dev *indio_dev)
 	INIT_WORK(&h->work_trigger_to_ring, lis3l02dq_trigger_bh_to_ring);
 	h->get_ring_element = &lis3l02dq_get_ring_element;
 
-	ring = iio_sw_rb_allocate(indio_dev);
+	ring = lis3l02dq_alloc_buf(indio_dev);
 	if (!ring)
 		return -ENOMEM;
 
 	indio_dev->ring = ring;
 	/* Effectively select the ring buffer implementation */
-	iio_ring_sw_register_funcs(&ring->access);
+	lis3l02dq_register_buf_funcs(&ring->access);
 	ring->bpe = 2;
 	ring->scan_el_attrs = &lis3l02dq_scan_el_group;
 	ring->scan_timestamp = true;
@@ -522,6 +523,6 @@ int lis3l02dq_configure_ring(struct iio_dev *indio_dev)
 	return 0;
 
 error_iio_sw_rb_free:
-	iio_sw_rb_free(indio_dev->ring);
+	lis3l02dq_free_buf(indio_dev->ring);
 	return ret;
 }
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 4/5] staging:iio: update example to handle case with no ring events
  2010-12-19 20:33 [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
                   ` (2 preceding siblings ...)
  2010-12-19 20:33 ` [PATCH 3/5] staging:iio:lis3l02dq allow buffer implementation selection Jonathan Cameron
@ 2010-12-19 20:33 ` Jonathan Cameron
  2010-12-19 20:33 ` [PATCH 5/5] staging:iio: buffer example - add lots more runtime parameters Jonathan Cameron
  2011-02-05 19:48 ` [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
  5 siblings, 0 replies; 9+ messages in thread
From: Jonathan Cameron @ 2010-12-19 20:33 UTC (permalink / raw)
  To: linux-iio; +Cc: Michael.Hennerich, Jonathan Cameron

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
---
 drivers/staging/iio/Documentation/generic_buffer.c |   45 +++++++++++++-------
 1 files changed, 29 insertions(+), 16 deletions(-)

diff --git a/drivers/staging/iio/Documentation/generic_buffer.c b/drivers/staging/iio/Documentation/generic_buffer.c
index df23aeb..0befcb8 100644
--- a/drivers/staging/iio/Documentation/generic_buffer.c
+++ b/drivers/staging/iio/Documentation/generic_buffer.c
@@ -26,6 +26,7 @@
 #include <sys/stat.h>
 #include <sys/dir.h>
 #include <linux/types.h>
+#include <string.h>
 #include "iio_utils.h"
 
 const int buf_len = 128;
@@ -134,10 +135,11 @@ int main(int argc, char **argv)
 	int dev_num, trig_num;
 	char *buffer_access, *buffer_event;
 	int scan_size;
+	int noevents = 0;
 
 	struct iio_channel_info *infoarray;
 
-	while ((c = getopt(argc, argv, "t:n:")) != -1) {
+	while ((c = getopt(argc, argv, "et:n:")) != -1) {
 		switch (c) {
 		case 'n':
 			device_name = optarg;
@@ -146,6 +148,9 @@ int main(int argc, char **argv)
 			trigger_name = optarg;
 			datardytrigger = 0;
 			break;
+		case 'e':
+			noevents = 1;
+			break;
 		case '?':
 			return -1;
 		}
@@ -260,22 +265,30 @@ int main(int argc, char **argv)
 
 	/* Wait for events 10 times */
 	for (j = 0; j < num_loops; j++) {
-		read_size = fread(&dat, 1, sizeof(struct iio_event_data),
-				  fp_ev);
-		switch (dat.id) {
-		case IIO_EVENT_CODE_RING_100_FULL:
-			toread = buf_len;
-			break;
-		case IIO_EVENT_CODE_RING_75_FULL:
-			toread = buf_len*3/4;
-			break;
-		case IIO_EVENT_CODE_RING_50_FULL:
-			toread = buf_len/2;
-			break;
-		default:
-			printf("Unexpecteded event code\n");
-			continue;
+		if (!noevents) {
+			read_size = fread(&dat,
+					1,
+					sizeof(struct iio_event_data),
+					fp_ev);
+			switch (dat.id) {
+			case IIO_EVENT_CODE_RING_100_FULL:
+				toread = buf_len;
+				break;
+			case IIO_EVENT_CODE_RING_75_FULL:
+				toread = buf_len*3/4;
+				break;
+			case IIO_EVENT_CODE_RING_50_FULL:
+				toread = buf_len/2;
+				break;
+			default:
+				printf("Unexpecteded event code\n");
+				continue;
+			}
+		} else {
+			usleep(1000);
+			toread = 64;
 		}
+
 		read_size = read(fp,
 				 data,
 				 toread*scan_size);
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH 5/5] staging:iio: buffer example - add lots more runtime parameters
  2010-12-19 20:33 [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
                   ` (3 preceding siblings ...)
  2010-12-19 20:33 ` [PATCH 4/5] staging:iio: update example to handle case with no ring events Jonathan Cameron
@ 2010-12-19 20:33 ` Jonathan Cameron
  2011-02-05 19:48 ` [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
  5 siblings, 0 replies; 9+ messages in thread
From: Jonathan Cameron @ 2010-12-19 20:33 UTC (permalink / raw)
  To: linux-iio; +Cc: Michael.Hennerich, Jonathan Cameron

Add ability to control delay for event free buffers
Add ability to control length of buffer
Add ability to control how many read cycles occur

Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
---
 drivers/staging/iio/Documentation/generic_buffer.c |   22 +++++++++++++++----
 1 files changed, 17 insertions(+), 5 deletions(-)

diff --git a/drivers/staging/iio/Documentation/generic_buffer.c b/drivers/staging/iio/Documentation/generic_buffer.c
index 0befcb8..771b236 100644
--- a/drivers/staging/iio/Documentation/generic_buffer.c
+++ b/drivers/staging/iio/Documentation/generic_buffer.c
@@ -29,9 +29,6 @@
 #include <string.h>
 #include "iio_utils.h"
 
-const int buf_len = 128;
-const int num_loops = 2;
-
 /**
  * size_from_channelarray() - calculate the storage size of a scan
  * @channels: the channel info array
@@ -119,6 +116,11 @@ void process_scan(char *data,
 
 int main(int argc, char **argv)
 {
+	unsigned long num_loops = 2;
+	unsigned long timedelay = 1000000;
+	unsigned long buf_len = 128;
+
+
 	int ret, c, i, j, toread;
 
 	FILE *fp_ev;
@@ -136,10 +138,11 @@ int main(int argc, char **argv)
 	char *buffer_access, *buffer_event;
 	int scan_size;
 	int noevents = 0;
+	char *dummy;
 
 	struct iio_channel_info *infoarray;
 
-	while ((c = getopt(argc, argv, "et:n:")) != -1) {
+	while ((c = getopt(argc, argv, "l:w:c:et:n:")) != -1) {
 		switch (c) {
 		case 'n':
 			device_name = optarg;
@@ -151,6 +154,15 @@ int main(int argc, char **argv)
 		case 'e':
 			noevents = 1;
 			break;
+		case 'c':
+			num_loops = strtoul(optarg, &dummy, 10);
+			break;
+		case 'w':
+			timedelay = strtoul(optarg, &dummy, 10);
+			break;
+		case 'l':
+			buf_len = strtoul(optarg, &dummy, 10);
+			break;
 		case '?':
 			return -1;
 		}
@@ -285,7 +297,7 @@ int main(int argc, char **argv)
 				continue;
 			}
 		} else {
-			usleep(1000);
+			usleep(timedelay);
 			toread = 64;
 		}
 
-- 
1.7.0.4

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [RFC PATCH 0/5] Add kfifo based buffer implementation
  2010-12-19 20:33 [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
                   ` (4 preceding siblings ...)
  2010-12-19 20:33 ` [PATCH 5/5] staging:iio: buffer example - add lots more runtime parameters Jonathan Cameron
@ 2011-02-05 19:48 ` Jonathan Cameron
  2011-02-07 10:25   ` Hennerich, Michael
  2011-02-08 20:36   ` Hennerich, Michael
  5 siblings, 2 replies; 9+ messages in thread
From: Jonathan Cameron @ 2011-02-05 19:48 UTC (permalink / raw)
  To: Jonathan Cameron; +Cc: linux-iio, Michael.Hennerich

On 12/19/10 20:33, Jonathan Cameron wrote:
> This set is an update of the proof of concept I wrote a while back.
> This time around I've simply used a byte stream buffer rather than
> variable record sizes.  The first patch pushes some of the
> exiting buffer code down into the ring_sw implementation to
> make it simpler to provide other implementations.
> 
> What you gain by picking kfifo:
> * Clean fast code for the underlying buffer.
> 
> What you loose:
> * Events - userspace has to 'know' how often to read the buffer
>   so as to not loose data.
> 
> Obvious difference is it is a fifo rather than a ring buffer.
> 
> This buffer should also lend itself to a simple implementation
> of a store_n function which should be useful for devices with
> a hardware ring which we then want to feed into a software one.

If anyone has time to take a look at this, it would be great to
get some feedback. If not I propose merging it anyway soon.
There is still work to be done to get this to an optimal state, but
right now it works so might as well make it available.

I fear my sw_ring implementation is one of the main blockers to moving
IIO out of staging so would like to show how easy it is to use
alternatives.  On that note we should probably have some documentation
to provide a clear explanation of when to pick one buffer over another.

The 'What option should a distro use?' question Greg raised the other
day will here be controlled by driver writers setting a suitable
default buffer choice if they implement multiple options.
> 
> Jonathan Cameron (5):
>   staging:iio:buffering  move the copy to user on rip down into
>     implementations
>   staging:iio:kfifo buffer implementation
>   staging:iio:lis3l02dq allow buffer implementation selection
>   staging:iio: update example to handle case with no ring events
>   staging:iio: buffer example - add lots more runtime parameters
> 
>  drivers/staging/iio/Documentation/generic_buffer.c |   63 +++++--
>  drivers/staging/iio/Kconfig                        |    6 +
>  drivers/staging/iio/Makefile                       |    1 +
>  drivers/staging/iio/accel/Kconfig                  |   23 +++-
>  drivers/staging/iio/accel/lis3l02dq.h              |   10 +
>  drivers/staging/iio/accel/lis3l02dq_ring.c         |    9 +-
>  drivers/staging/iio/industrialio-ring.c            |   23 +--
>  drivers/staging/iio/kfifo_buf.c                    |  196 ++++++++++++++++++++
>  drivers/staging/iio/kfifo_buf.h                    |   56 ++++++
>  drivers/staging/iio/ring_generic.h                 |    2 +-
>  drivers/staging/iio/ring_sw.c                      |   29 ++-
>  drivers/staging/iio/ring_sw.h                      |    4 +-
>  12 files changed, 363 insertions(+), 59 deletions(-)
>  create mode 100644 drivers/staging/iio/kfifo_buf.c
>  create mode 100644 drivers/staging/iio/kfifo_buf.h
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: [RFC PATCH 0/5] Add kfifo based buffer implementation
  2011-02-05 19:48 ` [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
@ 2011-02-07 10:25   ` Hennerich, Michael
  2011-02-08 20:36   ` Hennerich, Michael
  1 sibling, 0 replies; 9+ messages in thread
From: Hennerich, Michael @ 2011-02-07 10:25 UTC (permalink / raw)
  To: Jonathan Cameron; +Cc: linux-iio, device-drivers-devel

Jonathan Cameron wrote on 2011-02-05:
> On 12/19/10 20:33, Jonathan Cameron wrote:
>> This set is an update of the proof of concept I wrote a while back.
>> This time around I've simply used a byte stream buffer rather than
>> variable record sizes.  The first patch pushes some of the exiting
>> buffer code down into the ring_sw implementation to make it simpler to
>> provide other implementations.
>>
>> What you gain by picking kfifo:
>> * Clean fast code for the underlying buffer.
>>
>> What you loose:
>> * Events - userspace has to 'know' how often to read the buffer
>>   so as to not loose data.
>> Obvious difference is it is a fifo rather than a ring buffer.
>>
>> This buffer should also lend itself to a simple implementation of a
>> store_n function which should be useful for devices with a hardware
>> ring which we then want to feed into a software one.
>
> If anyone has time to take a look at this, it would be great to get
> some feedback. If not I propose merging it anyway soon.
> There is still work to be done to get this to an optimal state, but
> right now it works so might as well make it available.

A while ago I applied and tested this patch.
I looked and seemed to work fine. I have to admit I didn't do
extensive testing with it.

-Michael


> I fear my sw_ring implementation is one of the main blockers to moving
> IIO out of staging so would like to show how easy it is to use
> alternatives.  On that note we should probably have some documentation
> to provide a clear explanation of when to pick one buffer over another.
>
> The 'What option should a distro use?' question Greg raised the other
> day will here be controlled by driver writers setting a suitable
> default buffer choice if they implement multiple options.
>>
>> Jonathan Cameron (5):
>>   staging:iio:buffering  move the copy to user on rip down into
>>     implementations
>>   staging:iio:kfifo buffer implementation
>>   staging:iio:lis3l02dq allow buffer implementation selection
>>   staging:iio: update example to handle case with no ring events
>>   staging:iio: buffer example - add lots more runtime parameters
>>  drivers/staging/iio/Documentation/generic_buffer.c |   63 +++++--
>>  drivers/staging/iio/Kconfig                        |    6 +
>>  drivers/staging/iio/Makefile                       |    1 +
>>  drivers/staging/iio/accel/Kconfig                  |   23 +++-
>>  drivers/staging/iio/accel/lis3l02dq.h              |   10 +
>>  drivers/staging/iio/accel/lis3l02dq_ring.c         |    9 +-
>>  drivers/staging/iio/industrialio-ring.c            |   23 +--
>>  drivers/staging/iio/kfifo_buf.c                    |  196
>>  ++++++++++++++++++++ drivers/staging/iio/kfifo_buf.h
>>   |   56 ++++++ drivers/staging/iio/ring_generic.h                 |
>>  2 +- drivers/staging/iio/ring_sw.c                      |   29 ++-
>>  drivers/staging/iio/ring_sw.h                      |    4 +- 12 files
>>  changed, 363 insertions(+), 59 deletions(-)  create mode
>> 100644 drivers/staging/iio/kfifo_buf.c  create mode 100644
>> drivers/staging/iio/kfifo_buf.h
>>
>

Greetings,
Michael

--
Analog Devices GmbH      Wilhelm-Wagenfeld-Str. 6      80807 Muenchen
Sitz der Gesellschaft: Muenchen; Registergericht: Muenchen HRB 40368; Gesch=
aeftsfuehrer:Dr.Carsten Suckrow, Thomas Wessel, William A. Martin, Margaret=
 Seif

^ permalink raw reply	[flat|nested] 9+ messages in thread

* RE: [RFC PATCH 0/5] Add kfifo based buffer implementation
  2011-02-05 19:48 ` [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
  2011-02-07 10:25   ` Hennerich, Michael
@ 2011-02-08 20:36   ` Hennerich, Michael
  1 sibling, 0 replies; 9+ messages in thread
From: Hennerich, Michael @ 2011-02-08 20:36 UTC (permalink / raw)
  To: Hennerich, Michael, Jonathan Cameron; +Cc: linux-iio, device-drivers-devel


> From: Hennerich, Michael
> Jonathan Cameron wrote on 2011-02-05:
> > On 12/19/10 20:33, Jonathan Cameron wrote:
> >> This set is an update of the proof of concept I wrote a while back.
> >> This time around I've simply used a byte stream buffer rather than
> >> variable record sizes.  The first patch pushes some of the exiting
> >> buffer code down into the ring_sw implementation to make it simpler
> to
> >> provide other implementations.
> >>
> >> What you gain by picking kfifo:
> >> * Clean fast code for the underlying buffer.
> >>
> >> What you loose:
> >> * Events - userspace has to 'know' how often to read the buffer
> >>   so as to not loose data.
> >> Obvious difference is it is a fifo rather than a ring buffer.
> >>
> >> This buffer should also lend itself to a simple implementation of a
> >> store_n function which should be useful for devices with a hardware
> >> ring which we then want to feed into a software one.
> >
> > If anyone has time to take a look at this, it would be great to get
> > some feedback. If not I propose merging it anyway soon.
> > There is still work to be done to get this to an optimal state, but
> > right now it works so might as well make it available.
>
> A while ago I applied and tested this patch.
> I looked and seemed to work fine. I have to admit I didn't do
> extensive testing with it.

Tested-by: Michael Hennerich <michael.hennerich@analog.com>

> -Michael
>
>
> > I fear my sw_ring implementation is one of the main blockers to
> moving
> > IIO out of staging so would like to show how easy it is to use
> > alternatives.  On that note we should probably have some
> documentation
> > to provide a clear explanation of when to pick one buffer over
> another.
> >
> > The 'What option should a distro use?' question Greg raised the other
> > day will here be controlled by driver writers setting a suitable
> > default buffer choice if they implement multiple options.
> >>
> >> Jonathan Cameron (5):
> >>   staging:iio:buffering  move the copy to user on rip down into
> >>     implementations
> >>   staging:iio:kfifo buffer implementation
> >>   staging:iio:lis3l02dq allow buffer implementation selection
> >>   staging:iio: update example to handle case with no ring events
> >>   staging:iio: buffer example - add lots more runtime parameters
> >>  drivers/staging/iio/Documentation/generic_buffer.c |   63 +++++--
> >>  drivers/staging/iio/Kconfig                        |    6 +
> >>  drivers/staging/iio/Makefile                       |    1 +
> >>  drivers/staging/iio/accel/Kconfig                  |   23 +++-
> >>  drivers/staging/iio/accel/lis3l02dq.h              |   10 +
> >>  drivers/staging/iio/accel/lis3l02dq_ring.c         |    9 +-
> >>  drivers/staging/iio/industrialio-ring.c            |   23 +--
> >>  drivers/staging/iio/kfifo_buf.c                    |  196
> >>  ++++++++++++++++++++ drivers/staging/iio/kfifo_buf.h
> >>   |   56 ++++++ drivers/staging/iio/ring_generic.h                 |
> >>  2 +- drivers/staging/iio/ring_sw.c                      |   29 ++-
> >>  drivers/staging/iio/ring_sw.h                      |    4 +- 12
> files
> >>  changed, 363 insertions(+), 59 deletions(-)  create mode
> >> 100644 drivers/staging/iio/kfifo_buf.c  create mode 100644
> >> drivers/staging/iio/kfifo_buf.h
> >>
> >
>
> Greetings,
> Michael
>
> --
> Analog Devices GmbH      Wilhelm-Wagenfeld-Str. 6      80807 Muenchen
> Sitz der Gesellschaft: Muenchen; Registergericht: Muenchen HRB 40368;
> Geschaeftsfuehrer:Dr.Carsten Suckrow, Thomas Wessel, William A. Martin,
> Margaret Seif
>

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2011-02-08 20:36 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-12-19 20:33 [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
2010-12-19 20:33 ` [PATCH 1/5] staging:iio:buffering move the copy to user on rip down into implementations Jonathan Cameron
2010-12-19 20:33 ` [PATCH 2/5] staging:iio:kfifo buffer implementation Jonathan Cameron
2010-12-19 20:33 ` [PATCH 3/5] staging:iio:lis3l02dq allow buffer implementation selection Jonathan Cameron
2010-12-19 20:33 ` [PATCH 4/5] staging:iio: update example to handle case with no ring events Jonathan Cameron
2010-12-19 20:33 ` [PATCH 5/5] staging:iio: buffer example - add lots more runtime parameters Jonathan Cameron
2011-02-05 19:48 ` [RFC PATCH 0/5] Add kfifo based buffer implementation Jonathan Cameron
2011-02-07 10:25   ` Hennerich, Michael
2011-02-08 20:36   ` Hennerich, Michael

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.