From patchwork Fri Jan 7 14:26:01 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Genoud X-Patchwork-Id: 464071 Received: from lists.sourceforge.net (lists.sourceforge.net [216.34.181.88]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p07ERG7e028998 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 7 Jan 2011 14:27:37 GMT Received: from localhost ([127.0.0.1] helo=sfs-ml-4.v29.ch3.sourceforge.com) by sfs-ml-4.v29.ch3.sourceforge.com with esmtp (Exim 4.69) (envelope-from ) id 1PbDGw-0004fk-PV; Fri, 07 Jan 2011 14:26:30 +0000 Received: from sog-mx-3.v43.ch3.sourceforge.com ([172.29.43.193] helo=mx.sourceforge.net) by sfs-ml-4.v29.ch3.sourceforge.com with esmtp (Exim 4.69) (envelope-from ) id 1PbDGv-0004fe-NP for spi-devel-general@lists.sourceforge.net; Fri, 07 Jan 2011 14:26:29 +0000 Received-SPF: pass (sog-mx-3.v43.ch3.sourceforge.com: domain of gmail.com designates 74.125.82.53 as permitted sender) client-ip=74.125.82.53; envelope-from=richard.genoud@gmail.com; helo=mail-ww0-f53.google.com; Received: from mail-ww0-f53.google.com ([74.125.82.53]) by sog-mx-3.v43.ch3.sourceforge.com with esmtp (Exim 4.72) id 1PbDGu-0001Ka-N8 for spi-devel-general@lists.sourceforge.net; Fri, 07 Jan 2011 14:26:29 +0000 Received: by wwi18 with SMTP id 18so17599287wwi.10 for ; Fri, 07 Jan 2011 06:26:19 -0800 (PST) Received: by 10.216.179.207 with SMTP id h57mr814683wem.20.1294410379515; Fri, 07 Jan 2011 06:26:19 -0800 (PST) Received: from localhost.localdomain ([213.144.218.64]) by mx.google.com with ESMTPS id o33sm12441798wej.13.2011.01.07.06.26.17 (version=TLSv1/SSLv3 cipher=RC4-MD5); Fri, 07 Jan 2011 06:26:18 -0800 (PST) From: Richard Genoud To: Grant Likely , spi-devel-general@lists.sourceforge.net Subject: [PATCH] spi_imx.c: correct the test on platform_get_irq() return value Date: Fri, 7 Jan 2011 15:26:01 +0100 Message-Id: <1294410361-9092-1-git-send-email-richard.genoud@gmail.com> X-Mailer: git-send-email 1.7.1 In-Reply-To: References: X-Spam-Score: -1.6 (-) X-Spam-Report: Spam Filtering performed by mx.sourceforge.net. See http://spamassassin.org/tag/ for more details. -1.5 SPF_CHECK_PASS SPF reports sender host as permitted sender for sender-domain 0.0 FREEMAIL_FROM Sender email is freemail (richard.genoud[at]gmail.com) -0.0 SPF_PASS SPF: sender matches SPF record -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature X-Headers-End: 1PbDGu-0001Ka-N8 Cc: Richard Genoud , David Brownell , linux-kernel@vger.kernel.org, =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= X-BeenThere: spi-devel-general@lists.sourceforge.net X-Mailman-Version: 2.1.9 Precedence: list List-Id: Linux SPI core/device drivers discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: spi-devel-general-bounces@lists.sourceforge.net X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Fri, 07 Jan 2011 14:27:38 +0000 (UTC) diff --git a/drivers/spi/spi_imx.c b/drivers/spi/spi_imx.c index 55a38e2..793ae99 100644 --- a/drivers/spi/spi_imx.c +++ b/drivers/spi/spi_imx.c @@ -847,7 +847,7 @@ static int __devinit spi_imx_probe(struct platform_device *pdev) } spi_imx->irq = platform_get_irq(pdev, 0); - if (spi_imx->irq <= 0) { + if (spi_imx->irq < 0) { ret = -EINVAL; goto out_iounmap; }