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

Re: [PATCH v5 4/6] xen/cpupool: Create different cpupools at boot time


  • To: Julien Grall <julien@xxxxxxx>
  • From: Luca Fancellu <Luca.Fancellu@xxxxxxx>
  • Date: Thu, 7 Apr 2022 09:52:17 +0000
  • Accept-language: en-GB, 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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Hq3oahg5QT6EUzbvsX5jWcZmPTbDZIxo39RyUZA4e1Y=; b=GGPiqn555VGSI8dkSuevSzGQbbo/yvdFOf7VFpcydzwMOkWQNFrfuTvUft45Yk0N7YLkNfjpk9yJEl2SY0pmTzZA8D8zJ6HWOYWns1ADLfvqoane84MlMRnOCBcSvQyaaIB/ShUZuPHF1Wm8vX7IPMncxX3q1sxbBRx8SGlIW9yWZQblISAeEHTrZDPOhgPv1vavODAuNyhy3KjOuegxU9NEDIAfdaEb5qNV/i8+xOLZEu/qjwvfe+rJuZb+8nQrr2DPprt04vBb+EP8O7e1eeZFFYNvOuZRDAzVNy8DlhGgP3sUIQ0GYxKP5vb0ilnnfXj2aZr3u9Z4Ef1+gCxJsg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=b2vA5uJ97YUpcBVV6/sOldQ+1/rkO5QXw/Yw4WlnTkPVchtJcrnkFvADkq+QBWKDyNXcpW74qZ6ouQ57ycsYFefzoRqac8HpaTkgP3A1vBDZiMuhGS+EKgo5AFe/8sR3u2h9FARiK7gxDVZS8MBwHOxCesNt6LBIujbiPqqgdjwFJR0qWX3sDznE8jx/GyQE7qCIGAOmnWUJkRnlykdP8LLiMcQMkd0aXyTlMpH0/x/epJ6+5KDeETyOD/ZwBOFiLv5XouWtnWRoNMsAcVsvwNjc0KXFo2SvUfbWAF7aR1sSiSQ/bdqlpPYb15uvX64cc2Dt0EOljHsI7sP+9T1Upg==
  • Authentication-results-original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Cc: Xen developer discussion <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Bertrand Marquis <Bertrand.Marquis@xxxxxxx>, Wei Chen <Wei.Chen@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Wei Liu <wl@xxxxxxx>, Juergen Gross <jgross@xxxxxxxx>, Dario Faggioli <dfaggioli@xxxxxxxx>
  • Delivery-date: Thu, 07 Apr 2022 09:53:14 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Nodisclaimer: true
  • Original-authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
  • Thread-index: AQHYSMtZp02WrBHGjUK6R54AwN8yA6zkKdCAgAAO7AA=
  • Thread-topic: [PATCH v5 4/6] xen/cpupool: Create different cpupools at boot time


> On 7 Apr 2022, at 09:58, Julien Grall <julien@xxxxxxx> wrote:
> 
> Hi Luca,
> 
> On 05/04/2022 09:57, Luca Fancellu wrote:
>> Introduce a way to create different cpupools at boot time, this is
>> particularly useful on ARM big.LITTLE system where there might be the
>> need to have different cpupools for each type of core, but also
>> systems using NUMA can have different cpu pools for each node.
>> The feature on arm relies on a specification of the cpupools from the
>> device tree to build pools and assign cpus to them.
> 
> How will this work for ACPI? Note that I am not suggesting to add suport 
> right now. However, we probably want to clarify that this is not yet 
> supported.

Ok I will add a note saying ACPI is not supported in v6

> 
> [...]
> 
>> diff --git a/docs/misc/arm/device-tree/cpupools.txt 
>> b/docs/misc/arm/device-tree/cpupools.txt
>> new file mode 100644
>> index 000000000000..5dac2b1384e0
>> --- /dev/null
>> +++ b/docs/misc/arm/device-tree/cpupools.txt
>> @@ -0,0 +1,136 @@
>> +Boot time cpupools
>> +==================
>> +
>> +When BOOT_TIME_CPUPOOLS is enabled in the Xen configuration, it is possible 
>> to
>> +create cpupools during boot phase by specifying them in the device tree.
> 
> How about ACPI?

Same as above

> 
>> +
>> +Cpupools specification nodes shall be direct childs of /chosen node.
>> +Each cpupool node contains the following properties:
>> +
>> +- compatible (mandatory)
>> +
>> +    Must always include the compatiblity string: "xen,cpupool".
>> +
>> +- cpupool-cpus (mandatory)
>> +
>> +    Must be a list of device tree phandle to nodes describing cpus (e.g. 
>> having
>> +    device_type = "cpu"), it can't be empty.
>> +
>> +- cpupool-sched (optional)
>> +
>> +    Must be a string having the name of a Xen scheduler. Check the 
>> sched=<...>
>> +    boot argument for allowed values.
> 
> I would clarify what would be the scheduler if cpupool-sched is not specified.
> 
> Also, I would give a pointer to xen-command-line.pandoc so it is easier to 
> know where 'sched' is described.

Good point, I think the info got missed through the series, I’ll add and put 
the link.

> 
> [...]
> 
>> +void __init btcpupools_dtb_parse(void)
>> +{
>> +    const struct dt_device_node *chosen, *node;
>> +
>> +    chosen = dt_find_node_by_path("/chosen");
>> +    if ( !chosen )
>> +        return;
> Aside when using ACPI, the chosen node should always be there. So I think we 
> should throw/print an error if chosen is not present.

When you say error, do you mean like a panic or just a printk XENLOG_ERR and 
return?

> 
> Also, I would check that we haven't booted using ACPI rather than relying on 
> dt_find_node_by_path("/chosen") to return NULL.

Ok I will add a check on acpi_disabled to return if it is false.

Cheers,
Luca

> 
> Cheers,
> 
> -- 
> Julien Grall


 


Rackspace

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