[PATCH 2/3] i2c/cpm: drop NO_IRQ

Grant Likely grant.likely at secretlab.ca
Wed Feb 17 02:59:54 EST 2010


On Thu, Oct 22, 2009 at 2:11 PM, Wolfram Sang <w.sang at 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 at pengutronix.de>
> Cc: Jochen Friedrich <jochen at scram.de>
> Cc: Ben Dooks <ben-linux at fluff.org>

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

> ---
>  drivers/i2c/busses/i2c-cpm.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/i2c/busses/i2c-cpm.c b/drivers/i2c/busses/i2c-cpm.c
> index 9c2e100..16948db 100644
> --- a/drivers/i2c/busses/i2c-cpm.c
> +++ b/drivers/i2c/busses/i2c-cpm.c
> @@ -441,7 +441,7 @@ static int __devinit cpm_i2c_setup(struct cpm_i2c *cpm)
>        init_waitqueue_head(&cpm->i2c_wait);
>
>        cpm->irq = of_irq_to_resource(ofdev->node, 0, NULL);
> -       if (cpm->irq == NO_IRQ)
> +       if (!cpm->irq)
>                return -EINVAL;
>
>        /* Install interrupt handler. */
> --
> 1.6.5
>
> _______________________________________________
> Linuxppc-dev mailing list
> Linuxppc-dev at lists.ozlabs.org
> https://lists.ozlabs.org/listinfo/linuxppc-dev
>



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


More information about the Linuxppc-dev mailing list