From: Tony Lindgren <tony@atomide.com>
To: Kyungmin Park <kyungmin.park@samsung.com>
Cc: linux-omap@vger.kernel.org
Subject: Re: [PATCH] Fix tsx210x detection
Date: Thu, 13 Mar 2008 13:31:44 +0200 [thread overview]
Message-ID: <20080313113143.GE11653@atomide.com> (raw)
In-Reply-To: <20080306005848.GA20807@party>
* Kyungmin Park <kyungmin.park@samsung.com> [080306 02:59]:
> If the return value is all 0xff, it means there's no device.
>
> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
> ---
> diff --git a/drivers/spi/tsc210x.c b/drivers/spi/tsc210x.c
> index df8bcf9..1d2ac94 100644
> --- a/drivers/spi/tsc210x.c
> +++ b/drivers/spi/tsc210x.c
> @@ -1092,6 +1092,11 @@ static int tsc210x_probe(struct spi_device *spi, enum tsc_type type)
> dev_dbg(&dev->spi->dev, "revision, err %d\n", err);
> goto err_spi;
> }
> + if (reg == 0xffff) {
> + err = -ENODEV;
> + dev_dbg(&dev->spi->dev, "no device, err %d\n", err);
> + goto err_spi;
> + }
> dev_info(&spi->dev, "rev %d, irq %d\n", reg & 0x0007, spi->irq);
>
> err = tsc210x_configure(dev);
Pushing today.
Tony
parent reply other threads:[~2008-03-13 11:31 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <20080306005848.GA20807@party>]
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=20080313113143.GE11653@atomide.com \
--to=tony@atomide.com \
--cc=kyungmin.park@samsung.com \
--cc=linux-omap@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox