linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Grant Likely <grant.likely@secretlab.ca>
To: Wolfram Sang <w.sang@pengutronix.de>
Cc: linuxppc-dev@lists.ozlabs.org, linux-i2c@vger.kernel.org,
	Ben Dooks <ben-linux@fluff.org>,
	Sean MacLennan <smaclennan@pikatech.com>
Subject: Re: [PATCH 3/3] i2c/ibm-iic: drop NO_IRQ
Date: Tue, 16 Feb 2010 09:01:20 -0700	[thread overview]
Message-ID: <fa686aa41002160801k7a277567r50d71fb9d827203b@mail.gmail.com> (raw)
In-Reply-To: <1256245888-25210-4-git-send-email-w.sang@pengutronix.de>

On Thu, Oct 22, 2009 at 2:11 PM, Wolfram Sang <w.sang@pengutronix.de> wrote=
:
> Drop NO_IRQ as 0 is the preferred way to describe 'no irq'
> (http://lkml.org/lkml/2005/11/21/221). This change is safe, as the driver=
 is
> only used on powerpc, where NO_IRQ is 0 anyhow.
>
> Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
> Cc: Sean MacLennan <smaclennan@pikatech.com>
> Cc: Ben Dooks <ben-linux@fluff.org>

Acked-by: Grant Likely <grant.likely@secretlab.ca>

Ben, will you pick up this series of 3, or would you like me to merge
them through the powerpc tree?

Thanks,
g.

> ---
> =A0drivers/i2c/busses/i2c-ibm_iic.c | =A0 14 +++++++-------
> =A01 files changed, 7 insertions(+), 7 deletions(-)
>
> diff --git a/drivers/i2c/busses/i2c-ibm_iic.c b/drivers/i2c/busses/i2c-ib=
m_iic.c
> index b1bc6e2..2bef534 100644
> --- a/drivers/i2c/busses/i2c-ibm_iic.c
> +++ b/drivers/i2c/busses/i2c-ibm_iic.c
> @@ -668,12 +668,12 @@ static int __devinit iic_request_irq(struct of_devi=
ce *ofdev,
> =A0 =A0 =A0 =A0int irq;
>
> =A0 =A0 =A0 =A0if (iic_force_poll)
> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 return NO_IRQ;
> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 return 0;
>
> =A0 =A0 =A0 =A0irq =3D irq_of_parse_and_map(np, 0);
> - =A0 =A0 =A0 if (irq =3D=3D NO_IRQ) {
> + =A0 =A0 =A0 if (!irq) {
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0dev_err(&ofdev->dev, "irq_of_parse_and_map=
 failed\n");
> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 return NO_IRQ;
> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 return 0;
> =A0 =A0 =A0 =A0}
>
> =A0 =A0 =A0 =A0/* Disable interrupts until we finish initialization, assu=
mes
> @@ -683,7 +683,7 @@ static int __devinit iic_request_irq(struct of_device=
 *ofdev,
> =A0 =A0 =A0 =A0if (request_irq(irq, iic_handler, 0, "IBM IIC", dev)) {
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0dev_err(&ofdev->dev, "request_irq %d faile=
d\n", irq);
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0/* Fallback to the polling mode */
> - =A0 =A0 =A0 =A0 =A0 =A0 =A0 return NO_IRQ;
> + =A0 =A0 =A0 =A0 =A0 =A0 =A0 return 0;
> =A0 =A0 =A0 =A0}
>
> =A0 =A0 =A0 =A0return irq;
> @@ -719,7 +719,7 @@ static int __devinit iic_probe(struct of_device *ofde=
v,
> =A0 =A0 =A0 =A0init_waitqueue_head(&dev->wq);
>
> =A0 =A0 =A0 =A0dev->irq =3D iic_request_irq(ofdev, dev);
> - =A0 =A0 =A0 if (dev->irq =3D=3D NO_IRQ)
> + =A0 =A0 =A0 if (!dev->irq)
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0dev_warn(&ofdev->dev, "using polling mode\=
n");
>
> =A0 =A0 =A0 =A0/* Board specific settings */
> @@ -766,7 +766,7 @@ static int __devinit iic_probe(struct of_device *ofde=
v,
> =A0 =A0 =A0 =A0return 0;
>
> =A0error_cleanup:
> - =A0 =A0 =A0 if (dev->irq !=3D NO_IRQ) {
> + =A0 =A0 =A0 if (dev->irq) {
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0iic_interrupt_mode(dev, 0);
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0free_irq(dev->irq, dev);
> =A0 =A0 =A0 =A0}
> @@ -790,7 +790,7 @@ static int __devexit iic_remove(struct of_device *ofd=
ev)
>
> =A0 =A0 =A0 =A0i2c_del_adapter(&dev->adap);
>
> - =A0 =A0 =A0 if (dev->irq !=3D NO_IRQ) {
> + =A0 =A0 =A0 if (dev->irq) {
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0iic_interrupt_mode(dev, 0);
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0free_irq(dev->irq, dev);
> =A0 =A0 =A0 =A0}
> --
> 1.6.5
>
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev@lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/linuxppc-dev
>



--=20
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.

  reply	other threads:[~2010-02-16 16:01 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-22 21:11 i2c/janitoral: drop NO_IRQ from the subsystem Wolfram Sang
2009-10-22 21:11 ` [PATCH 1/3] i2c/mpc: drop NO_IRQ Wolfram Sang
2009-10-22 21:11   ` [PATCH 2/3] i2c/cpm: " Wolfram Sang
2009-10-22 21:11     ` [PATCH 3/3] i2c/ibm-iic: " Wolfram Sang
2010-02-16 16:01       ` Grant Likely [this message]
2010-02-16 15:59     ` [PATCH 2/3] i2c/cpm: " Grant Likely
2010-02-16 15:59   ` [PATCH 1/3] i2c/mpc: " Grant Likely

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=fa686aa41002160801k7a277567r50d71fb9d827203b@mail.gmail.com \
    --to=grant.likely@secretlab.ca \
    --cc=ben-linux@fluff.org \
    --cc=linux-i2c@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=smaclennan@pikatech.com \
    --cc=w.sang@pengutronix.de \
    /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).