Message ID | 1510947208-17134-2-git-send-email-arvind.yadav.cs@gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 0DFCB6023A for <patchwork-linux-mediatek@patchwork.kernel.org>; Fri, 17 Nov 2017 19:49:32 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id F287228EDA for <patchwork-linux-mediatek@patchwork.kernel.org>; Fri, 17 Nov 2017 19:49:31 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E59482A8D1; Fri, 17 Nov 2017 19:49:31 +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=-4.2 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, DKIM_VALID, FREEMAIL_FROM, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.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 7DFF728EDA for <patchwork-linux-mediatek@patchwork.kernel.org>; Fri, 17 Nov 2017 19:49:31 +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:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:References: In-Reply-To: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:List-Owner; bh=Nv3g72Q7xwWwCflNRDcBY9Q3WeH/Tpt+7yJX7/1Sp8U=; b=AwUChxANqmOyk2+K8vTpkMBE5g 2t97tTzoda34KhTizPn+klkpmPWBUyY5xBq2c7kfH+y65xz2/7gr6QPAn6TqGQL2n+AJJHYTWqZWz kzvhJMdjJkZrT0F+Emq3o4uKRJxGvPyaB77XBJQVJR2t7JAI3FBDAXHj5srgsip9Ihv/IUjVh93Cp qwMTVQ+wn1NUqrnXfUzrFzojlolayxlARUb44u56vyD7A+XMNX5JF1elquntORwxEUmZxW4TIM9fC BELMNhUcpH3x+Gh27n9ZWw1GfmLsj9iKi4i3SUny5MnNro0rGIjrC0N7u9FJtOM5DK3QlzBkxn182 RmkKUkDQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1eFmdm-0000R5-CU; Fri, 17 Nov 2017 19:49:30 +0000 Received: from mail-pf0-x243.google.com ([2607:f8b0:400e:c00::243]) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1eFmOp-0001kW-PJ; Fri, 17 Nov 2017 19:34:12 +0000 Received: by mail-pf0-x243.google.com with SMTP id r62so2631064pfd.5; Fri, 17 Nov 2017 11:33:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=rKhbnRiZ1dSqfXgbUpKOcnTx4iXs3Vq3R1q94+a/jfc=; b=rvC+D8ZAPcbVIJ60iN6QKS0Cx5GO2Ds+nX9kYaAPG/uQN7yvIqBwAEnOY1wekpwV+Y JVA2jGE6gevqpjLGdPWp46GuyCDJNQvAHtTZhmo8Vsk60El0LJy7D8v8d2Xzm/rSlsaj vK0rXSRQw7dSrweEerb5Uxk0AAcHHcVxpsonOpLvVekRq68ymnEBvi2cxMx17K26BUXf Kit61EmOgXiCSEYRmgT6+MMdq5GOgYYjelx6eDqZh/jdCIXgAzLSNl8KZfo8+HVQLPs/ +9qSlS83BCjAs6RwRiByvMOjzCtcGlE6S4b+JF0Do9akFjY5mUAywlXBecykgW3GO0zI EChg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=rKhbnRiZ1dSqfXgbUpKOcnTx4iXs3Vq3R1q94+a/jfc=; b=RJwUCIJpNY2GARaycPy1K/mmp4Fr08NEOkwvJsRhUX+2oM9AS1XRcceaMS/Eo7y696 Eq7P7JrQqmc3x75aenJIt9Jyk3FLGSIKs7C12ZxzQONLjIABCbOCjIuauT48FsON9Mlq sdNHO0ucpJCABpw9XJ+M10Rh0PBu/dNoyd6IptjAjJ6vLkd2PbhBg3qXHRIvwk3Epw+E +X8sSmENGecXMj5l5sfO5SEPYFZCx2NmS+8VHMzfM3gKILyXocZheDkzt3uRw3V9ffgV Oc2uSrTon0SRObWm6MueRE0XfpSjiKnHura7cSxxvCHJZPIuQYd13Dlyv365juC52+We 5BLg== X-Gm-Message-State: AJaThX49SzYgpZrw0rMxm/Du7DgHSDk7QYPLK731tahEutlQu+ee0SCQ e1a2k/qI0KizjkoNqu+x02w= X-Google-Smtp-Source: AGs4zMb55Eh6DQoTqQ0nAa7NqLZibAE/WTb4wWc18Kd+NhLu1rcre00G9eYOvLPUiUw//RnOaYa3eQ== X-Received: by 10.101.78.138 with SMTP id b10mr6013279pgs.36.1510947222880; Fri, 17 Nov 2017 11:33:42 -0800 (PST) Received: from localhost.localdomain ([103.16.68.147]) by smtp.gmail.com with ESMTPSA id u77sm9066799pfd.168.2017.11.17.11.33.40 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 17 Nov 2017 11:33:42 -0800 (PST) From: Arvind Yadav <arvind.yadav.cs@gmail.com> To: lgirdwood@gmail.com, broonie@kernel.org, perex@perex.cz, tiwai@suse.com, matthias.bgg@gmail.com Subject: [PATCH 1/5] ASoC: ep93xx-ac97: Fix platform_get_irq's error checking Date: Sat, 18 Nov 2017 01:03:24 +0530 Message-Id: <1510947208-17134-2-git-send-email-arvind.yadav.cs@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1510947208-17134-1-git-send-email-arvind.yadav.cs@gmail.com> References: <1510947208-17134-1-git-send-email-arvind.yadav.cs@gmail.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20171117_113404_365013_C922DF31 X-CRM114-Status: GOOD ( 10.03 ) X-BeenThere: linux-mediatek@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: <linux-mediatek.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-mediatek>, <mailto:linux-mediatek-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-mediatek/> List-Post: <mailto:linux-mediatek@lists.infradead.org> List-Help: <mailto:linux-mediatek-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-mediatek>, <mailto:linux-mediatek-request@lists.infradead.org?subject=subscribe> Cc: linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "Linux-mediatek" <linux-mediatek-bounces@lists.infradead.org> Errors-To: linux-mediatek-bounces+patchwork-linux-mediatek=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP |
diff --git a/sound/soc/cirrus/ep93xx-ac97.c b/sound/soc/cirrus/ep93xx-ac97.c index bbf7a92..d66c561 100644 --- a/sound/soc/cirrus/ep93xx-ac97.c +++ b/sound/soc/cirrus/ep93xx-ac97.c @@ -378,8 +378,8 @@ static int ep93xx_ac97_probe(struct platform_device *pdev) return PTR_ERR(info->regs); irq = platform_get_irq(pdev, 0); - if (!irq) - return -ENODEV; + if (irq < 0) + return irq; ret = devm_request_irq(&pdev->dev, irq, ep93xx_ac97_interrupt, IRQF_TRIGGER_HIGH, pdev->name, info);
The platform_get_irq() function returns negative if an error occurs. zero or positive number on success. platform_get_irq() error checking for zero is not correct. Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com> --- sound/soc/cirrus/ep93xx-ac97.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)