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

Re: [Xen-devel] [PATCH v5 3/8] xen/arm: introduce kinfo->guest_phandle_gic


  • To: Stefano Stabellini <sstabellini@xxxxxxxxxx>
  • From: Julien Grall <Julien.Grall@xxxxxxx>
  • Date: Wed, 25 Sep 2019 20:54:55 +0000
  • Accept-language: en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.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=7PSWjHywEiVSpvbfRn49YjIsVFoTokK0MZQ4dtXax+g=; b=fXu9V+bOsUQzpnWJ232/VeNx9FL0LLtTVf5MWVgtJUx96TQbgD1SOXLkmquplg4RTg76+L7/7AlvwSq9Hh4/hFZ6KRaHRNZ3pQOSGvjKAZd/m/QptuccrbtEXJoqJa7dXYuig9km3t/QeK/4z+idgn58lSUXBuTlVOwlGddqXJsymm0Rg0Q+wCfb8A2Qx2XaK5xWiQf/HYeBfiBpZRd3bGL0hvehZF501xDJE6/9V5lRf3FGWzXjNR9CkJ6gSd53YltZV6h9H2PITuxDB5M8w6qJF1fv11b2oRgoAdMXn/CRCiw0a36elFQCqL2NJE9fdivuP0iDHBac7R6QHKM84A==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=m8DrniWQK1HnjxiyrwNym4Jb6qqf1HdLuTTo2IvpR0DQ7AveETnWcYb2uvNOOt1/GyWEPJwBco1iYHyF0TvPD3TMcsn9GkGJC7+wcz1yMN/lCUIiH3XpuJDOJ3MIbjmJqSQ5ek5ovkJxdBDkTw3U9HxzE5EUvupSiSuXnrJ3qaJyBVsbN7mhWHWmJ2e+r8MJ92JIwQz3E+DmwGoLMP2kNQOgih19OKRxoLjd+j8y8gYvpPukyYUprtp8Soq+ElF7QPphcyNvg2MgjeiE5+T9B6ZKu1++eMwH9oNmBH82VnLn497n3I26AWY+HLvmubEoRgo5p8Hn+geDHOloa1w9dA==
  • Authentication-results: spf=temperror (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; lists.xen.org; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;lists.xen.org; dmarc=none action=none header.from=arm.com;
  • Authentication-results-original: spf=none (sender IP is ) smtp.mailfrom=Julien.Grall@xxxxxxx;
  • Cc: Stefano Stabellini <stefanos@xxxxxxxxxx>, "andrii_anisov@xxxxxxxx" <andrii_anisov@xxxxxxxx>, Achin Gupta <Achin.Gupta@xxxxxxx>, "xen-devel@xxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxx>, nd <nd@xxxxxxx>, "Volodymyr_Babchuk@xxxxxxxx" <Volodymyr_Babchuk@xxxxxxxx>
  • Delivery-date: Wed, 25 Sep 2019 20:55:39 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Nodisclaimer: True
  • Original-authentication-results: spf=none (sender IP is ) smtp.mailfrom=Julien.Grall@xxxxxxx;
  • Thread-index: AQHVc9H4VfH8CJdYOkWCA5Kgl4p5v6c831AA
  • Thread-topic: [PATCH v5 3/8] xen/arm: introduce kinfo->guest_phandle_gic

Hi,

On 25/09/2019 19:49, Stefano Stabellini wrote:
> Instead of always hard-coding the GIC phandle (GUEST_PHANDLE_GIC), store
> it in a variable under kinfo. This way it can be dynamically chosen per
> domain. Remove the fdt pointer argument to the make_*_domU_node
> functions and oass a struct kernel_info * instead. The fdt pointer can
> be accessed from kinfo->fdt. Remove the struct domain *d parameter to
> the make_*_domU_node functions because it becomes unused.
> 
> Initialize guest_phandle_gic to GUEST_PHANDLE_GIC at the beginning of
> prepare_dtb_domU. Later patches will change the value of
> guest_phandle_gic depending on user provided information.
> 
> Signed-off-by: Stefano Stabellini <stefanos@xxxxxxxxxx>
> 
> ---
> Changes in v5:
> - improve commit message
> Changes in v4:
> - new patch
> ---
>   xen/arch/arm/domain_build.c  | 36 +++++++++++++++++++++---------------
>   xen/include/asm-arm/kernel.h |  3 +++
>   2 files changed, 24 insertions(+), 15 deletions(-)
> 
> diff --git a/xen/arch/arm/domain_build.c b/xen/arch/arm/domain_build.c
> index 21985628f0..32f85cd959 100644
> --- a/xen/arch/arm/domain_build.c
> +++ b/xen/arch/arm/domain_build.c
> @@ -627,7 +627,8 @@ static int __init fdt_property_interrupts(const struct 
> kernel_info *kinfo,
>   {
>       int res;
>       uint32_t phandle = is_hardware_domain(kinfo->d) ?
> -                       dt_interrupt_controller->phandle : GUEST_PHANDLE_GIC;

Sorry, I only realized it now. But is there any reason to not set 
guest_phandle_gic for the hwdom also?

[...]

> diff --git a/xen/include/asm-arm/kernel.h b/xen/include/asm-arm/kernel.h
> index 33f3e72b11..760434369b 100644
> --- a/xen/include/asm-arm/kernel.h
> +++ b/xen/include/asm-arm/kernel.h
> @@ -36,6 +36,9 @@ struct kernel_info {
>       /* Enable pl011 emulation */
>       bool vpl011;
>   
> +    /* GIC phandle */
> +    uint32_t guest_phandle_gic;

This would also allow to drop the guest_ prefix.

> +
>       /* loader to use for this kernel */
>       void (*load)(struct kernel_info *info);
>       /* loader specific state */
> 

Cheers,

-- 
Julien Grall
_______________________________________________
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®.