Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1219700
| From | Yang Yingliang <yangyingliang@huawei.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [RFC PATCH v1 1/4] genirq: Introduce irq_settings_set_move_pcntxt() helper |
| Date | 2015-09-06 06:30 +0200 |
| Message-ID | <q5zKx-4RV-15@gated-at.bofh.it> (permalink) |
| References | <q5zKx-4RV-9@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
It's expected to use the helper when interrupt can be moved
in process.
Cc: Jiang Liu <jiang.liu@linux.intel.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Marc Zyngier <marc.zyngier@arm.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Will Deacon <will.deacon@arm.com>
Cc: Russell King - ARM Linux <linux@arm.linux.org.uk>
Cc: Hanjun Guo <hanjun.guo@linaro.org>
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
---
include/linux/irq.h | 1 +
kernel/irq/irqdesc.c | 12 ++++++++++++
kernel/irq/settings.h | 5 +++++
3 files changed, 18 insertions(+)
diff --git a/include/linux/irq.h b/include/linux/irq.h
index 6f8b340..f4ecfb9 100644
--- a/include/linux/irq.h
+++ b/include/linux/irq.h
@@ -514,6 +514,7 @@ static inline void irq_set_chip_and_handler(unsigned int irq, struct irq_chip *c
}
extern int irq_set_percpu_devid(unsigned int irq);
+extern int irq_set_move_pcntxt(unsigned int irq);
extern void
__irq_set_handler(unsigned int irq, irq_flow_handler_t handle, int is_chained,
diff --git a/kernel/irq/irqdesc.c b/kernel/irq/irqdesc.c
index 0a2a4b6..c036a1a 100644
--- a/kernel/irq/irqdesc.c
+++ b/kernel/irq/irqdesc.c
@@ -580,6 +580,18 @@ int irq_set_percpu_devid(unsigned int irq)
return 0;
}
+int irq_set_move_pcntxt(unsigned int irq)
+{
+ struct irq_desc *desc = irq_to_desc(irq);
+
+ if (!desc)
+ return -EINVAL;
+
+ irq_settings_set_move_pcntxt(desc);
+
+ return 0;
+}
+
void kstat_incr_irq_this_cpu(unsigned int irq)
{
kstat_incr_irqs_this_cpu(irq_to_desc(irq));
diff --git a/kernel/irq/settings.h b/kernel/irq/settings.h
index 3320b84..ea58bc2 100644
--- a/kernel/irq/settings.h
+++ b/kernel/irq/settings.h
@@ -135,6 +135,11 @@ static inline void irq_settings_set_noprobe(struct irq_desc *desc)
desc->status_use_accessors |= _IRQ_NOPROBE;
}
+static inline void irq_settings_set_move_pcntxt(struct irq_desc *desc)
+{
+ desc->status_use_accessors |= _IRQ_MOVE_PCNTXT;
+}
+
static inline bool irq_settings_can_move_pcntxt(struct irq_desc *desc)
{
return desc->status_use_accessors & _IRQ_MOVE_PCNTXT;
--
2.5.0
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[RFC PATCH v1 0/4] arm/arm64: fix a migrating irq bug when hotplug cpu Yang Yingliang <yangyingliang@huawei.com> - 2015-09-06 06:30 +0200
[RFC PATCH v1 1/4] genirq: Introduce irq_settings_set_move_pcntxt() helper Yang Yingliang <yangyingliang@huawei.com> - 2015-09-06 06:30 +0200
Re: [RFC PATCH v1 1/4] genirq: Introduce irq_settings_set_move_pcntxt() helper Thomas Gleixner <tglx@linutronix.de> - 2015-09-07 00:10 +0200
Re: [RFC PATCH v1 1/4] genirq: Introduce irq_settings_set_move_pcntxt() helper Yang Yingliang <yangyingliang@huawei.com> - 2015-09-07 04:00 +0200
[RFC PATCH v1 3/4] genirq: rename config GENERIC_PENDING_IRQ to GENERIC_IRQ_MIGRATION Yang Yingliang <yangyingliang@huawei.com> - 2015-09-06 06:30 +0200
Re: [RFC PATCH v1 0/4] arm/arm64: fix a migrating irq bug when hotplug cpu Jiang Liu <jiang.liu@linux.intel.com> - 2015-09-06 10:10 +0200
Re: [RFC PATCH v1 0/4] arm/arm64: fix a migrating irq bug when hotplug cpu Yang Yingliang <yangyingliang@huawei.com> - 2015-09-07 05:00 +0200
Re: [RFC PATCH v1 0/4] arm/arm64: fix a migrating irq bug when hotplug cpu Jiang Liu <jiang.liu@linux.intel.com> - 2015-09-07 04:00 +0200
csiph-web