diff options
author | Thierry Reding | 2013-09-18 15:24:44 +0200 |
---|---|---|
committer | Grant Likely | 2013-10-24 11:50:35 +0100 |
commit | f7578496a671a96e501f16a5104893275e32c33a (patch) | |
tree | f1bc2db4847acdea2bb4c777782b29c35c084ae2 /arch/powerpc/sysdev/fsl_gtm.c | |
parent | 3da5278727a895d49a601f67fd49dffa0b80f9a5 (diff) |
of/irq: Use irq_of_parse_and_map()
Replace some instances of of_irq_map_one()/irq_create_of_mapping() and
of_irq_to_resource() by the simpler equivalent irq_of_parse_and_map().
Signed-off-by: Thierry Reding <treding@nvidia.com>
Acked-by: Rob Herring <rob.herring@calxeda.com>
[grant.likely: resolved conflicts with core code renames]
Signed-off-by: Grant Likely <grant.likely@linaro.org>
Diffstat (limited to 'arch/powerpc/sysdev/fsl_gtm.c')
-rw-r--r-- | arch/powerpc/sysdev/fsl_gtm.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/arch/powerpc/sysdev/fsl_gtm.c b/arch/powerpc/sysdev/fsl_gtm.c index 0eb871cc3437..dd0d5be6cd1f 100644 --- a/arch/powerpc/sysdev/fsl_gtm.c +++ b/arch/powerpc/sysdev/fsl_gtm.c @@ -401,16 +401,15 @@ static int __init fsl_gtm_init(void) gtm->clock = *clock; for (i = 0; i < ARRAY_SIZE(gtm->timers); i++) { - int ret; - struct resource irq; + unsigned int irq; - ret = of_irq_to_resource(np, i, &irq); - if (ret == NO_IRQ) { + irq = irq_of_parse_and_map(np, i); + if (irq == NO_IRQ) { pr_err("%s: not enough interrupts specified\n", np->full_name); goto err; } - gtm->timers[i].irq = irq.start; + gtm->timers[i].irq = irq; gtm->timers[i].gtm = gtm; } |