From: sashiko-bot@kernel.org
To: "Shivank Garg" <shivankg@amd.com>
Cc: kvm@vger.kernel.org
Subject: Re: [PATCH 4/5] KVM: selftests: add get_numa_mem_nodes()
Date: Sun, 23 Aug 2026 13:47:59 +0000 [thread overview]
Message-ID: <20260823134800.596C51F000E9@smtp.kernel.org> (raw)
In-Reply-To: <20260823-shivank-gmem-fix-split-v1-4-512a29fb8e86@amd.com>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] `numaif.h` uses the `BITS_PER_TYPE` macro but does not include the header that defines it.
--
--- Patch [4]: [PATCH 4/5] KVM: selftests: add get_numa_mem_nodes() ---
commit 307e268608f2261ad345e9a86e81fdd51a53d40a
Author: Shivank Garg <shivankg@amd.com>
KVM: selftests: add get_numa_mem_nodes()
This patch moves the memory node query using MPOL_F_MEMS_ALLOWED from the
xAPIC IPI test into numaif.h as get_numa_mem_nodes(). This allows other
KVM selftests to use it directly instead of duplicating the logic.
> diff --git a/tools/testing/selftests/kvm/include/numaif.h b/tools/testing/selftests/kvm/include/numaif.h
> index 29572a6d789cd..55124e2330ab6 100644
> --- a/tools/testing/selftests/kvm/include/numaif.h
> +++ b/tools/testing/selftests/kvm/include/numaif.h
> @@ -75,6 +75,18 @@ static bool is_numa_available(void)
[ ... ]
> +static inline unsigned long get_numa_mem_nodes(void)
> +{
> + unsigned long nodemask = 0;
> +
> + /* Get set of first 64 numa nodes available */
> + if (get_mempolicy(NULL, &nodemask, BITS_PER_TYPE(nodemask), NULL,
> + MPOL_F_MEMS_ALLOWED))
[Severity: Low]
Does numaif.h need to include the header that defines BITS_PER_TYPE?
If a test includes numaif.h without previously including the header defining
this macro, it might fail to compile due to a missing definition, breaking
header self-containment.
> + return 0;
> +
> + return nodemask;
> +}
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260823-shivank-gmem-fix-split-v1-0-512a29fb8e86@amd.com?part=4
next prev parent reply other threads:[~2026-08-23 13:48 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-23 13:36 [PATCH 0/5] KVM: guest_memfd: fix unbind race and NUMA selftests Shivank Garg
2026-08-23 13:36 ` [PATCH 1/5] KVM: guest_memfd: take the invalidate lock when unbinding a dying file Shivank Garg
2026-08-23 13:50 ` sashiko-bot
2026-08-25 21:54 ` Sean Christopherson
2026-08-25 22:13 ` Sean Christopherson
2026-08-26 10:28 ` Garg, Shivank
2026-08-23 13:36 ` [PATCH 2/5] KVM: selftests: fix maxnode arguments in xapic_ipi_test Shivank Garg
2026-08-23 13:36 ` [PATCH 3/5] KVM: selftests: use BITS_PER_TYPE() for NUMA masks Shivank Garg
2026-08-23 13:36 ` [PATCH 4/5] KVM: selftests: add get_numa_mem_nodes() Shivank Garg
2026-08-23 13:47 ` sashiko-bot [this message]
2026-08-23 14:22 ` Garg, Shivank
2026-08-23 13:36 ` [PATCH 5/5] KVM: selftests: use allowed NUMA nodes in guest_memfd_test Shivank Garg
2026-08-31 8:24 ` [PATCH 0/5] KVM: guest_memfd: fix unbind race and NUMA selftests Garg, Shivank
2026-08-31 13:34 ` Sean Christopherson
2026-08-31 14:22 ` Garg, Shivank
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260823134800.596C51F000E9@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=kvm@vger.kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
--cc=shivankg@amd.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.