All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] numa: Skip invalidation of cluster and NUMA node boundary for qtest
@ 2023-07-21 10:44 Gavin Shan
  2023-07-21 11:29 ` Peter Maydell
  0 siblings, 1 reply; 3+ messages in thread
From: Gavin Shan @ 2023-07-21 10:44 UTC (permalink / raw)
  To: qemu-arm
  Cc: qemu-devel, eduardo, marcel.apfelbaum, philmd, wangyanan55,
	imammedo, peter.maydell, pbonzini, shan.gavin

There are warning messages printed from tests/qtest/numa-test.c,
to complain the CPU cluster and NUMA node boundary is broken. Since
the broken boundary is expected, we don't want to see the warning
messages.

  # cd /home/gavin/sandbox/qemu.main/build
  # MALLOC_PERTURB_=255 QTEST_QEMU_BINARY=./qemu-system-aarch64           \
    G_TEST_DBUS_DAEMON=../tests/dbus-vmstate-daemon.sh                    \
    QTEST_QEMU_IMG=./qemu-img                                             \
    QTEST_QEMU_STORAGE_DAEMON_BINARY=./storage-daemon/qemu-storage-daemon \
    tests/qtest/numa-test --tap -k
      :
    qemu-system-aarch64: warning: CPU-0 and CPU-4 in socket-0-cluster-0   \
    have been associated with node-0 and node-1 respectively.             \
    It can cause OSes like Linux to misbehave
      :

Skip the invalidation of CPU cluster and NUMA node boundary when
qtest is enabled, to avoid the warning messages.

Fixes: a494fdb715 ("numa: Validate cluster and NUMA node boundary if required")
Signed-off-by: Gavin Shan <gshan@redhat.com>
---
 hw/core/machine.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/core/machine.c b/hw/core/machine.c
index f0d35c6401..1c5136e735 100644
--- a/hw/core/machine.c
+++ b/hw/core/machine.c
@@ -1271,7 +1271,7 @@ static void validate_cpu_cluster_to_numa_boundary(MachineState *ms)
     const CPUArchId *cpus = possible_cpus->cpus;
     int i, j;
 
-    if (state->num_nodes <= 1 || possible_cpus->len <= 1) {
+    if (qtest_enabled() || state->num_nodes <= 1 || possible_cpus->len <= 1) {
         return;
     }
 
-- 
2.41.0



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] numa: Skip invalidation of cluster and NUMA node boundary for qtest
  2023-07-21 10:44 [PATCH] numa: Skip invalidation of cluster and NUMA node boundary for qtest Gavin Shan
@ 2023-07-21 11:29 ` Peter Maydell
  2024-01-11 15:41   ` Peter Maydell
  0 siblings, 1 reply; 3+ messages in thread
From: Peter Maydell @ 2023-07-21 11:29 UTC (permalink / raw)
  To: Gavin Shan
  Cc: qemu-arm, qemu-devel, eduardo, marcel.apfelbaum, philmd,
	wangyanan55, imammedo, pbonzini, shan.gavin

On Fri, 21 Jul 2023 at 11:44, Gavin Shan <gshan@redhat.com> wrote:
>
> There are warning messages printed from tests/qtest/numa-test.c,
> to complain the CPU cluster and NUMA node boundary is broken. Since
> the broken boundary is expected, we don't want to see the warning
> messages.
>
>   # cd /home/gavin/sandbox/qemu.main/build
>   # MALLOC_PERTURB_=255 QTEST_QEMU_BINARY=./qemu-system-aarch64           \
>     G_TEST_DBUS_DAEMON=../tests/dbus-vmstate-daemon.sh                    \
>     QTEST_QEMU_IMG=./qemu-img                                             \
>     QTEST_QEMU_STORAGE_DAEMON_BINARY=./storage-daemon/qemu-storage-daemon \
>     tests/qtest/numa-test --tap -k
>       :
>     qemu-system-aarch64: warning: CPU-0 and CPU-4 in socket-0-cluster-0   \
>     have been associated with node-0 and node-1 respectively.             \
>     It can cause OSes like Linux to misbehave
>       :
>
> Skip the invalidation of CPU cluster and NUMA node boundary when
> qtest is enabled, to avoid the warning messages.
>
> Fixes: a494fdb715 ("numa: Validate cluster and NUMA node boundary if required")
> Signed-off-by: Gavin Shan <gshan@redhat.com>

Reviewed-by: Peter Maydell <peter.maydell@linaro.org>

thanks
-- PMM


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] numa: Skip invalidation of cluster and NUMA node boundary for qtest
  2023-07-21 11:29 ` Peter Maydell
@ 2024-01-11 15:41   ` Peter Maydell
  0 siblings, 0 replies; 3+ messages in thread
From: Peter Maydell @ 2024-01-11 15:41 UTC (permalink / raw)
  To: Gavin Shan
  Cc: qemu-arm, qemu-devel, eduardo, marcel.apfelbaum, philmd,
	wangyanan55, imammedo, pbonzini, shan.gavin

On Fri, 21 Jul 2023 at 12:29, Peter Maydell <peter.maydell@linaro.org> wrote:
>
> On Fri, 21 Jul 2023 at 11:44, Gavin Shan <gshan@redhat.com> wrote:
> >
> > There are warning messages printed from tests/qtest/numa-test.c,
> > to complain the CPU cluster and NUMA node boundary is broken. Since
> > the broken boundary is expected, we don't want to see the warning
> > messages.
> >
> >   # cd /home/gavin/sandbox/qemu.main/build
> >   # MALLOC_PERTURB_=255 QTEST_QEMU_BINARY=./qemu-system-aarch64           \
> >     G_TEST_DBUS_DAEMON=../tests/dbus-vmstate-daemon.sh                    \
> >     QTEST_QEMU_IMG=./qemu-img                                             \
> >     QTEST_QEMU_STORAGE_DAEMON_BINARY=./storage-daemon/qemu-storage-daemon \
> >     tests/qtest/numa-test --tap -k
> >       :
> >     qemu-system-aarch64: warning: CPU-0 and CPU-4 in socket-0-cluster-0   \
> >     have been associated with node-0 and node-1 respectively.             \
> >     It can cause OSes like Linux to misbehave
> >       :
> >
> > Skip the invalidation of CPU cluster and NUMA node boundary when
> > qtest is enabled, to avoid the warning messages.
> >
> > Fixes: a494fdb715 ("numa: Validate cluster and NUMA node boundary if required")
> > Signed-off-by: Gavin Shan <gshan@redhat.com>
>
> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>

Looks like this got lost last year. I'm going to pick it up and
apply it since the warnings it suppresses are still in the
test output.

thanks
-- PMM


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-01-11 15:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-21 10:44 [PATCH] numa: Skip invalidation of cluster and NUMA node boundary for qtest Gavin Shan
2023-07-21 11:29 ` Peter Maydell
2024-01-11 15:41   ` Peter Maydell

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.