linux-iio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: linux-iio@vger.kernel.org
Cc: greg@kroah.com, guenter.roeck@ericsson.com, khali@linux-fr.org,
	dmitry.torokhov@gmail.com, broonie@opensource.wolfsonmicro.com,
	alan@lxorguk.ukuu.org.uk, arnd@arndb.de,
	linus.walleij@linaro.org, maxime.ripard@free-electrons.com,
	thomas.petazzoni@free-electrons.com, zdevai@gmail.com,
	w.sang@pengutronix.de, marek.vasut@gmail.com,
	Jonathan Cameron <jic23@kernel.org>
Subject: [PATCH 0/6 V6] IIO: in kernel (as opposed to userspace) pull consumers
Date: Wed, 15 Feb 2012 19:47:59 +0000	[thread overview]
Message-ID: <1329335285-31006-1-git-send-email-jic23@kernel.org> (raw)

Previously IIO: in kernel pull interfaces.

Changes since the RFC V5.  The race condition on exit is avoided by
the introduction of the first patch and related modifications later.
All in kernel consumers ultimately access the IIO devices through
the iio_info structure pointer in the relevant iio_dev structure.
Thus (protected by a mutex) we can set this to null on device removal
and check it in users.  Thus ensuring a clean error is returned if
the provider is removed before the consumer has finished with it.
Right now there is nothing to even make this hard but we can
easily get the module at a later date to cut down on this happening.

Otherwise, I've made the whole thing no longer an option for IIO
as suggested by Linus.

Few cleanups beyond that from testing and appopriate updates to the
documentation.

Any comments?  I'd like to get this out the way so we can move
on to the more 'interesting' case of push interfaces (those that
are interrupt driven).  Patches for that are ready but need cleaning
up and are more invasive that these within IIO itself.

Jonathan

Jonathan Cameron (6):
  staging:iio:core set the iio_dev.info pointer to null on unregister
    under lock.
  staging:iio:core add in kernel interface mapping and getting IIO
    channels.
  staging:iio: move iio data return types into types.h for use by
    inkern
  staging:iio::hwmon interface client driver.
  staging:iio:Documentation in kernel pull description.
  stargate2: example of map configuration for iio to hwmon example.

 arch/arm/mach-pxa/stargate2.c                  |   24 ++
 drivers/staging/iio/Documentation/inkernel.txt |   58 +++++
 drivers/staging/iio/Kconfig                    |    7 +
 drivers/staging/iio/Makefile                   |    4 +-
 drivers/staging/iio/consumer.h                 |   96 ++++++++
 drivers/staging/iio/driver.h                   |   34 +++
 drivers/staging/iio/iio.h                      |    8 +-
 drivers/staging/iio/iio_hwmon.c                |  232 +++++++++++++++++++
 drivers/staging/iio/industrialio-core.c        |    4 +
 drivers/staging/iio/inkern.c                   |  292 ++++++++++++++++++++++++
 drivers/staging/iio/machine.h                  |   24 ++
 drivers/staging/iio/types.h                    |    4 +
 12 files changed, 780 insertions(+), 7 deletions(-)
 create mode 100644 drivers/staging/iio/Documentation/inkernel.txt
 create mode 100644 drivers/staging/iio/consumer.h
 create mode 100644 drivers/staging/iio/driver.h
 create mode 100644 drivers/staging/iio/iio_hwmon.c
 create mode 100644 drivers/staging/iio/inkern.c
 create mode 100644 drivers/staging/iio/machine.h

-- 
1.7.8.4


             reply	other threads:[~2012-02-15 19:47 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-15 19:47 Jonathan Cameron [this message]
2012-02-15 19:48 ` [PATCH 1/6] staging:iio:core set the iio_dev.info pointer to null on unregister under lock Jonathan Cameron
2012-02-15 19:48 ` [PATCH 2/6] staging:iio:core add in kernel interface mapping and getting IIO channels Jonathan Cameron
2012-02-15 19:48 ` [PATCH 3/6] staging:iio: move iio data return types into types.h for use by inkern Jonathan Cameron
2012-02-15 19:48 ` [PATCH 4/6] staging:iio::hwmon interface client driver Jonathan Cameron
2012-02-15 19:48 ` [PATCH 5/6] staging:iio:Documentation in kernel pull description Jonathan Cameron
2012-02-15 19:48 ` [PATCH 6/6] stargate2: example of map configuration for iio to hwmon example Jonathan Cameron
2012-02-15 21:07   ` Jonathan Cameron
2012-02-24 20:07     ` Greg KH
2012-02-25 11:19       ` Jonathan Cameron
2012-02-15 21:11 ` [PATCH 5.5/6] staging:iio:max1363 enable use with inkernel interfaces Jonathan Cameron
2012-02-15 21:50 ` [PATCH 0/6 V6] IIO: in kernel (as opposed to userspace) pull consumers Linus Walleij
2012-02-24 20:10   ` Greg KH

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=1329335285-31006-1-git-send-email-jic23@kernel.org \
    --to=jic23@kernel.org \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=arnd@arndb.de \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=dmitry.torokhov@gmail.com \
    --cc=greg@kroah.com \
    --cc=guenter.roeck@ericsson.com \
    --cc=khali@linux-fr.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=marek.vasut@gmail.com \
    --cc=maxime.ripard@free-electrons.com \
    --cc=thomas.petazzoni@free-electrons.com \
    --cc=w.sang@pengutronix.de \
    --cc=zdevai@gmail.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).