aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarc Zyngier <marc.zyngier@arm.com>2015-10-13 07:51:45 -0400
committerThomas Gleixner <tglx@linutronix.de>2015-10-13 13:01:25 -0400
commite7a46c818564329f977f8fa157b5e9e1d0d83012 (patch)
tree26f67d01cbe4b584166127b00e9f845a81ddf43f
parentbe5436c83ac8921f33fe07323fab03c6644ce52e (diff)
irqdomain: Documentation updates
Update the IRQ domain documentation to reflect the changes made while divorcing the domain infrastructure from Device Tree. Signed-off-by: Marc Zyngier <marc.zyngier@arm.com> Tested-by: Hanjun Guo <hanjun.guo@linaro.org> Tested-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Cc: <linux-arm-kernel@lists.infradead.org> Cc: Tomasz Nowicki <tomasz.nowicki@linaro.org> Cc: Suravee Suthikulpanit <Suravee.Suthikulpanit@amd.com> Cc: Graeme Gregory <graeme@xora.org.uk> Cc: Jake Oshins <jakeo@microsoft.com> Cc: Jiang Liu <jiang.liu@linux.intel.com> Cc: Jason Cooper <jason@lakedaemon.net> Cc: Rafael J. Wysocki <rjw@rjwysocki.net> Link: http://lkml.kernel.org/r/1444737105-31573-18-git-send-email-marc.zyngier@arm.com Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
-rw-r--r--Documentation/IRQ-domain.txt8
-rw-r--r--include/linux/irqdomain.h23
2 files changed, 14 insertions, 17 deletions
diff --git a/Documentation/IRQ-domain.txt b/Documentation/IRQ-domain.txt
index 3a8e15cba816..8d990bde8693 100644
--- a/Documentation/IRQ-domain.txt
+++ b/Documentation/IRQ-domain.txt
@@ -32,9 +32,9 @@ top of the irq_alloc_desc*() API. An irq_domain to manage mapping is
32preferred over interrupt controller drivers open coding their own 32preferred over interrupt controller drivers open coding their own
33reverse mapping scheme. 33reverse mapping scheme.
34 34
35irq_domain also implements translation from Device Tree interrupt 35irq_domain also implements translation from an abstract irq_fwspec
36specifiers to hwirq numbers, and can be easily extended to support 36structure to hwirq numbers (Device Tree and ACPI GSI so far), and can
37other IRQ topology data sources. 37be easily extended to support other IRQ topology data sources.
38 38
39=== irq_domain usage === 39=== irq_domain usage ===
40An interrupt controller driver creates and registers an irq_domain by 40An interrupt controller driver creates and registers an irq_domain by
@@ -184,7 +184,7 @@ There are four major interfaces to use hierarchy irq_domain:
184 related resources associated with these interrupts. 184 related resources associated with these interrupts.
1853) irq_domain_activate_irq(): activate interrupt controller hardware to 1853) irq_domain_activate_irq(): activate interrupt controller hardware to
186 deliver the interrupt. 186 deliver the interrupt.
1873) irq_domain_deactivate_irq(): deactivate interrupt controller hardware 1874) irq_domain_deactivate_irq(): deactivate interrupt controller hardware
188 to stop delivering the interrupt. 188 to stop delivering the interrupt.
189 189
190Following changes are needed to support hierarchy irq_domain. 190Following changes are needed to support hierarchy irq_domain.
diff --git a/include/linux/irqdomain.h b/include/linux/irqdomain.h
index 2b3340ae915d..d5e5c5bef28c 100644
--- a/include/linux/irqdomain.h
+++ b/include/linux/irqdomain.h
@@ -5,9 +5,10 @@
5 * helpful for interrupt controllers to implement mapping between hardware 5 * helpful for interrupt controllers to implement mapping between hardware
6 * irq numbers and the Linux irq number space. 6 * irq numbers and the Linux irq number space.
7 * 7 *
8 * irq_domains also have a hook for translating device tree interrupt 8 * irq_domains also have hooks for translating device tree or other
9 * representation into a hardware irq number that can be mapped back to a 9 * firmware interrupt representations into a hardware irq number that
10 * Linux irq number without any extra platform support code. 10 * can be mapped back to a Linux irq number without any extra platform
11 * support code.
11 * 12 *
12 * Interrupt controller "domain" data structure. This could be defined as a 13 * Interrupt controller "domain" data structure. This could be defined as a
13 * irq domain controller. That is, it handles the mapping between hardware 14 * irq domain controller. That is, it handles the mapping between hardware
@@ -17,16 +18,12 @@
17 * model). It's the domain callbacks that are responsible for setting the 18 * model). It's the domain callbacks that are responsible for setting the
18 * irq_chip on a given irq_desc after it's been mapped. 19 * irq_chip on a given irq_desc after it's been mapped.
19 * 20 *
20 * The host code and data structures are agnostic to whether or not 21 * The host code and data structures use a fwnode_handle pointer to
21 * we use an open firmware device-tree. We do have references to struct 22 * identify the domain. In some cases, and in order to preserve source
22 * device_node in two places: in irq_find_host() to find the host matching 23 * code compatibility, this fwnode pointer is "upgraded" to a DT
23 * a given interrupt controller node, and of course as an argument to its 24 * device_node. For those firmware infrastructures that do not provide
24 * counterpart domain->ops->match() callback. However, those are treated as 25 * a unique identifier for an interrupt controller, the irq_domain
25 * generic pointers by the core and the fact that it's actually a device-node 26 * code offers a fwnode allocator.
26 * pointer is purely a convention between callers and implementation. This
27 * code could thus be used on other architectures by replacing those two
28 * by some sort of arch-specific void * "token" used to identify interrupt
29 * controllers.
30 */ 27 */
31 28
32#ifndef _LINUX_IRQDOMAIN_H 29#ifndef _LINUX_IRQDOMAIN_H