From patchwork Tue Jul 2 11:42:40 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Marek_Beh=C3=BAn?= X-Patchwork-Id: 13719486 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 27829C3064D for ; Tue, 2 Jul 2024 11:44:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc: To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=xp4QDctYbXDBsbyLqnutrmXsE/LmUKtecDpSut8zwfk=; b=okoIHvfaQCxb/gnNmKUgx4MVSn zvCJJgAclBN7NyhisEdp25Q4XJYlPGjTAHHaarrcaOgEWOMezkTHa0PqvHbkwOnB83K6NaHMS0+zD 0ZJsHQ2QLBTaCdpV/zU/2I61aM6tmtnvUGEtY+ht5QoxBFVy3aKRT5EAtl8jodtKRljzBYdQytsDi jLmDDAOD/am8d/Yx/FiUnagLtnP/lQmg1yWkghJkJLXPJQ1FcvjstFMBsKXRgbwP0v2qMITLGuOwS XYSet8/Vs+32Vj4/ZsRIryOucb1tfhYDbOLI7McbRYxtNavduvOel9xbsTW0BRQOby22BqLQSPyyK L/f/G6dw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sObwA-00000006WqN-44ia; Tue, 02 Jul 2024 11:44:42 +0000 Received: from sin.source.kernel.org ([2604:1380:40e1:4800::1]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sObv1-00000006W7h-1PYV for linux-arm-kernel@lists.infradead.org; Tue, 02 Jul 2024 11:43:32 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by sin.source.kernel.org (Postfix) with ESMTP id BAA2ECE1D56; Tue, 2 Jul 2024 11:43:29 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DFBF9C2BD10; Tue, 2 Jul 2024 11:43:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1719920609; bh=DLCEkL8UyWedUpt6/VZAPlMX55GRHEMyQrbp7gGRMN0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=FoKzXr8RLSSmI6o1B0l25Ph8aDARYef99enKPXQA4Tf0774XT/G1JhRzQTU/VENdl 8rzVsXYxpQEAoLYTylM3RGkkMZRxEMZ+7XG2IppIhaPUtwli288KLgHZnLM2/zUkfM OVZ2H+vC0tP6ESdVScFuFeuvw4K3+mFCuNDTaPDjr4PikdHDt5VgnaP1l6I4xCyTrQ DR6RiLGgCpLSLorhJPpKBSf/50WZc1qebhSsQIBdyIShv7hZVRy6EHRqoSMXG9Vt/B BtIEFWaJ/jevwh1EjjA9PH69p6mDsD+JMATLYTlmsKm/H3w3z75oX6f7s2H718xBEB YBUZqoySL5tmw== From: =?utf-8?q?Marek_Beh=C3=BAn?= To: Andrew Lunn , Gregory Clement , Sebastian Hesselbarth , Thomas Gleixner , linux-arm-kernel@lists.infradead.org, arm@kernel.org, Andy Shevchenko , Hans de Goede , =?utf-8?q?Ilpo_J=C3=A4rvinen?= Cc: =?utf-8?q?Marek_Beh=C3=BAn?= Subject: [PATCH v2 08/30] irqchip/armada-370-xp: Simplify is_percpu_irq() code Date: Tue, 2 Jul 2024 13:42:40 +0200 Message-ID: <20240702114302.22475-9-kabel@kernel.org> X-Mailer: git-send-email 2.44.2 In-Reply-To: <20240702114302.22475-1-kabel@kernel.org> References: <20240702114302.22475-1-kabel@kernel.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240702_044331_582731_C88A82BC X-CRM114-Status: GOOD ( 10.08 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Simplify the code in the is_percpu_irq() function. Instead of if (condition) return true; return false; simply return condition. Signed-off-by: Marek Behún Reviewed-by: Andrew Lunn Reviewed-by: Ilpo Järvinen --- drivers/irqchip/irq-armada-370-xp.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/drivers/irqchip/irq-armada-370-xp.c b/drivers/irqchip/irq-armada-370-xp.c index b9631cc25c0b..cfd6dc803150 100644 --- a/drivers/irqchip/irq-armada-370-xp.c +++ b/drivers/irqchip/irq-armada-370-xp.c @@ -201,10 +201,7 @@ static inline unsigned int msi_doorbell_end(void) static inline bool is_percpu_irq(irq_hw_number_t irq) { - if (irq <= MPIC_MAX_PER_CPU_IRQS) - return true; - - return false; + return irq <= MPIC_MAX_PER_CPU_IRQS; } /*