From: Octavian Purdila <octavian.purdila@intel.com>
To: linux-iio@vger.kernel.org
Cc: srinivas.pandruvada@linux.intel.com,
Octavian Purdila <octavian.purdila@intel.com>
Subject: [PATCH v5 0/3] iio: add support for hardware fifos
Date: Wed, 4 Mar 2015 19:56:10 +0200 [thread overview]
Message-ID: <1425491773-28499-1-git-send-email-octavian.purdila@intel.com> (raw)
Sorry for spawning a new patch set so quickly, but based on the
comments from Lars I rewrote the read watermark logic and the patches
are now hopefully easier to review than the previous patch set.
Changes since v4:
* rewrite the watermark read logic to fix an undeflow issue and allow
draining when the buffer is disabled
* manipulate the watermark field under the device lock
* use wake_up_interruptible_poll
* bmc150: flush the fifo before disabling the buffer and take the
device mutex when emabling/disabling the fifo
Changes since v3:
* remove hwfifo_length and make hwfifo_watermark read-only
* remove trigger for hardware fifo
* use the buffer watermark as a hint for the hardware fifo
* hwfifo_watermark is negative if the device does not support hardware
fifo, 0 if hardware fifo is supported but currently disabled and a
strictly positive value if hardware fifo is enabled in which case
this is the watermark for the hardware fifo
* the hardware fifo is activated by the device driver when it makes
sense (e.g. at buffer enable time if there is no conflicting
trigger)
* move the hwfifo operations to struct iio_info
* remove the flush from the poll operation - it causes unnecessary
flush operations
* move the wait condition logic in a separate function to make it more
readable
* bmc150: make sure to check the I2C bus supports either full i2c or
at least SMBUS i2c block read as fifo reads must do a burst read of
the whole frame (all 3 axis)
* bmc150: rework the way we timestamp the samples stored in the fifo
to account for sampling frequency variations from device to device
Josselin Costanzi (1):
iio: add watermark logic to iio read and poll
Octavian Purdila (2):
iio: add support for hardware fifo
iio: bmc150_accel: add support for hardware fifo
Documentation/ABI/testing/sysfs-bus-iio | 40 ++++
drivers/iio/accel/bmc150-accel.c | 363 +++++++++++++++++++++++++++++--
drivers/iio/industrialio-buffer.c | 177 +++++++++++++--
drivers/iio/kfifo_buf.c | 11 +-
drivers/staging/iio/accel/sca3000_ring.c | 4 +-
include/linux/iio/buffer.h | 8 +-
include/linux/iio/iio.h | 26 +++
7 files changed, 581 insertions(+), 48 deletions(-)
--
1.9.1
next reply other threads:[~2015-03-04 17:56 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-03-04 17:56 Octavian Purdila [this message]
2015-03-04 17:56 ` [PATCH v5 1/3] iio: add watermark logic to iio read and poll Octavian Purdila
2015-03-14 17:46 ` Jonathan Cameron
2015-03-18 9:19 ` Lars-Peter Clausen
2015-03-18 9:29 ` Octavian Purdila
2015-03-18 9:37 ` Lars-Peter Clausen
2015-03-19 15:43 ` Octavian Purdila
2015-03-19 15:46 ` Octavian Purdila
2015-03-04 17:56 ` [PATCH v5 2/3] iio: add support for hardware fifo Octavian Purdila
2015-03-14 18:16 ` Jonathan Cameron
2015-03-16 10:05 ` Octavian Purdila
2015-03-21 12:16 ` Jonathan Cameron
2015-03-18 11:55 ` Lars-Peter Clausen
2015-03-18 16:47 ` Octavian Purdila
2015-03-21 12:18 ` Jonathan Cameron
2015-03-04 17:56 ` [PATCH v5 3/3] iio: bmc150_accel: " Octavian Purdila
2015-03-14 18:32 ` Jonathan Cameron
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1425491773-28499-1-git-send-email-octavian.purdila@intel.com \
--to=octavian.purdila@intel.com \
--cc=linux-iio@vger.kernel.org \
--cc=srinivas.pandruvada@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).