Linux IIO development
 help / color / mirror / Atom feed
From: Lars-Peter Clausen <lars@metafoo.de>
To: Peter Meerwald <pmeerw@pmeerw.net>
Cc: jic23@cam.ac.uk, linux-iio@vger.kernel.org
Subject: Re: lis3l02dq_core fails to compile
Date: Mon, 06 Aug 2012 10:53:58 +0200	[thread overview]
Message-ID: <501F8626.5030007@metafoo.de> (raw)
In-Reply-To: <alpine.DEB.2.01.1208061029320.1363@pmeerw.net>

On 08/06/2012 10:39 AM, Peter Meerwald wrote:
> Hello,
> 
> staging/iio/accel/lis3l02dq_core.c fails to compile when irq_to_gpio() is 
> not available
> 
> the solution is to pass both, irq and gpio via platform data (e.g. as 
> done by staging/iio/magnetometer/ak8975.c)?
> 

gpio_to_irq will always be available. While irq_to_gpio is deprecated. So it
should work if you just pass the gpio.

But looking at the driver it only seems to check if the IRQ is a valid GPIO,
but never seems use the GPIO pin otherwise. Maybe I missed something, but
I'd just remove the whole  gpio_is_valid(irq_to_gpio(spi->irq)) check.

- Lars

  reply	other threads:[~2012-08-06  8:53 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-06  8:39 lis3l02dq_core fails to compile Peter Meerwald
2012-08-06  8:53 ` Lars-Peter Clausen [this message]
2012-08-06  9:04   ` Peter Meerwald

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=501F8626.5030007@metafoo.de \
    --to=lars@metafoo.de \
    --cc=jic23@cam.ac.uk \
    --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