From: Alison Schofield <amsfield22@gmail.com>
To: jic23@kernel.org
Cc: tiberiu.a.breana@intel.com, mranostay@gmail.com, knaack.h@gmx.de,
lars@metafoo.de, pmeerw@pmeerw.net, linux-iio@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: [PATCH 0/3] iio: complete the setup of buffer timestamps
Date: Mon, 11 Jul 2016 08:24:12 -0700 [thread overview]
Message-ID: <cover.1468203399.git.amsfield22@gmail.com> (raw)
These drivers are using iio_poll_func->timestamp in their triggered buffer
handler as the timestamp pushed to buffer. Problem is that it was not set up
at probe time via iio_triggered_buffer_setup(), so timestamp is always 0.
Buffer space has been allocated for the timestamp, so it seems to be
wanted.
These patches make the fix io_triggered_buffer_setup() during probe by
passing the iio_pollfunc_store_time parameter.
Alternative change would be to use iio_get_time_ns() directly in the
push_to_buffers call in the handler. We can do this if you are not
one of those "devices (who) need a timestamp grabbed as soon as possible
after the trigger" (from iio_poll_func definition)
Either way you are using iio_get_tme_ns(), it's just a question of when.
Let me know if you'd rather go the slower way.
Alison Schofield (3):
iio: accel: bma220_spi: set up buffer timestamps for non-zero values
iio: humidity: am2315: set up buffer timestamps for non-zero values
iio: proximity: as3935: set up buffer timestamps for non-zero values
drivers/iio/accel/bma220_spi.c | 2 +-
drivers/iio/humidity/am2315.c | 2 +-
drivers/iio/proximity/as3935.c | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
--
2.1.4
next reply other threads:[~2016-07-11 15:24 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-11 15:24 Alison Schofield [this message]
2016-07-11 15:25 ` [PATCH 1/3] iio: accel: bma220_spi: set up buffer timestamps for non-zero values Alison Schofield
2016-07-11 15:53 ` Breana, Tiberiu A
2016-07-24 12:05 ` Jonathan Cameron
2016-07-11 15:26 ` [PATCH 2/3] iio: humidity: am2315: " Alison Schofield
2016-07-11 15:54 ` Breana, Tiberiu A
2016-07-24 12:07 ` Jonathan Cameron
2016-07-11 15:26 ` [PATCH 3/3] iio: proximity: as3935: " Alison Schofield
2016-07-24 12:09 ` 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=cover.1468203399.git.amsfield22@gmail.com \
--to=amsfield22@gmail.com \
--cc=jic23@kernel.org \
--cc=knaack.h@gmx.de \
--cc=lars@metafoo.de \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mranostay@gmail.com \
--cc=pmeerw@pmeerw.net \
--cc=tiberiu.a.breana@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).