aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-11-12 02:52:17 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2013-11-12 02:52:17 -0500
commit10d0c9705e80bbd3d587c5fad24599aabaca6688 (patch)
tree9456083a1b04b8d98da08d88e937cfeff80e2a7d /kernel
parent85b656cf1560e27a89354a23f2c10ba229d2f173 (diff)
parentc11eede69b6ad0ac44ebc1e021a8d2699c5f1f8f (diff)
Merge tag 'devicetree-for-3.13' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux
Pull devicetree updates from Rob Herring: "DeviceTree updates for 3.13. This is a bit larger pull request than usual for this cycle with lots of clean-up. - Cross arch clean-up and consolidation of early DT scanning code. - Clean-up and removal of arch prom.h headers. Makes arch specific prom.h optional on all but Sparc. - Addition of interrupts-extended property for devices connected to multiple interrupt controllers. - Refactoring of DT interrupt parsing code in preparation for deferred probe of interrupts. - ARM cpu and cpu topology bindings documentation. - Various DT vendor binding documentation updates" * tag 'devicetree-for-3.13' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux: (82 commits) powerpc: add missing explicit OF includes for ppc dt/irq: add empty of_irq_count for !OF_IRQ dt: disable self-tests for !OF_IRQ of: irq: Fix interrupt-map entry matching MIPS: Netlogic: replace early_init_devtree() call of: Add Panasonic Corporation vendor prefix of: Add Chunghwa Picture Tubes Ltd. vendor prefix of: Add AU Optronics Corporation vendor prefix of/irq: Fix potential buffer overflow of/irq: Fix bug in interrupt parsing refactor. of: set dma_mask to point to coherent_dma_mask of: add vendor prefix for PHYTEC Messtechnik GmbH DT: sort vendor-prefixes.txt of: Add vendor prefix for Cadence of: Add empty for_each_available_child_of_node() macro definition arm/versatile: Fix versatile irq specifications. of/irq: create interrupts-extended property microblaze/pci: Drop PowerPC-ism from irq parsing of/irq: Create of_irq_parse_and_map_pci() to consolidate arch code. of/irq: Use irq_of_parse_and_map() ...
Diffstat (limited to 'kernel')
-rw-r--r--kernel/irq/irqdomain.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/kernel/irq/irqdomain.c b/kernel/irq/irqdomain.c
index 706724e9835d..cf68bb36fe58 100644
--- a/kernel/irq/irqdomain.c
+++ b/kernel/irq/irqdomain.c
@@ -465,27 +465,26 @@ int irq_create_strict_mappings(struct irq_domain *domain, unsigned int irq_base,
465} 465}
466EXPORT_SYMBOL_GPL(irq_create_strict_mappings); 466EXPORT_SYMBOL_GPL(irq_create_strict_mappings);
467 467
468unsigned int irq_create_of_mapping(struct device_node *controller, 468unsigned int irq_create_of_mapping(struct of_phandle_args *irq_data)
469 const u32 *intspec, unsigned int intsize)
470{ 469{
471 struct irq_domain *domain; 470 struct irq_domain *domain;
472 irq_hw_number_t hwirq; 471 irq_hw_number_t hwirq;
473 unsigned int type = IRQ_TYPE_NONE; 472 unsigned int type = IRQ_TYPE_NONE;
474 unsigned int virq; 473 unsigned int virq;
475 474
476 domain = controller ? irq_find_host(controller) : irq_default_domain; 475 domain = irq_data->np ? irq_find_host(irq_data->np) : irq_default_domain;
477 if (!domain) { 476 if (!domain) {
478 pr_warn("no irq domain found for %s !\n", 477 pr_warn("no irq domain found for %s !\n",
479 of_node_full_name(controller)); 478 of_node_full_name(irq_data->np));
480 return 0; 479 return 0;
481 } 480 }
482 481
483 /* If domain has no translation, then we assume interrupt line */ 482 /* If domain has no translation, then we assume interrupt line */
484 if (domain->ops->xlate == NULL) 483 if (domain->ops->xlate == NULL)
485 hwirq = intspec[0]; 484 hwirq = irq_data->args[0];
486 else { 485 else {
487 if (domain->ops->xlate(domain, controller, intspec, intsize, 486 if (domain->ops->xlate(domain, irq_data->np, irq_data->args,
488 &hwirq, &type)) 487 irq_data->args_count, &hwirq, &type))
489 return 0; 488 return 0;
490 } 489 }
491 490