From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 03307188A38; Tue, 10 Sep 2024 10:28:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1725964103; cv=none; b=W+KCsVb5mNr/7rT+bfni6y82TvwK/P34yr115ZFsYb6K6fw3cVwtftwdR/YOfFZIa0B8Lw5e7YgnDDENIv2GdDYWk56lB/KHEZbh6fgtNRSq540wJ5C6P7fK6EEr7ctMDLtLfSKnGKq51RE5PXKX9SAMteE4CgdHYoVlekG5pNU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1725964103; c=relaxed/simple; bh=rTj5cmewmxIL8O8WEvlHkFoSU58g1A3xnIdpJu/KBTM=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=NQN1HAVu1Z56VwTM4CSgx8ph+RsLiKHnRzj6PGhc7laphGeNqa9nxQ1fGKPDFZL9FAsSQRqK4+tq12KlcdsNzJQQ0XRNvC8iUcaUieK7oyIISMBD2skHCnHDFOOVGMgZD1iUBerYg5PvSTWWuW7isOCI6Ayrdu9wDivu95r3VRw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=u/+rj1aZ; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="u/+rj1aZ" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 80238C4CECD; Tue, 10 Sep 2024 10:28:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1725964102; bh=rTj5cmewmxIL8O8WEvlHkFoSU58g1A3xnIdpJu/KBTM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=u/+rj1aZ2ch4AkcWrXogTDq+enhGZSOwyPOaxIAfQn7lBkDv0gudoWaxEeL/7l4mV O+eJ5E/xtlFZc+bRqNqOwlhmHkBn+tcuUJgsNG4Um99ayoDxYUtPEn0KpghZDh5Rpx /paDzVh3aRhYxVuF8QT4cqMNYTNvrdZtvqlRa2tk= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, =?UTF-8?q?Pali=20Roh=C3=A1r?= , =?UTF-8?q?Marek=20Beh=C3=BAn?= , Thomas Gleixner , Andrew Lunn , Sasha Levin Subject: [PATCH 6.6 069/269] irqchip/armada-370-xp: Do not allow mapping IRQ 0 and 1 Date: Tue, 10 Sep 2024 11:30:56 +0200 Message-ID: <20240910092610.657996836@linuxfoundation.org> X-Mailer: git-send-email 2.46.0 In-Reply-To: <20240910092608.225137854@linuxfoundation.org> References: <20240910092608.225137854@linuxfoundation.org> User-Agent: quilt/0.67 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 6.6-stable review patch. If anyone has any objections, please let me know. ------------------ From: Pali Rohár [ Upstream commit 3cef738208e5c3cb7084e208caf9bbf684f24feb ] IRQs 0 (IPI) and 1 (MSI) are handled internally by this driver, generic_handle_domain_irq() is never called for these IRQs. Disallow mapping these IRQs. [ Marek: changed commit message ] Signed-off-by: Pali Rohár Signed-off-by: Marek Behún Signed-off-by: Thomas Gleixner Reviewed-by: Andrew Lunn Signed-off-by: Sasha Levin --- drivers/irqchip/irq-armada-370-xp.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/irqchip/irq-armada-370-xp.c b/drivers/irqchip/irq-armada-370-xp.c index a55528469278..91a42e2d7a13 100644 --- a/drivers/irqchip/irq-armada-370-xp.c +++ b/drivers/irqchip/irq-armada-370-xp.c @@ -566,6 +566,10 @@ static struct irq_chip armada_370_xp_irq_chip = { static int armada_370_xp_mpic_irq_map(struct irq_domain *h, unsigned int virq, irq_hw_number_t hw) { + /* IRQs 0 and 1 cannot be mapped, they are handled internally */ + if (hw <= 1) + return -EINVAL; + armada_370_xp_irq_mask(irq_get_irq_data(virq)); if (!is_percpu_irq(hw)) writel(hw, per_cpu_int_base + -- 2.43.0