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

[PATCH 2/6] x86/x2apic: use physical destination mode by default


  • To: xen-devel@xxxxxxxxxxxxxxxxxxxx
  • From: Roger Pau Monne <roger.pau@xxxxxxxxxx>
  • Date: Thu, 23 Jun 2022 10:24:24 +0200
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.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=mV+GSA3oDieHR/bXqJJFOlJFFYmGghYFGMWvwZGx7cE=; b=oIs9ZGWLbsDTb946MHt44xHElFjiUkn4dz55fAvTmwNwQyubEDLZZxzuHzB2vcS40N87XZKhsOZFSBlSQmapMzI39qMWStgRLv/BOwI0lVG301QV00KUdKJrR8NhDafe+AtswBcV4qukDbKVy0PwMeejIbDh8niaxLn4groLdSllKHbwNSHZWuNbgfhCKoeMOXPNmWfWxEkdtMjffJD5qg6ZtVRrLrVQaSH1WqR4+QN7DaAbYzQPMUe8dwFWOAH6HmzxRqVvavtGrOExTA0AnbTZW899Pu05ZXoJHTI5+dt7uyInYPSJolqJyTcfNGvGFe7RahcGxQ8seU4u0eHNWA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=bSeHdKlGl6KeIQqP5EybgsYP1KcCpx9XAxf+5iVFGT9/EDvrLdj/xEzwDY6W47BFOexPLqw//06ReXRkP2/B1oCwutzRRCAoU3QB/CbF6RCdCFMLS5SLpYONJvU4gXPYJekClFzkhnIRBxTNKnCaql/LkkH00CMJw3j39vcXLAseL4npD1kevBsegE3WPqVSAb7KRNXXr9ZO04JpMjyMqPm4mO8DUB5G09w0KuLS6lTqrdK9kpze+TYJOCVME8QPillSQOzPfB33Pp0Ps2RCWasPfyexLG4NCmF/gXulNloQFT6kHVKfwFhDGfxhv6flPdimupXonCUx3vRaGHXOlA==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com;
  • Cc: Roger Pau Monne <roger.pau@xxxxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
  • Delivery-date: Thu, 23 Jun 2022 08:25:27 +0000
  • Ironport-data: A9a23:WdLx3aLHG/rYz7/FFE+RzZQlxSXFcZb7ZxGr2PjKsXjdYENSgzxWy mIWWzyOP/6LNmP0ed51Pty/p0kB78fTzYVgHlNlqX01Q3x08seUXt7xwmUcns+xwm8vaGo9s q3yv/GZdJhcokf0/0vrav67xZVF/fngqoDUUYYoAQgsA14+IMsdoUg7wbRh3NQy2YTR7z6l4 rseneWOYDdJ5BYsWo4kw/rrRMRH5amaVJsw5zTSVNgT1LPsvyB94KE3fMldG0DQUIhMdtNWc s6YpF2PEsE1yD92Yj+tuu6TnkTn2dc+NyDW4pZdc/DKbhSvOkXee0v0XRYRQR4/ttmHozx+4 PwKuYDtaiF5B4nBg8Zedkh7TTx3AKITrdcrIVDn2SCS52vvViK2htlLUgQxN4Be/ftrC2ZT8 /BeMCoKch2Im+OxxvS8V/VogcMgasLsOevzuFk5lW2fUalgHMGFGvuajTNb9G5YasRmB/HRa tBfcTNyRB/BfwdOKhEcD5dWcOKA2SWlLmIA9gn9SawfwVKJlBJA07rXaoTRUPnUa+9yu0GEq TeTl4j+KlRAXDCF8hKV/3TpiuLRkCfTXIMJCKb+5vNsmEeUxGEYFFsRT1TTifuzh1O6WtlfA 1cJ4Sdopq83nGSpU938UhuQsHOC+BkGVLJ4CPYm4QuAzq7V5QexBWUeSDNFLts8u6ceWjgCx lKP2dTzClRSXKa9THuc8vKYqG20MC1Md2saP3ZaHU0C/sXpp5w1glTXVNF/HaWpj9rzXzbt3 zSNqyt4jLIW5SIW65iGEZn8q2rEjvD0osQdvG07gkrNAttFWbOY
  • Ironport-hdrordr: A9a23:i9xhhai31kgLKkVuNGyk0eserXBQX0h13DAbv31ZSRFFG/FwyP rCoB1L73XJYWgqM03I+eruBEBPewK/yXcT2/hqAV7CZnichILMFu1fBOTZslnd8kHFltK1kJ 0QCpSWa+eAcmSS8/yKhzVQeuxIqLfnzEnrv5an854Ed3AXV0gK1XYdNu/0KDwUeOEQbqBJaa Z0q/A37gaISDAyVICWF3MFV+/Mq5nik4/nWwcPA1oC5BOVhT2lxbbmG1zAty1uGA9n8PMHyy zoggb57qKsv7WSzQLd7Xba69BzlMH6wtVOKcSQgow+KynqiCyveIN9Mofy9AwdkaWK0hIHgd PMqxAvM4Ba7G7QRHi8pV/X1wzpwF8Vmgvf4G7dpUGmjd3yRTo8BcYEr5leaAHl500pu8w5+L 5X3kqC3qAnQi/orWDY3ZzlRhtqnk27rT4JiugIlUFSVoMYdft4sZEfxkVIC50NdRiKpLzPKN MeTf002cwmMW9zNxvizypSKZ2XLzkO9y69MwY/Upf/6UkVoJh7p3FosfD30E1wsa7VcKM0lt gsAp4Y6o2mcfVmHZ6VfN1xJ/dfKla9Ni4kY1jiV2gOKsk8SgHwgq+yxokJz8eXX7FN5KcOuf 36ISFlXCgJCgjTNfE=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

Using cluster mode by default greatly limits the amount of vectors
available, as then vector space is shared amongst all the CPUs in the
logical cluster.

This can lead to vector shortage issues on boxes with not a huge
amount of CPUs but with a non-trivial amount of devices, there are
reports of boxes with 32 CPUs (2 logical clusters, and thus only 414
dynamic vectors) that run out of vectors and fail to setup interrupts
for dom0.

This could be considered as a regression when switching from xAPIC
mode, as when using xAPIC only physical mode is supported.

Switch default Kconfig selection to use x2APIC physical mode.

Signed-off-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
---
 docs/misc/xen-command-line.pandoc | 5 ++---
 xen/arch/x86/Kconfig              | 4 ++--
 2 files changed, 4 insertions(+), 5 deletions(-)

diff --git a/docs/misc/xen-command-line.pandoc 
b/docs/misc/xen-command-line.pandoc
index a92b7d228c..952874c4f4 100644
--- a/docs/misc/xen-command-line.pandoc
+++ b/docs/misc/xen-command-line.pandoc
@@ -2646,11 +2646,10 @@ Permit use of x2apic setup for SMP environments.
 ### x2apic_phys (x86)
 > `= <boolean>`
 
-> Default: `true` if **FADT** mandates physical mode or if interrupt remapping
->          is not available, `false` otherwise.
+> Default: `false` if **FADT** mandates cluster mode, `true` otherwise.
 
 In the case that x2apic is in use, this option switches between physical and
-clustered mode.  The default, given no hint from the **FADT**, is cluster
+clustered mode.  The default, given no hint from the **FADT**, is physical
 mode.
 
 ### xenheap_megabytes (arm32)
diff --git a/xen/arch/x86/Kconfig b/xen/arch/x86/Kconfig
index f560dc13f4..74bfb37db4 100644
--- a/xen/arch/x86/Kconfig
+++ b/xen/arch/x86/Kconfig
@@ -228,11 +228,11 @@ endchoice
 
 choice
        prompt "x2APIC default destination mode"
-       default X2APIC_LOGICAL
+       default X2APIC_PHYS
        ---help---
          Specify default destination mode for x2APIC.
 
-         If unsure, choose "Logical".
+         If unsure, choose "Physical".
 
 config X2APIC_LOGICAL
        bool "Logical mode"
-- 
2.36.1




 


Rackspace

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