All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mailbox: apple: Keep IRQs active in suspend
@ 2022-05-02  8:33 ` Hector Martin
  0 siblings, 0 replies; 2+ messages in thread
From: Hector Martin @ 2022-05-02  8:33 UTC (permalink / raw)
  To: Jassi Brar
  Cc: Alyssa Rosenzweig, Sven Peter, linux-arm-kernel, linux-kernel,
	Hector Martin

Some consumers (notably SMC) need to be wakeup sources for s2idle,
so the IRQs need to stay enabled during suspend. We expect
consumers to properly suspend coprocessors such that no IRQs would
be triggered where not necessary, so this can be done unconditionally.

Signed-off-by: Hector Martin <marcan@marcan.st>
---
 drivers/mailbox/apple-mailbox.c | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/drivers/mailbox/apple-mailbox.c b/drivers/mailbox/apple-mailbox.c
index e0c2bf7c6338..ce54f72d8676 100644
--- a/drivers/mailbox/apple-mailbox.c
+++ b/drivers/mailbox/apple-mailbox.c
@@ -369,8 +369,8 @@ static int apple_mbox_probe(struct platform_device *pdev)
 
 	ret = devm_request_threaded_irq(dev, mbox->irq_recv_not_empty, NULL,
 					apple_mbox_recv_irq,
-					IRQF_NO_AUTOEN | IRQF_ONESHOT, irqname,
-					mbox);
+					IRQF_NO_AUTOEN | IRQF_ONESHOT | IRQF_NO_SUSPEND,
+					irqname, mbox);
 	if (ret)
 		return ret;
 
@@ -378,9 +378,8 @@ static int apple_mbox_probe(struct platform_device *pdev)
 	if (!irqname)
 		return -ENOMEM;
 
-	ret = devm_request_irq(dev, mbox->irq_send_empty,
-			       apple_mbox_send_empty_irq, IRQF_NO_AUTOEN,
-			       irqname, mbox);
+	ret = devm_request_irq(dev, mbox->irq_send_empty, apple_mbox_send_empty_irq,
+			       IRQF_NO_AUTOEN | IRQF_NO_SUSPEND, irqname, mbox);
 	if (ret)
 		return ret;
 
-- 
2.35.1


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

* [PATCH] mailbox: apple: Keep IRQs active in suspend
@ 2022-05-02  8:33 ` Hector Martin
  0 siblings, 0 replies; 2+ messages in thread
From: Hector Martin @ 2022-05-02  8:33 UTC (permalink / raw)
  To: Jassi Brar
  Cc: Alyssa Rosenzweig, Sven Peter, linux-arm-kernel, linux-kernel,
	Hector Martin

Some consumers (notably SMC) need to be wakeup sources for s2idle,
so the IRQs need to stay enabled during suspend. We expect
consumers to properly suspend coprocessors such that no IRQs would
be triggered where not necessary, so this can be done unconditionally.

Signed-off-by: Hector Martin <marcan@marcan.st>
---
 drivers/mailbox/apple-mailbox.c | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/drivers/mailbox/apple-mailbox.c b/drivers/mailbox/apple-mailbox.c
index e0c2bf7c6338..ce54f72d8676 100644
--- a/drivers/mailbox/apple-mailbox.c
+++ b/drivers/mailbox/apple-mailbox.c
@@ -369,8 +369,8 @@ static int apple_mbox_probe(struct platform_device *pdev)
 
 	ret = devm_request_threaded_irq(dev, mbox->irq_recv_not_empty, NULL,
 					apple_mbox_recv_irq,
-					IRQF_NO_AUTOEN | IRQF_ONESHOT, irqname,
-					mbox);
+					IRQF_NO_AUTOEN | IRQF_ONESHOT | IRQF_NO_SUSPEND,
+					irqname, mbox);
 	if (ret)
 		return ret;
 
@@ -378,9 +378,8 @@ static int apple_mbox_probe(struct platform_device *pdev)
 	if (!irqname)
 		return -ENOMEM;
 
-	ret = devm_request_irq(dev, mbox->irq_send_empty,
-			       apple_mbox_send_empty_irq, IRQF_NO_AUTOEN,
-			       irqname, mbox);
+	ret = devm_request_irq(dev, mbox->irq_send_empty, apple_mbox_send_empty_irq,
+			       IRQF_NO_AUTOEN | IRQF_NO_SUSPEND, irqname, mbox);
 	if (ret)
 		return ret;
 
-- 
2.35.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

end of thread, other threads:[~2022-05-02  8:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-02  8:33 [PATCH] mailbox: apple: Keep IRQs active in suspend Hector Martin
2022-05-02  8:33 ` Hector Martin

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.