All of lore.kernel.org
 help / color / mirror / Atom feed
From: Lars-Peter Clausen <lars@metafoo.de>
To: Jonathan Cameron <jic23@kernel.org>
Cc: linux-iio@vger.kernel.org, device-drivers-devel@blackfin.uclinux.org
Subject: Re: [PATCH 12/14] staging:iio:impedance-analyzer:ad5933 unwind use of IIO_CHAN macro.
Date: Wed, 11 Apr 2012 13:46:15 +0200	[thread overview]
Message-ID: <4F856F07.9030401@metafoo.de> (raw)
In-Reply-To: <1334089310-22576-13-git-send-email-jic23@kernel.org>

On 04/10/2012 10:21 PM, Jonathan Cameron wrote:
> This macro is being removed to simplify ongoing maintenance
> so we need to unwind and remaining users.
> 
> Signed-off-by: Jonathan Cameron <jic23@kernel.org>

The cocci patches disagrees on one occasion, but I think it's a bug in the
original driver again.

Acked-by: Lars-Peter Clausen <lars@metafoo.de>

> ---
>  drivers/staging/iio/impedance-analyzer/ad5933.c |   47 ++++++++++++++++++-----
>  1 file changed, 38 insertions(+), 9 deletions(-)
> 
> diff --git a/drivers/staging/iio/impedance-analyzer/ad5933.c b/drivers/staging/iio/impedance-analyzer/ad5933.c
> index cd82b56..06b9fe2 100644
> --- a/drivers/staging/iio/impedance-analyzer/ad5933.c
> +++ b/drivers/staging/iio/impedance-analyzer/ad5933.c
> @@ -109,15 +109,44 @@ static struct ad5933_platform_data ad5933_default_pdata  = {
>  };
>  
>  static struct iio_chan_spec ad5933_channels[] = {
> -	IIO_CHAN(IIO_TEMP, 0, 1, 1, NULL, 0, 0, 0,
> -		 0, AD5933_REG_TEMP_DATA, IIO_ST('s', 14, 16, 0), 0),
> -	/* Ring Channels */
> -	IIO_CHAN(IIO_VOLTAGE, 0, 1, 0, "real_raw", 0, 0,
> -		 IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
> -		 AD5933_REG_REAL_DATA, 0, IIO_ST('s', 16, 16, 0), 0),
> -	IIO_CHAN(IIO_VOLTAGE, 0, 1, 0, "imag_raw", 0, 0,
> -		 IIO_CHAN_INFO_SCALE_SEPARATE_BIT,
> -		 AD5933_REG_IMAG_DATA, 1, IIO_ST('s', 16, 16, 0), 0),
> +	{
> +		.type = IIO_TEMP,
> +		.indexed = 1,
> +		.processed_val = 1,
> +		.channel = 0,
> +		.address = AD5933_REG_TEMP_DATA,

address was set to 0 and scan_index was set to AD5933_REG_TEMP_DATA with the
original code, but that doesn't make any sense.

> +		.scan_type = {
> +			.sign = 's',
> +			.realbits = 14,
> +			.storagebits = 16,
> +		},
> +	}

  reply	other threads:[~2012-04-11 11:46 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-10 20:21 [PATCH 00/14] IIO: Kill off IIO_CHAN macro Jonathan Cameron
2012-04-10 20:21 ` [PATCH 01/14] staging:iio:accel:adis16201 unwind use of " Jonathan Cameron
2012-04-11 11:39   ` Lars-Peter Clausen
2012-04-10 20:21 ` [PATCH 02/14] staging:iio:accel:adis16203 " Jonathan Cameron
2012-04-11 11:39   ` Lars-Peter Clausen
2012-04-10 20:21 ` [PATCH 03/14] staging:iio:accel:adis16204 " Jonathan Cameron
2012-04-11 11:40   ` Lars-Peter Clausen
2012-04-10 20:21 ` [PATCH 04/14] staging:iio:accel:adis16209 " Jonathan Cameron
2012-04-11 11:42   ` Lars-Peter Clausen
2012-04-10 20:21 ` [PATCH 05/14] staging:iio:accel:adis16240 " Jonathan Cameron
2012-04-11 11:25   ` Lars-Peter Clausen
2012-04-11 17:46     ` [PATCH V2] " Jonathan Cameron
2012-04-13  8:26       ` Lars-Peter Clausen
2012-04-13  8:26         ` Lars-Peter Clausen
2012-04-10 20:21 ` [PATCH 06/14] staging:iio:accel:lis3l02dq " Jonathan Cameron
2012-04-10 20:21 ` [PATCH 07/14] staging:iio:accel:sca3000 " Jonathan Cameron
2012-04-10 20:21 ` [PATCH 08/14] staging:iio:adc:ad7298 " Jonathan Cameron
2012-04-11 11:44   ` Lars-Peter Clausen
2012-04-10 20:21 ` [PATCH 09/14] staging:iio:adc:ad7476 " Jonathan Cameron
2012-04-11  9:47   ` Lars-Peter Clausen
2012-04-11 17:41     ` [PATCH V2] " Jonathan Cameron
2012-04-13  8:22       ` Lars-Peter Clausen
2012-04-10 20:21 ` [PATCH 10/14] staging:iio:accel:ad7780 " Jonathan Cameron
2012-04-11 11:49   ` Lars-Peter Clausen
2012-04-10 20:21 ` [PATCH 11/14] staging:iio:gyro:adis16260 " Jonathan Cameron
2012-04-11 11:52   ` Lars-Peter Clausen
2012-04-10 20:21 ` [PATCH 12/14] staging:iio:impedance-analyzer:ad5933 " Jonathan Cameron
2012-04-11 11:46   ` Lars-Peter Clausen [this message]
2012-04-10 20:21 ` [PATCH 13/14] staging:iio:meter:ade7758 " Jonathan Cameron
2012-04-11 11:47   ` Lars-Peter Clausen
2012-04-10 20:21 ` [PATCH 14/14] staging:iio:core drop the IIO_CHAN macro for ease of maintenance Jonathan Cameron
2012-04-11 11:21 ` [PATCH 00/14] IIO: Kill off IIO_CHAN macro Lars-Peter Clausen
2012-04-11 11:20   ` Jonathan Cameron
2012-04-11 11:55     ` Lars-Peter Clausen
2012-04-11 11:53       ` Jonathan Cameron
  -- strict thread matches above, loose matches on Subject: below --
2012-04-13  9:42 [PATCH 00/14 V2] " Jonathan Cameron
2012-04-13  9:42 ` [PATCH 12/14] staging:iio:impedance-analyzer:ad5933 unwind use of " 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=4F856F07.9030401@metafoo.de \
    --to=lars@metafoo.de \
    --cc=device-drivers-devel@blackfin.uclinux.org \
    --cc=jic23@kernel.org \
    --cc=linux-iio@vger.kernel.org \
    /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 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.