From patchwork Fri May 31 09:18:15 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien DESSENNE X-Patchwork-Id: 10969791 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id BF8E014C0 for ; Fri, 31 May 2019 09:18:51 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AE59A28C6D for ; Fri, 31 May 2019 09:18:51 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9EFC828B20; Fri, 31 May 2019 09:18:51 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 99E1828B20 for ; Fri, 31 May 2019 09:18:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:To :From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=XVr32VOY5LanF/JS2KXbGEtwzjfWzxaXfjRamd1MKZY=; b=ScRBElYl15aPUa vxDaBDTo/xwEgotTI0llkSyF+0RYeTBuWxbu74R5Ty1B1IXMNvP+M1YpX9PZZyd0T4Gemr2jQ3Yq9 ve+OnQbUKcjFsYluhc7Omfvfx15b1m37D0SsJfSzd8xCwvjPHpwsBuW27RBpOFYNdDsyT+QnZ1WIg XFTRKm7Ogy/0YUym4QrBQ1dU4d1Sa/4JKn+WNlFT0ry806XeKPayYJ5zDkwe639UuXp0UDwycVREK O8O9Lu52zyL7FkOuPVSWPDV9nfzqcrJ7GYb9+TaLu9ARGtqZWMq2Ux51LGtJQMjCT8mqmUQaAx4YK Y9AJdLzcUDoVcWh4fwBw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1hWdgU-0002im-5b; Fri, 31 May 2019 09:18:46 +0000 Received: from mx08-00178001.pphosted.com ([91.207.212.93] helo=mx07-00178001.pphosted.com) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1hWdgQ-0002iD-Ur for linux-arm-kernel@lists.infradead.org; Fri, 31 May 2019 09:18:44 +0000 Received: from pps.filterd (m0046661.ppops.net [127.0.0.1]) by mx08-00178001.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x4V97nqd018680; Fri, 31 May 2019 11:18:31 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=st.com; h=from : to : cc : subject : date : message-id : mime-version : content-type; s=STMicroelectronics; bh=rz5GP3p1X72UWRAxSNm3DrASQ+E4MaPT9C6RQHCpmq0=; b=rvbek+Dq2ug8amgrE3UQvq+FhSycEB2bRCB8U9vs4DAkatMPUGr6eKLpSgp9rDmrw/v2 ZXOf+CtoinI3KWqDKUQ+hpqVdz2b5sjivjjN50b+hboktcNsV8bg8uT9j786apCqsC5K 2wMmOra0jHuYTEBGK2XNUFDUSvqLZUrxNcqyyXQGWG3mRac7D0Fpq8+m+66m8+UHMr9P SQvviH4fe/eIEjxCN9/myCtgtQ7JFMBRW3kDogi8oXZz+yeZRLBOcI+Sbdxu3mcOR73Z shBWFBRB/yXCf2Oe9s991wLAH5hM8FSrmb/OgCKBu+QwwX96q5GWWJCh8PmhmvN4pDk3 vA== Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx08-00178001.pphosted.com with ESMTP id 2spvkhk772-1 (version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT); Fri, 31 May 2019 11:18:31 +0200 Received: from zeta.dmz-eu.st.com (zeta.dmz-eu.st.com [164.129.230.9]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id D1D5C31; Fri, 31 May 2019 09:18:28 +0000 (GMT) Received: from Webmail-eu.st.com (Safex1hubcas23.st.com [10.75.90.46]) by zeta.dmz-eu.st.com (STMicroelectronics) with ESMTP id A14272476; Fri, 31 May 2019 09:18:28 +0000 (GMT) Received: from SAFEX1HUBCAS21.st.com (10.75.90.45) by SAFEX1HUBCAS23.st.com (10.75.90.46) with Microsoft SMTP Server (TLS) id 14.3.439.0; Fri, 31 May 2019 11:18:28 +0200 Received: from localhost (10.201.23.25) by Webmail-ga.st.com (10.75.90.48) with Microsoft SMTP Server (TLS) id 14.3.439.0; Fri, 31 May 2019 11:18:28 +0200 From: Fabien Dessenne To: Hugues Fruchet , Mauro Carvalho Chehab , Maxime Coquelin , "Alexandre Torgue" , Pavel Machek , Hans Verkuil , , , , Subject: [PATCH] media: stm32-dcmi: fix irq = 0 case Date: Fri, 31 May 2019 11:18:15 +0200 Message-ID: <1559294295-20573-1-git-send-email-fabien.dessenne@st.com> X-Mailer: git-send-email 2.7.4 MIME-Version: 1.0 X-Originating-IP: [10.201.23.25] X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:, , definitions=2019-05-31_05:, , signatures=0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190531_021843_275997_EDEDFBA5 X-CRM114-Status: GOOD ( 13.56 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Sasha Levin , Greg Kroah-Hartman , Fabien Dessenne 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 Manage the irq = 0 case, where we shall return an error. Fixes: b5b5a27bee58 ("media: stm32-dcmi: return appropriate error codes during probe") Signed-off-by: Fabien Dessenne Acked-by: Pavel Machek Reported-by: Pavel Machek --- drivers/media/platform/stm32/stm32-dcmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/platform/stm32/stm32-dcmi.c b/drivers/media/platform/stm32/stm32-dcmi.c index b9dad0a..d855e9c 100644 --- a/drivers/media/platform/stm32/stm32-dcmi.c +++ b/drivers/media/platform/stm32/stm32-dcmi.c @@ -1702,7 +1702,7 @@ static int dcmi_probe(struct platform_device *pdev) if (irq <= 0) { if (irq != -EPROBE_DEFER) dev_err(&pdev->dev, "Could not get irq\n"); - return irq; + return irq ? irq : -ENXIO; } dcmi->res = platform_get_resource(pdev, IORESOURCE_MEM, 0);