From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753289AbdKWTLQ (ORCPT ); Thu, 23 Nov 2017 14:11:16 -0500 Received: from terminus.zytor.com ([65.50.211.136]:52829 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753229AbdKWTLP (ORCPT ); Thu, 23 Nov 2017 14:11:15 -0500 Date: Thu, 23 Nov 2017 11:09:59 -0800 From: tip-bot for Colin Ian King Message-ID: Cc: tglx@linutronix.de, jason@lakedaemon.net, mingo@kernel.org, colin.king@canonical.com, hpa@zytor.com, marc.zyngier@arm.com, linux-kernel@vger.kernel.org Reply-To: hpa@zytor.com, jason@lakedaemon.net, mingo@kernel.org, tglx@linutronix.de, colin.king@canonical.com, linux-kernel@vger.kernel.org, marc.zyngier@arm.com In-Reply-To: <20171117183553.2739-1-colin.king@canonical.com> References: <20171117183553.2739-1-colin.king@canonical.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:irq/urgent] irqchip/qcom: Fix u32 comparison with value less than zero Git-Commit-ID: e9990d70e8a063a7b894c5cbb99f630a0f41200d X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: e9990d70e8a063a7b894c5cbb99f630a0f41200d Gitweb: https://git.kernel.org/tip/e9990d70e8a063a7b894c5cbb99f630a0f41200d Author: Colin Ian King AuthorDate: Fri, 17 Nov 2017 18:35:53 +0000 Committer: Thomas Gleixner CommitDate: Thu, 23 Nov 2017 20:03:58 +0100 irqchip/qcom: Fix u32 comparison with value less than zero The comparison of u32 nregs being less than zero is never true since nregs is unsigned. Fix this by making nregs a signed integer. Fixes: f20cc9b00c7b ("irqchip/qcom: Add IRQ combiner driver") Signed-off-by: Colin Ian King Signed-off-by: Thomas Gleixner Cc: Marc Zyngier Cc: kernel-janitors@vger.kernel.org Cc: Jason Cooper Link: https://lkml.kernel.org/r/20171117183553.2739-1-colin.king@canonical.com --- drivers/irqchip/qcom-irq-combiner.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/irqchip/qcom-irq-combiner.c b/drivers/irqchip/qcom-irq-combiner.c index 6aa3ea4..f312659 100644 --- a/drivers/irqchip/qcom-irq-combiner.c +++ b/drivers/irqchip/qcom-irq-combiner.c @@ -238,7 +238,7 @@ static int __init combiner_probe(struct platform_device *pdev) { struct combiner *combiner; size_t alloc_sz; - u32 nregs; + int nregs; int err; nregs = count_registers(pdev);