Skip to content

Commit e13b99f

Browse files
afzalmamKAGA-KOKO
authored andcommitted
c6x: Replace setup_irq() by request_irq()
request_irq() is preferred over setup_irq(). Invocations of setup_irq() occur after memory allocators are ready. setup_irq() was required in older kernels as the memory allocator was not available during early boot. Hence replace setup_irq() by request_irq(). Signed-off-by: afzal mohammed <[email protected]> Signed-off-by: Thomas Gleixner <[email protected]> Link: https://lkml.kernel.org/r/56e991e920ce5806771fab892574cba89a3d413f.1585320721.git.afzal.mohd.ma@gmail.com
1 parent 82c849e commit e13b99f

File tree

1 file changed

+3
-8
lines changed

1 file changed

+3
-8
lines changed

arch/c6x/platforms/timer64.c

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -165,13 +165,6 @@ static irqreturn_t timer_interrupt(int irq, void *dev_id)
165165
return IRQ_HANDLED;
166166
}
167167

168-
static struct irqaction timer_iact = {
169-
.name = "timer",
170-
.flags = IRQF_TIMER,
171-
.handler = timer_interrupt,
172-
.dev_id = &t64_clockevent_device,
173-
};
174-
175168
void __init timer64_init(void)
176169
{
177170
struct clock_event_device *cd = &t64_clockevent_device;
@@ -238,7 +231,9 @@ void __init timer64_init(void)
238231
cd->cpumask = cpumask_of(smp_processor_id());
239232

240233
clockevents_register_device(cd);
241-
setup_irq(cd->irq, &timer_iact);
234+
if (request_irq(cd->irq, timer_interrupt, IRQF_TIMER, "timer",
235+
&t64_clockevent_device))
236+
pr_err("Failed to request irq %d (timer)\n", cd->irq);
242237

243238
out:
244239
of_node_put(np);

0 commit comments

Comments
 (0)