|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v2 01/16] xen/arm: timer: replace timer_dt_irq by timer_get_irq
On Thu, 2014-04-03 at 21:41 +0100, Julien Grall wrote:
> The function is nearly only used to retrieve the IRQ number.
>
> There is one place where the IRQ type is used (in domain_build.c) but
> as the timer IRQ is virtualised for guest we might not have the same property
> (e.g active-low level sensitive interrupt).
Is this statement impacted at all by Stefano switching things to use the
LR.HW bit?
>
> Replace timer_dt_irq by timer_get_irq which will return the IRQ number.
>
> Signed-off-by: Julien Grall <julien.grall@xxxxxxxxxx>
> @@ -647,17 +647,20 @@ static int make_timer_node(const struct domain *d, void
> *fdt,
> if ( res )
> return res;
>
> - irq = timer_dt_irq(TIMER_PHYS_SECURE_PPI);
> - DPRINT(" Secure interrupt %u\n", irq->irq);
> - set_interrupt_ppi(intrs[0], irq->irq, 0xf, irq->type);
> + /* The timer IRQ is emulated by Xen. It always exposes an active-low
> + * level-sensitive interrupt */
>
> - irq = timer_dt_irq(TIMER_PHYS_NONSECURE_PPI);
> - DPRINT(" Non secure interrupt %u\n", irq->irq);
> - set_interrupt_ppi(intrs[1], irq->irq, 0xf, irq->type);
> + irq = timer_get_irq(TIMER_PHYS_SECURE_PPI);
> + DPRINT(" Secure interrupt %u\n", irq);
> + set_interrupt_ppi(intrs[0], irq, 0xf, DT_IRQ_TYPE_LEVEL_LOW);
>
> - irq = timer_dt_irq(TIMER_VIRT_PPI);
> - DPRINT(" Virt interrupt %u\n", irq->irq);
> - set_interrupt_ppi(intrs[2], irq->irq, 0xf, irq->type);
> + irq = timer_get_irq(TIMER_PHYS_NONSECURE_PPI);
> + DPRINT(" Non secure interrupt %u\n", irq);
> + set_interrupt_ppi(intrs[1], irq, 0xf, DT_IRQ_TYPE_LEVEL_LOW);
> +
> + irq = timer_get_irq(TIMER_VIRT_PPI);
> + DPRINT(" Virt interrupt %u\n", irq);
> + set_interrupt_ppi(intrs[2], irq, 0xf, DT_IRQ_TYPE_LEVEL_LOW);
>
> res = fdt_property_interrupts(fdt, intrs, 3);
> if ( res )
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |