mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] irqchip/bcm2836: Enable SKIP_SET_WAKE and MASK_ON_SUSPEND
@ 2024-12-02 11:54 Stefan Wahren
  2024-12-02 16:56 ` Florian Fainelli
  2024-12-03 11:20 ` [tip: irq/urgent] " tip-bot2 for Stefan Wahren
  0 siblings, 2 replies; 3+ messages in thread
From: Stefan Wahren @ 2024-12-02 11:54 UTC (permalink / raw)
  To: Florian Fainelli, Ray Jui, Scott Branden, Thomas Gleixner
  Cc: Lukas Wunner, Peter Robinson, Ivan T . Ivanov, linux-arm-kernel,
	bcm-kernel-feedback-list, linux-kernel, Stefan Wahren

The BCM2836 interrupt controller doesn't provide any facility to
configure the wakeup sources. That's the reason why the driver lacks
the irq_set_wake() callback for the interrupt chip.

Enable the flags IRQCHIP_SKIP_SET_WAKE and IRQCHIP_MASK_ON_SUSPEND so
the interrupt suspend logic can handle the chip correctly.

This was inspired by the patch series "irqchip/irq-bcm283x update
for BCM7211" by Florian Fainelli.

Link: https://lore.kernel.org/lkml/20191001224842.9382-1-f.fainelli@gmail.com/
Signed-off-by: Stefan Wahren <wahrenst@gmx.net>
---
 drivers/irqchip/irq-bcm2836.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/irqchip/irq-bcm2836.c b/drivers/irqchip/irq-bcm2836.c
index e5f1059b989f..e366257684b5 100644
--- a/drivers/irqchip/irq-bcm2836.c
+++ b/drivers/irqchip/irq-bcm2836.c
@@ -58,6 +58,7 @@ static struct irq_chip bcm2836_arm_irqchip_timer = {
 	.name		= "bcm2836-timer",
 	.irq_mask	= bcm2836_arm_irqchip_mask_timer_irq,
 	.irq_unmask	= bcm2836_arm_irqchip_unmask_timer_irq,
+	.flags		= IRQCHIP_MASK_ON_SUSPEND | IRQCHIP_SKIP_SET_WAKE,
 };

 static void bcm2836_arm_irqchip_mask_pmu_irq(struct irq_data *d)
@@ -74,6 +75,7 @@ static struct irq_chip bcm2836_arm_irqchip_pmu = {
 	.name		= "bcm2836-pmu",
 	.irq_mask	= bcm2836_arm_irqchip_mask_pmu_irq,
 	.irq_unmask	= bcm2836_arm_irqchip_unmask_pmu_irq,
+	.flags		= IRQCHIP_MASK_ON_SUSPEND | IRQCHIP_SKIP_SET_WAKE,
 };

 static void bcm2836_arm_irqchip_mask_gpu_irq(struct irq_data *d)
@@ -88,6 +90,7 @@ static struct irq_chip bcm2836_arm_irqchip_gpu = {
 	.name		= "bcm2836-gpu",
 	.irq_mask	= bcm2836_arm_irqchip_mask_gpu_irq,
 	.irq_unmask	= bcm2836_arm_irqchip_unmask_gpu_irq,
+	.flags		= IRQCHIP_MASK_ON_SUSPEND | IRQCHIP_SKIP_SET_WAKE,
 };

 static void bcm2836_arm_irqchip_dummy_op(struct irq_data *d)
--
2.34.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] irqchip/bcm2836: Enable SKIP_SET_WAKE and MASK_ON_SUSPEND
  2024-12-02 11:54 [PATCH] irqchip/bcm2836: Enable SKIP_SET_WAKE and MASK_ON_SUSPEND Stefan Wahren
@ 2024-12-02 16:56 ` Florian Fainelli
  2024-12-03 11:20 ` [tip: irq/urgent] " tip-bot2 for Stefan Wahren
  1 sibling, 0 replies; 3+ messages in thread
From: Florian Fainelli @ 2024-12-02 16:56 UTC (permalink / raw)
  To: Stefan Wahren, Ray Jui, Scott Branden, Thomas Gleixner
  Cc: Lukas Wunner, Peter Robinson, Ivan T . Ivanov, linux-arm-kernel,
	bcm-kernel-feedback-list, linux-kernel

On 12/2/24 03:54, Stefan Wahren wrote:
> The BCM2836 interrupt controller doesn't provide any facility to
> configure the wakeup sources. That's the reason why the driver lacks
> the irq_set_wake() callback for the interrupt chip.
> 
> Enable the flags IRQCHIP_SKIP_SET_WAKE and IRQCHIP_MASK_ON_SUSPEND so
> the interrupt suspend logic can handle the chip correctly.
> 
> This was inspired by the patch series "irqchip/irq-bcm283x update
> for BCM7211" by Florian Fainelli.
> 
> Link: https://lore.kernel.org/lkml/20191001224842.9382-1-f.fainelli@gmail.com/
> Signed-off-by: Stefan Wahren <wahrenst@gmx.net>

Acked-by: Florian Fainelli <florian.fainelli@broadcom.com>
-- 
Florian

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [tip: irq/urgent] irqchip/bcm2836: Enable SKIP_SET_WAKE and MASK_ON_SUSPEND
  2024-12-02 11:54 [PATCH] irqchip/bcm2836: Enable SKIP_SET_WAKE and MASK_ON_SUSPEND Stefan Wahren
  2024-12-02 16:56 ` Florian Fainelli
@ 2024-12-03 11:20 ` tip-bot2 for Stefan Wahren
  1 sibling, 0 replies; 3+ messages in thread
From: tip-bot2 for Stefan Wahren @ 2024-12-03 11:20 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: Stefan Wahren, Thomas Gleixner, Florian Fainelli, x86, linux-kernel, maz

The following commit has been merged into the irq/urgent branch of tip:

Commit-ID:     ee3878b84cc27ee62cdf78d2842830f4dcdab117
Gitweb:        https://git.kernel.org/tip/ee3878b84cc27ee62cdf78d2842830f4dcdab117
Author:        Stefan Wahren <wahrenst@gmx.net>
AuthorDate:    Mon, 02 Dec 2024 12:54:37 +01:00
Committer:     Thomas Gleixner <tglx@linutronix.de>
CommitterDate: Tue, 03 Dec 2024 12:15:42 +01:00

irqchip/bcm2836: Enable SKIP_SET_WAKE and MASK_ON_SUSPEND

The BCM2836 interrupt controller doesn't provide any facility to configure
the wakeup sources. That's the reason why the driver lacks the
irq_set_wake() callback for the interrupt chip.

Enable the flags IRQCHIP_SKIP_SET_WAKE and IRQCHIP_MASK_ON_SUSPEND so the
interrupt suspend logic can handle the chip correctly equivalently to the
corresponding bcm2835 change (9a58480e5e53 ("irqchip/bcm2835: Enable
SKIP_SET_WAKE and MASK_ON_SUSPEND").

Signed-off-by: Stefan Wahren <wahrenst@gmx.net>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Acked-by: Florian Fainelli <florian.fainelli@broadcom.com>
Link: https://lore.kernel.org/all/20241202115437.33552-1-wahrenst@gmx.net
---
 drivers/irqchip/irq-bcm2836.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/irqchip/irq-bcm2836.c b/drivers/irqchip/irq-bcm2836.c
index e5f1059..e366257 100644
--- a/drivers/irqchip/irq-bcm2836.c
+++ b/drivers/irqchip/irq-bcm2836.c
@@ -58,6 +58,7 @@ static struct irq_chip bcm2836_arm_irqchip_timer = {
 	.name		= "bcm2836-timer",
 	.irq_mask	= bcm2836_arm_irqchip_mask_timer_irq,
 	.irq_unmask	= bcm2836_arm_irqchip_unmask_timer_irq,
+	.flags		= IRQCHIP_MASK_ON_SUSPEND | IRQCHIP_SKIP_SET_WAKE,
 };
 
 static void bcm2836_arm_irqchip_mask_pmu_irq(struct irq_data *d)
@@ -74,6 +75,7 @@ static struct irq_chip bcm2836_arm_irqchip_pmu = {
 	.name		= "bcm2836-pmu",
 	.irq_mask	= bcm2836_arm_irqchip_mask_pmu_irq,
 	.irq_unmask	= bcm2836_arm_irqchip_unmask_pmu_irq,
+	.flags		= IRQCHIP_MASK_ON_SUSPEND | IRQCHIP_SKIP_SET_WAKE,
 };
 
 static void bcm2836_arm_irqchip_mask_gpu_irq(struct irq_data *d)
@@ -88,6 +90,7 @@ static struct irq_chip bcm2836_arm_irqchip_gpu = {
 	.name		= "bcm2836-gpu",
 	.irq_mask	= bcm2836_arm_irqchip_mask_gpu_irq,
 	.irq_unmask	= bcm2836_arm_irqchip_unmask_gpu_irq,
+	.flags		= IRQCHIP_MASK_ON_SUSPEND | IRQCHIP_SKIP_SET_WAKE,
 };
 
 static void bcm2836_arm_irqchip_dummy_op(struct irq_data *d)

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-12-03 11:20 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-12-02 11:54 [PATCH] irqchip/bcm2836: Enable SKIP_SET_WAKE and MASK_ON_SUSPEND Stefan Wahren
2024-12-02 16:56 ` Florian Fainelli
2024-12-03 11:20 ` [tip: irq/urgent] " tip-bot2 for Stefan Wahren

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®