[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] xen/arm: extend fdt_property_interrupts


  • To: Viktor Mitin <viktor.mitin.19@xxxxxxxxx>
  • From: Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
  • Date: Fri, 26 Jul 2019 11:57:16 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1;spf=pass smtp.mailfrom=epam.com;dmarc=pass action=none header.from=epam.com;dkim=pass header.d=epam.com;arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=YT8j+OKnia7KLKv/5ekfhitxRdw1WuvpTQvpWj/VSDU=; b=chlHiM3l/U0OfnI7JEXrhWkHBIe0sfboSqFkKfy0T8WpGN1ETOcMrTwTSqpOJ4Nk+0IMQ27Lhl9fzAo3Wbl9piBaaYgLHfbwZOb4j47TXHQzbTWzdt40Gf32I0HX8x969FN7FVYrkMFqJYgdLVioLnZXWGRm5q8qSa5tm3s39H8T23Xn28/OMcqRVk8+3hCvdoZgyGMQTWRrX/hzya2C43rOHMf9NeteUmyJbOc2PCpu5cDT2YaG82UCvFqadwwsU8z5uLM2LhE22rM1Di6usgq3XezHUrZ53m1dhc9T8nckTUudQE83zKC9j2oXutfazMPPPxCoQV20YJII8Qehtw==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=ausmyPgZs0Jrr6m8zX211SdWMh+o9zYiQWKTRIu9EcuF3I7I0FEnIEJmNNM//bP/OneIevYl+K0r+g4FCZ8+ep4UEun94XyVGZso1yu6L46nXbG0zQO1Yxep5kO/Q5L0EU+HZQkXDyUQSDkiJrZqxHtwgKsdCN8jLT9Lvp9G5mbMzAcL+01L/Arb4stCCOu4fqO/WBptnnVff+Rs68Sz+qfrnX+tgrMzotxolZK1vNGJ8mh3F3W9JL/4qyiJzuMLb3OCY1ig5gGhFrqxqHOr7zIHbN7nb311Fu9VP7IHD9WWsXGcze5IC3+SPban/pHqvN6lFKFny3LAxGYT8mjwIA==
  • Authentication-results: spf=none (sender IP is ) smtp.mailfrom=Volodymyr_Babchuk@xxxxxxxx;
  • Cc: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Julien Grall <julien.grall@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Viktor Mitin <Viktor_Mitin@xxxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>
  • Delivery-date: Fri, 26 Jul 2019 11:57:22 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Thread-index: AQHVQ5DIG4Wp10DIaUKStsgLLIvpgKbcy2UA
  • Thread-topic: [PATCH] xen/arm: extend fdt_property_interrupts

Hello Vikor,

Viktor Mitin writes:

> xen/arm: extend fdt_property_interrupts to deal with other
> domain than the hwdom

It is unclear what problem you are facing. Could you please elaborate
commit message?

Also, looks like your commit message is formatted incorrectly.

> Tested with aarch64 qemu dom0 and dom0less boot.
>
> Suggested-by: Julien Grall <julien.grall@xxxxxxx>
> Signed-off-by: Viktor Mitin <viktor_mitin@xxxxxxxx>
>
> ---
> See discussion in mail:
> [PATCH] xen/arm: merge make_timer_node and make_timer_domU_node
>
>
>  xen/arch/arm/domain_build.c | 22 +++++++++++++---------
>  1 file changed, 13 insertions(+), 9 deletions(-)
>
> diff --git a/xen/arch/arm/domain_build.c b/xen/arch/arm/domain_build.c
> index 4c8404155a..5f68603392 100644
> --- a/xen/arch/arm/domain_build.c
> +++ b/xen/arch/arm/domain_build.c
> @@ -621,17 +621,19 @@ static void __init set_interrupt(gic_interrupt_t 
> interrupt,
>   *  "interrupts": contains the list of interrupts
>   *  "interrupt-parent": link to the GIC
>   */
> -static int __init fdt_property_interrupts(void *fdt, gic_interrupt_t *intr,
> -                                          unsigned num_irq)
> +static int __init fdt_property_interrupts(const struct kernel_info *kinfo,
> +                            gic_interrupt_t *intr, unsigned num_irq)
Wrong indentation there.

>  {
>      int res;
> +    uint32_t phandle = is_hardware_domain(kinfo->d) ? 
There is extra space at EOL.

> +                       dt_interrupt_controller->phandle : GUEST_PHANDLE_GIC;
>  
> -    res = fdt_property(fdt, "interrupts", intr, sizeof (intr[0]) * num_irq);
> +    res = fdt_property(kinfo->fdt, "interrupts", 
There is extra space at EOL.


> +                       intr, sizeof (intr[0]) * num_irq);
>      if ( res )
>          return res;
>  
> -    res = fdt_property_cell(fdt, "interrupt-parent",
> -                            dt_interrupt_controller->phandle);
> +    res = fdt_property_cell(kinfo->fdt, "interrupt-parent", phandle);
>  
>      return res;
>  }
> @@ -733,7 +735,7 @@ static int __init make_hypervisor_node(struct domain *d,
>       *  TODO: Handle properly the cpumask;
>       */
>      set_interrupt(intr, d->arch.evtchn_irq, 0xf, DT_IRQ_TYPE_LEVEL_LOW);
> -    res = fdt_property_interrupts(fdt, &intr, 1);
> +    res = fdt_property_interrupts(kinfo, &intr, 1);
>      if ( res )
>          return res;
>  
> @@ -960,8 +962,10 @@ static int __init make_gic_node(const struct domain *d, 
> void *fdt,
>      return res;
>  }
>  
> -static int __init make_timer_node(const struct domain *d, void *fdt)
> +static int __init make_timer_node(const struct kernel_info *kinfo)
>  {
> +    void *fdt = kinfo->fdt;
> +
>      static const struct dt_device_match timer_ids[] __initconst =
>      {
>          DT_MATCH_COMPATIBLE("arm,armv7-timer"),
> @@ -1016,7 +1020,7 @@ static int __init make_timer_node(const struct domain 
> *d, void *fdt)
>      dt_dprintk("  Virt interrupt %u\n", irq);
>      set_interrupt(intrs[2], irq, 0xf, DT_IRQ_TYPE_LEVEL_LOW);
>  
> -    res = fdt_property_interrupts(fdt, intrs, 3);
> +    res = fdt_property_interrupts(kinfo, intrs, 3);
>      if ( res )
>          return res;
>  
> @@ -1377,7 +1381,7 @@ static int __init handle_node(struct domain *d, struct 
> kernel_info *kinfo,
>      if ( device_get_class(node) == DEVICE_GIC )
>          return make_gic_node(d, kinfo->fdt, node);
>      if ( dt_match_node(timer_matches, node) )
> -        return make_timer_node(d, kinfo->fdt);
> +        return make_timer_node(kinfo);
>  
>      /* Skip nodes used by Xen */
>      if ( dt_device_used_by(node) == DOMID_XEN )


-- 
Volodymyr Babchuk at EPAM
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.