summaryrefslogtreecommitdiff
path: root/include/linux/irq_sim.h
diff options
context:
space:
mode:
authorBartosz Golaszewski <brgl@bgdev.pl>2018-11-09 18:21:32 +0100
committerMarc Zyngier <marc.zyngier@arm.com>2018-12-13 09:35:31 +0000
commit06459901d55ee2f690b8e1fe084fb03061d617cf (patch)
tree80ca6e836924930684dfaa8ee308267ad71e5e5e /include/linux/irq_sim.h
parent81b1e6e6a8590a19257e37a1633bec098d499c57 (diff)
irq/irq_sim: Store multiple interrupt offsets in a bitmap
Two threads can try to fire the irq_sim with different offsets and will end up fighting for the irq_work asignment. Thomas Gleixner suggested a solution based on a bitfield where we set a bit for every offset associated with an interrupt that should be fired and then iterate over all set bits in the interrupt handler. This is a slightly modified solution using a bitmap so that we don't impose a limit on the number of interrupts one can allocate with irq_sim. Suggested-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Diffstat (limited to 'include/linux/irq_sim.h')
-rw-r--r--include/linux/irq_sim.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/irq_sim.h b/include/linux/irq_sim.h
index 630a57e55db6..4500d453a63e 100644
--- a/include/linux/irq_sim.h
+++ b/include/linux/irq_sim.h
@@ -16,7 +16,7 @@
struct irq_sim_work_ctx {
struct irq_work work;
- int irq;
+ unsigned long *pending;
};
struct irq_sim_irq_ctx {