All of lore.kernel.org
 help / color / mirror / Atom feed
From: marc.zyngier@arm.com (Marc Zyngier)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/5] genirq: Add irqchip_set_wake_parent
Date: Sat,  6 Dec 2014 13:46:12 +0000	[thread overview]
Message-ID: <1417873576-10463-2-git-send-email-marc.zyngier@arm.com> (raw)
In-Reply-To: <1417873576-10463-1-git-send-email-marc.zyngier@arm.com>

This proves to be usefull with stacked domains.

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
---
 include/linux/irq.h |  1 +
 kernel/irq/chip.c   | 16 ++++++++++++++++
 2 files changed, 17 insertions(+)

diff --git a/include/linux/irq.h b/include/linux/irq.h
index 8badf34..7de85b8 100644
--- a/include/linux/irq.h
+++ b/include/linux/irq.h
@@ -459,6 +459,7 @@ extern void irq_chip_eoi_parent(struct irq_data *data);
 extern int irq_chip_set_affinity_parent(struct irq_data *data,
 					const struct cpumask *dest,
 					bool force);
+extern int irq_chip_set_wake_parent(struct irq_data *data, unsigned int on);
 #endif
 
 static inline void irq_chip_write_msi_msg(struct irq_data *data,
diff --git a/kernel/irq/chip.c b/kernel/irq/chip.c
index 6f1c7a5..96c190b 100644
--- a/kernel/irq/chip.c
+++ b/kernel/irq/chip.c
@@ -948,6 +948,22 @@ int irq_chip_retrigger_hierarchy(struct irq_data *data)
 
 	return -ENOSYS;
 }
+
+/**
+ * irq_chip_set_wake - Set/reset wake-up on the parent interrupt
+ * @data:	Pointer to interrupt specific data
+ * @on:		Whether to set or reset the wake-up capability of this irq
+ *
+ * Conditional, as the underlying parent chip might not implement it.
+ */
+int irq_chip_set_wake_parent(struct irq_data *data, unsigned int on)
+{
+	data = data->parent_data;
+	if (data->chip->irq_set_wake)
+		return data->chip->irq_set_wake(data, on);
+
+	return -ENOSYS;
+}
 #endif
 
 /**
-- 
2.1.3

  reply	other threads:[~2014-12-06 13:46 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-06 13:46 [PATCH 0/5] irqchip: kill the GIC routable domain Marc Zyngier
2014-12-06 13:46 ` Marc Zyngier [this message]
2014-12-06 15:34   ` [PATCH 1/5] genirq: Add irqchip_set_wake_parent Stefan Agner
2014-12-08 11:18     ` Marc Zyngier
2014-12-06 13:46 ` [PATCH 2/5] irqchip: crossbar: convert dra7 crossbar to stacked domains Marc Zyngier
2014-12-06 13:46 ` [PATCH 3/5] DT: update ti,irq-crossbar binding Marc Zyngier
2014-12-06 13:46 ` [PATCH 4/5] irqchip: GIC: get rid of routable domain Marc Zyngier
2014-12-06 13:46 ` [PATCH 5/5] DT: arm,gic: kill arm,routable-irqs Marc Zyngier
2014-12-07 17:16 ` [PATCH 0/5] irqchip: kill the GIC routable domain Nishanth Menon
2014-12-07 17:16   ` Nishanth Menon
2014-12-07 18:03   ` Nishanth Menon
2014-12-07 18:03     ` Nishanth Menon
2014-12-08  9:10     ` Marc Zyngier
2014-12-08  9:10       ` Marc Zyngier
2014-12-08 22:41       ` Nishanth Menon
2014-12-08 22:41         ` Nishanth Menon
2014-12-09  9:53         ` Marc Zyngier
2014-12-09  9:53           ` Marc Zyngier
2014-12-09 18:17           ` Nishanth Menon
2014-12-09 18:17             ` Nishanth Menon
2014-12-09 18:40             ` Marc Zyngier
2014-12-09 18:40               ` Marc Zyngier
2014-12-10 18:21               ` Nishanth Menon
2014-12-10 18:21                 ` Nishanth Menon
2015-01-07 16:14                 ` Nishanth Menon
2015-01-07 16:14                   ` Nishanth Menon
2015-01-07 16:09               ` Jason Cooper
2015-01-07 16:09                 ` Jason Cooper

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1417873576-10463-2-git-send-email-marc.zyngier@arm.com \
    --to=marc.zyngier@arm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.