linux-api.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Andrew F. Davis" <afd@ti.com>
To: Jonathan Cameron <jic23@kernel.org>,
	Hartmut Knaack <knaack.h@gmx.de>,
	Lars-Peter Clausen <lars@metafoo.de>,
	Peter Meerwald <pmeerw@pmeerw.net>
Cc: linux-iio@vger.kernel.org, linux-api@vger.kernel.org,
	linux-kernel@vger.kernel.org, "Andrew F. Davis" <afd@ti.com>
Subject: [PATCH 06/13] iio: health/afe440x: Remove unneeded offset handling
Date: Sun, 1 May 2016 15:36:56 -0500	[thread overview]
Message-ID: <1462135023-14445-7-git-send-email-afd@ti.com> (raw)
In-Reply-To: <1462135023-14445-1-git-send-email-afd@ti.com>

No channel in the afe4403 driver has IIO_CHAN_INFO_OFFSET set so
remove the handlers for this.

Signed-off-by: Andrew F. Davis <afd@ti.com>
---
 drivers/iio/health/afe4403.c | 17 -----------------
 1 file changed, 17 deletions(-)

diff --git a/drivers/iio/health/afe4403.c b/drivers/iio/health/afe4403.c
index bcff528..cac6090 100644
--- a/drivers/iio/health/afe4403.c
+++ b/drivers/iio/health/afe4403.c
@@ -293,14 +293,6 @@ static int afe4403_read_raw(struct iio_dev *indio_dev,
 			if (ret)
 				return ret;
 			return IIO_VAL_INT;
-		case IIO_CHAN_INFO_OFFSET:
-			ret = regmap_read(afe->regmap, reg_info.offreg,
-					  val);
-			if (ret)
-				return ret;
-			*val &= reg_info.mask;
-			*val >>= reg_info.shift;
-			return IIO_VAL_INT;
 		}
 		break;
 	case IIO_CURRENT:
@@ -333,15 +325,6 @@ static int afe4403_write_raw(struct iio_dev *indio_dev,
 	const struct afe440x_reg_info reg_info = afe4403_reg_info[chan->address];
 
 	switch (chan->type) {
-	case IIO_INTENSITY:
-		switch (mask) {
-		case IIO_CHAN_INFO_OFFSET:
-			return regmap_update_bits(afe->regmap,
-				reg_info.offreg,
-				reg_info.mask,
-				(val << reg_info.shift));
-		}
-		break;
 	case IIO_CURRENT:
 		switch (mask) {
 		case IIO_CHAN_INFO_RAW:
-- 
2.8.1

  parent reply	other threads:[~2016-05-01 20:36 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-01 20:36 [PATCH 00/13] Rework for AFE440x drivers to prepare for AFE4405 Andrew F. Davis
2016-05-01 20:36 ` [PATCH 01/13] iio: health/afe440x: Fix kernel-doc format Andrew F. Davis
     [not found]   ` <1462135023-14445-2-git-send-email-afd-l0cyMroinI0@public.gmane.org>
2016-05-04  9:58     ` Jonathan Cameron
2016-05-01 20:36 ` [PATCH 02/13] iio: health/afe440x: Remove of_match_ptr and ifdefs Andrew F. Davis
2016-05-04  9:59   ` Jonathan Cameron
2016-05-01 20:36 ` [PATCH 04/13] iio: health/afe440x: Always use separate gain values Andrew F. Davis
2016-05-04 10:02   ` Jonathan Cameron
2016-05-04 15:13     ` Andrew F. Davis
2016-05-04 18:33       ` Jonathan Cameron
2016-05-01 20:36 ` Andrew F. Davis [this message]
     [not found]   ` <1462135023-14445-7-git-send-email-afd-l0cyMroinI0@public.gmane.org>
2016-05-04 10:04     ` [PATCH 06/13] iio: health/afe440x: Remove unneeded offset handling Jonathan Cameron
2016-05-01 20:36 ` [PATCH 07/13] iio: health/afe4404: Remove LED3 input channel Andrew F. Davis
2016-05-04 10:04   ` Jonathan Cameron
2016-05-01 20:37 ` [PATCH 10/13] iio: health/afe440x: Make gain settings a modifier for the stages Andrew F. Davis
2016-05-04 10:12   ` Jonathan Cameron
     [not found] ` <1462135023-14445-1-git-send-email-afd-l0cyMroinI0@public.gmane.org>
2016-05-01 20:36   ` [PATCH 03/13] iio: health/afe440x: Remove unneeded initializers Andrew F. Davis
2016-05-04  9:59     ` Jonathan Cameron
2016-05-01 20:36   ` [PATCH 05/13] iio: health/afe440x: Fix scan_index assignment Andrew F. Davis
     [not found]     ` <1462135023-14445-6-git-send-email-afd-l0cyMroinI0@public.gmane.org>
2016-05-04 10:03       ` Jonathan Cameron
2016-05-01 20:36   ` [PATCH 08/13] iio: health/afe440x: Remove channel names Andrew F. Davis
2016-05-04 10:08     ` Jonathan Cameron
     [not found]       ` <f0679a4f-c8f0-1712-e7fc-a61350734a03-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2016-05-04 15:28         ` Andrew F. Davis
2016-05-01 20:36   ` [PATCH 09/13] iio: health/afe440x: Use regmap fields Andrew F. Davis
2016-05-04 10:10     ` Jonathan Cameron
     [not found]       ` <45523060-7ae8-076f-dece-34e76e8a740a-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2016-05-04 15:30         ` Andrew F. Davis
2016-05-01 20:37   ` [PATCH 11/13] iio: health/afe440x: Match LED currents to stages Andrew F. Davis
2016-05-04 10:13     ` Jonathan Cameron
2016-05-01 20:37   ` [PATCH 12/13] iio: health/afe440x: Remove unused definitions Andrew F. Davis
2016-05-04 10:14     ` Jonathan Cameron
2016-05-01 20:37   ` [PATCH 13/13] iio: health/afe4404: ENSEPGAIN is part of CONTROL2 register Andrew F. Davis
2016-05-04 10:14     ` Jonathan Cameron
2016-05-04 10:25 ` [PATCH 00/13] Rework for AFE440x drivers to prepare for AFE4405 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=1462135023-14445-7-git-send-email-afd@ti.com \
    --to=afd@ti.com \
    --cc=jic23@kernel.org \
    --cc=knaack.h@gmx.de \
    --cc=lars@metafoo.de \
    --cc=linux-api@vger.kernel.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pmeerw@pmeerw.net \
    /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).