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

Re: [PATCH] xen: make multicall debug boot time selectable


  • To: Jürgen Groß <jgross@xxxxxxxx>, linux-kernel@xxxxxxxxxxxxxxx, x86@xxxxxxxxxx, linux-doc@xxxxxxxxxxxxxxx
  • From: boris.ostrovsky@xxxxxxxxxx
  • Date: Mon, 8 Jul 2024 10:32:46 -0400
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.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=ZnwlyQvoE3Rv2/At91FpookQgeRnODnb3bxS9ygpmgg=; b=RZkMaT8WbaERjmtWWSnLyTxKZ2FKDLbHeZeEtAD8nlVCg7P0Jnb0atRdsSCBqe/eShWZbN9tMjJtLymKrTiVdxYeUgLA5qcIlRdd6kLaFt7AQSYM9aYi7ptzO/cVM406HgjWUqQFgEybT4RTeFBSFEwj56w9wQGhWgDXN93WLegnS26hftor1rj0AMthZnvXUVSSA73R6nSV86jbCQZ2mw0+F+F+cLH4BXLbItofwgMVUNkofZ8eaTL2g79iDfqed0iBcy2+R+/9SS1f4cazITfdeu2S9dhsX9bP7yWpCYEpNnZkqUjcXsWoJL1z/lVI4ocKiUSxUlGVVJNC0jn0Fg==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=QSwVlLpV/Fb5rygUPc4N/zrZCVh76tklHR9T2ZR0UWsCJ6n5m/NMcVwTICJFU48jJjyDzv7Btifm13Bmk9aChqvuG12YQVLW2eymvkEsmTRO5FmcAdXMDRc8rcNcDPIGuDUWSNECJikOpjvLVUXffgvRTdAcBgsNoVGGszltBf05HRxq8eaJ7c4BpvUHqFeaPyji3NpnDILEfaTaEVYQCNcPCj71ucsZi3i3LuO4S6RkRgUVm7KrDPiCtT0V/aPh7o9KO2tZk0G+lWbgOwIllmk0GPjrKQaEplwOBkseYs4CA7sOMW0U+n8ZIQut735lvErkxz18gy5Ut7WxzSVEMA==
  • Cc: Jonathan Corbet <corbet@xxxxxxx>, Thomas Gleixner <tglx@xxxxxxxxxxxxx>, Ingo Molnar <mingo@xxxxxxxxxx>, Borislav Petkov <bp@xxxxxxxxx>, Dave Hansen <dave.hansen@xxxxxxxxxxxxxxx>, "H. Peter Anvin" <hpa@xxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
  • Delivery-date: Mon, 08 Jul 2024 14:33:30 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>



On 7/8/24 5:04 AM, Jürgen Groß wrote:
On 06.07.24 00:36, boris.ostrovsky@xxxxxxxxxx wrote:




Also, would it be better to keep these fields as a struct of scalars and instead have the percpu array of this struct? Otherwise there is a whole bunch of [MC_BATCH] arrays, all of them really indexed by the same value. (And while at it, there is no reason to have callbacks[MC_BATCH] sized like that -- it has nothing to do with batch size and can probably be made smaller)

As today the mc_buffer's entries are copied via a single memcpy(), there
are 3 options:

Ah yes, it's memcpy, I didn't think of that. Then leaving it as is is the best.


- make mc_debug_data a percpu pointer to a single array, requiring to
   copy the mc_buffer's entries in a loop

- let struct mc_debug_data contain two arrays (entries[] and struct foo {}[],
   with struct foo containing the other pointers/values)

- keep the layout as in my patch

Regarding the callbacks: I think the max number of callbacks is indeed MC_BATCH, as for each batch member one callback might be requested. So I'd rather keep it
the way it is today.


Right, I was trying to point out that it's the max number but I suspect it usually is smaller -- we currently ask for a callback in fewer than half of the cases where we submit a request.


-boris



 


Rackspace

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