From patchwork Thu Jun 12 07:32:01 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Boris BREZILLON X-Patchwork-Id: 4339851 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 51FFD9F357 for ; Thu, 12 Jun 2014 07:34:27 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 93F8F2022A for ; Thu, 12 Jun 2014 07:34:26 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 7FD30201D5 for ; Thu, 12 Jun 2014 07:34:25 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1WuzUs-0006Wo-OP; Thu, 12 Jun 2014 07:32:30 +0000 Received: from top.free-electrons.com ([176.31.233.9] helo=mail.free-electrons.com) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1WuzUo-0006M2-F7 for linux-arm-kernel@lists.infradead.org; Thu, 12 Jun 2014 07:32:26 +0000 Received: by mail.free-electrons.com (Postfix, from userid 106) id 89FF17E9; Thu, 12 Jun 2014 09:32:06 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from localhost.localdomain (col31-4-88-188-83-94.fbx.proxad.net [88.188.83.94]) by mail.free-electrons.com (Postfix) with ESMTPSA id DFA6C60F; Thu, 12 Jun 2014 09:32:05 +0200 (CEST) From: Boris BREZILLON To: kbuild test robot , Wolfram Sang Subject: [PATCH] i2c: sun6-p2wi: fix erroneous error message Date: Thu, 12 Jun 2014 09:32:01 +0200 Message-Id: <1402558321-18981-1-git-send-email-boris.brezillon@free-electrons.com> X-Mailer: git-send-email 1.8.3.2 In-Reply-To: <53994cdd.dj2lZ0lrPyPuIr9Z%fengguang.wu@intel.com> References: <53994cdd.dj2lZ0lrPyPuIr9Z%fengguang.wu@intel.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140612_003226_650812_D567D1FC X-CRM114-Status: GOOD ( 11.50 ) X-Spam-Score: 0.3 (/) Cc: Boris BREZILLON , linux-i2c@vger.kernel.org, Shuge , Maxime Ripard , kevin@allwinnertech.com, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The variable containing the return value of platform_get_irq is irq not ret, this means the error code printed in the error message will be false. Signed-off-by: Boris BREZILLON Reported-by: Fengguang Wu --- Hello Wolfram, This patch fixes a bug reported by Fengguang's build robot. I know you've already applied my series to your for-next tree, but let me know if you want me to squash this patch into the P2WI series and send a v8. Best Regards, Boris drivers/i2c/busses/i2c-sun6i-p2wi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/i2c/busses/i2c-sun6i-p2wi.c b/drivers/i2c/busses/i2c-sun6i-p2wi.c index f1d3e6f..5d2d678 100644 --- a/drivers/i2c/busses/i2c-sun6i-p2wi.c +++ b/drivers/i2c/busses/i2c-sun6i-p2wi.c @@ -240,7 +240,7 @@ static int p2wi_probe(struct platform_device *pdev) snprintf(p2wi->adapter.name, sizeof(p2wi->adapter.name), pdev->name); irq = platform_get_irq(pdev, 0); if (irq < 0) { - dev_err(dev, "failed to retrieve irq: %d\n", ret); + dev_err(dev, "failed to retrieve irq: %d\n", irq); return irq; }