summaryrefslogtreecommitdiffstats
path: root/include/linux/irqdomain.h
diff options
context:
space:
mode:
authorMasahiro Yamada2017-10-05 03:44:54 +0200
committerMarc Zyngier2017-10-19 11:30:03 +0200
commitf1d783585486c7c612f277c2a6f0c9bb5a67e463 (patch)
tree87895cecab4db87b5db128cd91826f8421e440d1 /include/linux/irqdomain.h
parentirqchip: Add Kconfig menu (diff)
downloadkernel-qcow2-linux-f1d783585486c7c612f277c2a6f0c9bb5a67e463.tar.gz
kernel-qcow2-linux-f1d783585486c7c612f277c2a6f0c9bb5a67e463.tar.xz
kernel-qcow2-linux-f1d783585486c7c612f277c2a6f0c9bb5a67e463.zip
irqdomain: Move revmap_trees_mutex to struct irq_domain
The revmap_trees_mutex protects domain->revmap_tree. There is no need to make it global because it is allowed to modify revmap_tree of two different domains concurrently. Having said that, this would not be a actual bottleneck because the interrupt map/unmap does not occur quite often. Rather, the motivation is to tidy up the code from a data structure point of view. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Diffstat (limited to 'include/linux/irqdomain.h')
-rw-r--r--include/linux/irqdomain.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/irqdomain.h b/include/linux/irqdomain.h
index 7d0c6c144708..df162f7a4aad 100644
--- a/include/linux/irqdomain.h
+++ b/include/linux/irqdomain.h
@@ -32,6 +32,7 @@
#include <linux/types.h>
#include <linux/irqhandler.h>
#include <linux/of.h>
+#include <linux/mutex.h>
#include <linux/radix-tree.h>
struct device_node;
@@ -176,6 +177,7 @@ struct irq_domain {
unsigned int revmap_direct_max_irq;
unsigned int revmap_size;
struct radix_tree_root revmap_tree;
+ struct mutex revmap_tree_mutex;
unsigned int linear_revmap[];
};