[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [PATCH v4 02/10] xen/page_alloc: Optimize getting per-NUMA-node free page counts
- To: Jan Beulich <jbeulich@xxxxxxxx>
- From: Bernhard Kaindl <bernhard.kaindl@xxxxxxxxxx>
- Date: Wed, 4 Mar 2026 18:21:42 +0000
- Accept-language: en-GB, en-US
- 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=arcselector10001; 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=HT8S73pF0AdY20RHfdnN8wYSfqur/qUxBePSwcJeCFA=; b=Yx7oP7WNziXcjxkN7+1gu8n6iUtLmqjnNY5RJJVR9S0r1T6r/S+DF/jtezQggNhUfn3xKHO+efqa95qGj4tIXeAPf0T0x73zHppwgGuQkWRhdrly9zufkAkN3DIj6rcCOidq6qm3RTX0kRwMDDTKl95zMIFi2GNlw06zReJwKUtqTOahVIOzarA9rFuNlDO9ytpYmHoehnV3yeVp3s4u8Z4ud/SjsT9TdS2JVR24Yx90Ij326EOyjNbDcGDXBfOEztwf00nYrhr5cjr7V3ZywG3RxAksvoD+6qMU84IkQ0K4oYI2J58qXo1NX7JbrSzj1cr/R47d80MYp7V38DmXdw==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=sLOxQA3bUqKpeA0RY8nfFo1TqVEPEyR/LNFQR8qYKUHSIz1FnDSnETWcEqeNLrUgAvlX3qluQE/b6w37ya8c7j/UEezT6BIgu9U9LVHzC88kEddBu6hsyYzSuT+ubFNlkVKpE8j4tSP2oeX3N8ph7gT/pQPTZf17QOTTHz98eOvC9rsPvJ3xlTpEamCBgVDmckop6mERLzWeLsSDwkhksMhRQB330v9+aqOYzWkbgA2CvM0GVV5FmLheabWUCLkwl67PPu70XKqXk2nCe4gHg8IYdW1zQxvWJavdxuFPzVSpr7F4M0rQOZMFKed/WT00AXGYYoOH/Na82oAf9flm6g==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com;
- Cc: Andrew Cooper <andrew.cooper@xxxxxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>, Michal Orzel <michal.orzel@xxxxxxx>, Julien Grall <julien@xxxxxxx>, Roger Pau Monne <roger.pau@xxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- Delivery-date: Wed, 04 Mar 2026 18:21:55 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
- Thread-index: AQHcpy3M66O7r2QZuEav6YZwQwz7ULWemlMAgAAa8BA=
- Thread-topic: [PATCH v4 02/10] xen/page_alloc: Optimize getting per-NUMA-node free page counts
Jan Beulich <jbeulich@xxxxxxxx> wrote:
> On 26.02.2026 15:29, Bernhard Kaindl wrote:
> >
> > Also change total_avail_pages and outstanding_claims to unsigned long:
> >
> > Those never become negative (we protect that with ASSERT/BUG_ON already),
> > and converting them to unsigned long makes that explicit, and also
> > fixes signed/unsigned comparison warnings.
>
> This wants to be a separate commit. It hasn't got anything to do in here.
Ok.
> > This only needs moving the ASSERT to before the subtraction.
> > See the previous commit moving the BUG_ON for outstanding_claims.
>
> Please can you avoid such statements? You won't know in which order the
> patches are committed: Patch 01 may go in weeks or months before patch
> 02.
Thanks, ok, will remove.
- NB. I do think the first 3 commits should best be applied in one go.
> > +#define node_avail_pages(node) (node_avail_pages[node])
>
> This isn't really needed when ...
>
> > +static unsigned long node_avail_pages[MAX_NUMNODES];
>
> ... it's a static array anyway. Plus you may want to talk to Andrew regarding
> the use of such a macro as an lvalue.
Ok. It was only a controlled, local accessor in this file to support moving
it to another storage variable, but I'll omit the accessor macro(s) then.
> > +/* total outstanding claims by all domains */
> > +static unsigned long outstanding_claims;
>
> As you touch it, comment style wants correcting.
I guess you mean to uppercase the 1st letter of the comment. Will do.
Bernhard
|