[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20080507154641.83a09a06.akpm@linux-foundation.org>
Date: Wed, 7 May 2008 15:46:41 -0700
From: Andrew Morton <akpm@...ux-foundation.org>
To: Roel Kluin <12o3l@...cali.nl>
Cc: galak@...nel.crashing.org, linuxppc-dev@...abs.org,
linux-kernel@...r.kernel.org, dbrownell@...rs.sourceforge.net,
spi-devel-general@...ts.sourceforge.net
Subject: Re: [PATCH 1/2] spi_mpc83xx: test below 0 on unsigned irq in
mpc83xx_spi_probe()
On Wed, 23 Apr 2008 22:55:16 +0200
Roel Kluin <12o3l@...cali.nl> wrote:
> mpc83xx_spi->irq is unsigned, so the test fails
>
> Signed-off-by: Roel Kluin <12o3l@...cali.nl>
> ---
> diff --git a/drivers/spi/spi_mpc83xx.c b/drivers/spi/spi_mpc83xx.c
> index be15a62..033fd51 100644
> --- a/drivers/spi/spi_mpc83xx.c
> +++ b/drivers/spi/spi_mpc83xx.c
> @@ -454,12 +454,12 @@ static int __init mpc83xx_spi_probe(struct platform_device *dev)
> goto put_master;
> }
>
> - mpc83xx_spi->irq = platform_get_irq(dev, 0);
> -
> - if (mpc83xx_spi->irq < 0) {
> - ret = -ENXIO;
> + ret = platform_get_irq(dev, 0);
> + if (ret < 0)
> goto unmap_io;
> - }
> +
> + mpc83xx_spi->irq = ret;
> + ret = 0;
>
> /* Register for SPI Interrupt */
> ret = request_irq(mpc83xx_spi->irq, mpc83xx_spi_irq,
>
In the recently-merged spi_mpc83xx-much-improved-driver.patch, mpc83xx_spi.irq
has type `int' so I don't think we need this fix any more.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists