public inbox for linux-iio@vger.kernel.org
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Linus Walleij <linus.walleij@linaro.org>,
	Hartmut Knaack <knaack.h@gmx.de>,
	Lars-Peter Clausen <lars@metafoo.de>,
	Peter Meerwald <pmeerw@pmeerw.net>,
	linux-iio@vger.kernel.org, Denis CIOCCA <denis.ciocca@st.com>
Cc: Lee Jones <lee.jones@linaro.org>
Subject: Re: [PATCH 04/10] iio: st_sensors: make detection more helpful
Date: Mon, 04 May 2015 17:24:13 +0100	[thread overview]
Message-ID: <55479D2D.7000807@kernel.org> (raw)
In-Reply-To: <1430399755-26475-4-git-send-email-linus.walleij@linaro.org>

On 30/04/15 14:15, Linus Walleij wrote:
> The ST sensors are detected by reading a WhoAmI register and
> matching the number found to a sensor name string. To make it
> easier to figure out what happens when things go wrong, print
> the WhoAmI value and the device name we're trying to match.
> 
> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Applied.
> ---
>  drivers/iio/common/st_sensors/st_sensors_core.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/iio/common/st_sensors/st_sensors_core.c b/drivers/iio/common/st_sensors/st_sensors_core.c
> index cbeb5e01bc3a..1255b157c71c 100644
> --- a/drivers/iio/common/st_sensors/st_sensors_core.c
> +++ b/drivers/iio/common/st_sensors/st_sensors_core.c
> @@ -503,7 +503,8 @@ int st_sensors_check_device_support(struct iio_dev *indio_dev,
>  			break;
>  	}
>  	if (n == ARRAY_SIZE(sensor_settings[i].sensors_supported)) {
> -		dev_err(&indio_dev->dev, "device name and WhoAmI mismatch.\n");
> +		dev_err(&indio_dev->dev, "device name \"%s\" and WhoAmI (0x%02x) mismatch",
> +			indio_dev->name, wai);
>  		goto sensor_name_mismatch;
>  	}
>  
> 


  reply	other threads:[~2015-05-04 16:24 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-30 13:15 [PATCH 01/10] iio: st_sensors: print error when failing to get IRQ Linus Walleij
2015-04-30 13:15 ` [PATCH 02/10] iio: st_sensors: make interrupt optional Linus Walleij
2015-05-04 16:20   ` Jonathan Cameron
2015-04-30 13:15 ` [PATCH 04/10] iio: st_sensors: make detection more helpful Linus Walleij
2015-05-04 16:24   ` Jonathan Cameron [this message]
2015-04-30 13:15 ` [PATCH 05/10] iio: magnetometer: support for lsm303dlh Linus Walleij
2015-05-04 16:26   ` Jonathan Cameron
2015-04-30 13:15 ` [PATCH 06/10] iio: st_accel: support 8bit channel data Linus Walleij
2015-04-30 14:56   ` Peter Meerwald
2015-05-04 12:11     ` Linus Walleij
2015-05-04 16:39       ` Jonathan Cameron
2015-05-05 12:22         ` Linus Walleij
2015-05-05 12:41           ` Linus Walleij
2015-04-30 13:15 ` [PATCH 07/10] iio: st_accel: support the LIS331DL sensor Linus Walleij
2015-04-30 13:15 ` [PATCH 08/10] ARM: ux500: fix lsm303dlh magnetometer compat string Linus Walleij
2015-05-04 16:33   ` Jonathan Cameron
2015-04-30 13:15 ` [PATCH 09/10] ARM: ux500: assign the sensor trigger IRQs Linus Walleij
2015-04-30 13:15 ` [PATCH 10/10] ARM: ux500: add the sensors to the STUIB board Linus Walleij
2015-05-04 16:17 ` [PATCH 01/10] iio: st_sensors: print error when failing to get IRQ 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=55479D2D.7000807@kernel.org \
    --to=jic23@kernel.org \
    --cc=denis.ciocca@st.com \
    --cc=knaack.h@gmx.de \
    --cc=lars@metafoo.de \
    --cc=lee.jones@linaro.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-iio@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