[PATCH 0/3] account for NVDIMM nodes during SRAT generation

Vishal Verma posted 3 patches 4 years ago
Test docker-mingw@fedora passed
Test docker-quick@centos7 passed
Test checkpatch failed
Test FreeBSD passed
Test asan passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20200428012810.10877-1-vishal.l.verma@intel.com
Maintainers: Thomas Huth <thuth@redhat.com>, Laurent Vivier <lvivier@redhat.com>, "Michael S. Tsirkin" <mst@redhat.com>, Paolo Bonzini <pbonzini@redhat.com>, Igor Mammedov <imammedo@redhat.com>, Richard Henderson <rth@twiddle.net>, Eduardo Habkost <ehabkost@redhat.com>, Marcel Apfelbaum <marcel.apfelbaum@gmail.com>
There is a newer version of this series
hw/i386/acpi-build.c             |  20 ++++++++++++++++++++
tests/data/acpi/pc/SRAT.dimmpxm  | Bin 392 -> 392 bytes
tests/data/acpi/q35/SRAT.dimmpxm | Bin 392 -> 392 bytes
3 files changed, 20 insertions(+)
[PATCH 0/3] account for NVDIMM nodes during SRAT generation
Posted by Vishal Verma 4 years ago
On the command line, one can specify a NUMA node for NVDIMM devices. If
we set up the topology to give NVDIMMs their own nodes, i.e. not
containing any CPUs or regular memory, qemu doesn't populate SRAT memory
affinity structures for these nodes. However the NFIT does reference
those proximity domains.

As a result, Linux, while parsing the SRAT, fails to initialize node
related structures for these nodes, and they never end up in the
nodes_possible map. When these are onlined at a later point (via
hotplug), this causes problems.

I've followed the instructions in bios-tables-test.c to update the
expected SRAT binary, and the tests (make check) pass. Patches 1 and 3
are the relevant ones for the binary update.

Patch 2 is the main patch which changes SRAT generation.

Vishal Verma (3):
  diffs-allowed: add the SRAT AML to diffs-allowed
  hw/acpi-build: account for NVDIMM numa nodes in SRAT
  tests/acpi: update expected SRAT files

 hw/i386/acpi-build.c             |  20 ++++++++++++++++++++
 tests/data/acpi/pc/SRAT.dimmpxm  | Bin 392 -> 392 bytes
 tests/data/acpi/q35/SRAT.dimmpxm | Bin 392 -> 392 bytes
 3 files changed, 20 insertions(+)

-- 
2.25.4


Re: [PATCH 0/3] account for NVDIMM nodes during SRAT generation
Posted by Verma, Vishal L 3 years, 11 months ago
On Mon, 2020-04-27 at 19:28 -0600, Vishal Verma wrote:
> On the command line, one can specify a NUMA node for NVDIMM devices. If
> we set up the topology to give NVDIMMs their own nodes, i.e. not
> containing any CPUs or regular memory, qemu doesn't populate SRAT memory
> affinity structures for these nodes. However the NFIT does reference
> those proximity domains.
> 
> As a result, Linux, while parsing the SRAT, fails to initialize node
> related structures for these nodes, and they never end up in the
> nodes_possible map. When these are onlined at a later point (via
> hotplug), this causes problems.
> 
> I've followed the instructions in bios-tables-test.c to update the
> expected SRAT binary, and the tests (make check) pass. Patches 1 and 3
> are the relevant ones for the binary update.
> 
> Patch 2 is the main patch which changes SRAT generation.
> 
> Vishal Verma (3):
>   diffs-allowed: add the SRAT AML to diffs-allowed
>   hw/acpi-build: account for NVDIMM numa nodes in SRAT
>   tests/acpi: update expected SRAT files
> 
>  hw/i386/acpi-build.c             |  20 ++++++++++++++++++++
>  tests/data/acpi/pc/SRAT.dimmpxm  | Bin 392 -> 392 bytes
>  tests/data/acpi/q35/SRAT.dimmpxm | Bin 392 -> 392 bytes
>  3 files changed, 20 insertions(+)
> 
Hi All - Just pinging this patchset again. I neglected to CC maintainers
in the original posting, doing so now. The full series can be seen here:

https://lore.kernel.org/qemu-devel/20200428012810.10877-1-vishal.l.verma@intel.com/

If I should resend the patches, please let me know and I'll be happy to
do so.
Re: [PATCH 0/3] account for NVDIMM nodes during SRAT generation
Posted by no-reply@patchew.org 4 years ago
Patchew URL: https://patchew.org/QEMU/20200428012810.10877-1-vishal.l.verma@intel.com/



Hi,

This series seems to have some coding style problems. See output below for
more information:

Subject: [PATCH 0/3] account for NVDIMM nodes during SRAT generation
Message-id: 20200428012810.10877-1-vishal.l.verma@intel.com
Type: series

=== TEST SCRIPT BEGIN ===
#!/bin/bash
git rev-parse base > /dev/null || exit 0
git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram
./scripts/checkpatch.pl --mailback base..
=== TEST SCRIPT END ===

Switched to a new branch 'test'
34c59d3 tests/acpi: update expected SRAT files
dcc96eb hw/acpi-build: account for NVDIMM numa nodes in SRAT
08b7ee5 diffs-allowed: add the SRAT AML to diffs-allowed

=== OUTPUT BEGIN ===
1/3 Checking commit 08b7ee5e7ddf (diffs-allowed: add the SRAT AML to diffs-allowed)
2/3 Checking commit dcc96eb97d46 (hw/acpi-build: account for NVDIMM numa nodes in SRAT)
ERROR: Do not add expected files together with tests, follow instructions in tests/qtest/bios-tables-test.c: both tests/qtest/bios-tables-test-allowed-diff.h and hw/i386/acpi-build.c found

ERROR: Do not add expected files together with tests, follow instructions in tests/qtest/bios-tables-test.c: both tests/qtest/bios-tables-test-allowed-diff.h and hw/i386/acpi-build.c found

total: 2 errors, 0 warnings, 32 lines checked

Patch 2/3 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

3/3 Checking commit 34c59d3a0232 (tests/acpi: update expected SRAT files)
ERROR: Do not add expected files together with tests, follow instructions in tests/qtest/bios-tables-test.c: both tests/data/acpi/pc/SRAT.dimmpxm and hw/i386/acpi-build.c found

ERROR: Do not add expected files together with tests, follow instructions in tests/qtest/bios-tables-test.c: both tests/data/acpi/q35/SRAT.dimmpxm and hw/i386/acpi-build.c found

ERROR: Do not add expected files together with tests, follow instructions in tests/qtest/bios-tables-test.c: both tests/qtest/bios-tables-test-allowed-diff.h and hw/i386/acpi-build.c found

ERROR: Do not add expected files together with tests, follow instructions in tests/qtest/bios-tables-test.c: both tests/qtest/bios-tables-test-allowed-diff.h and hw/i386/acpi-build.c found

total: 4 errors, 0 warnings, 1 lines checked

Patch 3/3 has style problems, please review.  If any of these errors
are false positives report them to the maintainer, see
CHECKPATCH in MAINTAINERS.

=== OUTPUT END ===

Test command exited with code: 1


The full log is available at
http://patchew.org/logs/20200428012810.10877-1-vishal.l.verma@intel.com/testing.checkpatch/?type=message.
---
Email generated automatically by Patchew [https://patchew.org/].
Please send your feedback to patchew-devel@redhat.com
Re: [PATCH 0/3] account for NVDIMM nodes during SRAT generation
Posted by Verma, Vishal L 4 years ago
On Mon, 2020-04-27 at 19:44 -0700, no-reply@patchew.org wrote:
> Patchew URL: https://patchew.org/QEMU/20200428012810.10877-1-vishal.l.verma@intel.com/
[..]
> 
> === OUTPUT BEGIN ===
> 1/3 Checking commit 08b7ee5e7ddf (diffs-allowed: add the SRAT AML to
> diffs-allowed)
> 2/3 Checking commit dcc96eb97d46 (hw/acpi-build: account for NVDIMM
> numa nodes in SRAT)
> ERROR: Do not add expected files together with tests, follow
> instructions in tests/qtest/bios-tables-test.c: both tests/qtest/bios-
> tables-test-allowed-diff.h and hw/i386/acpi-build.c found
> 
> ERROR: Do not add expected files together with tests, follow
> instructions in tests/qtest/bios-tables-test.c: both tests/qtest/bios-
> tables-test-allowed-diff.h and hw/i386/acpi-build.c found

I'm not sure I follow these errors - I think I followed the instructions
in bios-tables-test.c exactly.. Did I miss something?

> 
> total: 2 errors, 0 warnings, 32 lines checked
> 
> Patch 2/3 has style problems, please review.  If any of these errors
> are false positives report them to the maintainer, see
> CHECKPATCH in MAINTAINERS.
> 
> 3/3 Checking commit 34c59d3a0232 (tests/acpi: update expected SRAT
> files)
> ERROR: Do not add expected files together with tests, follow
> instructions in tests/qtest/bios-tables-test.c: both
> tests/data/acpi/pc/SRAT.dimmpxm and hw/i386/acpi-build.c found
> 
> ERROR: Do not add expected files together with tests, follow
> instructions in tests/qtest/bios-tables-test.c: both
> tests/data/acpi/q35/SRAT.dimmpxm and hw/i386/acpi-build.c found
> 
> ERROR: Do not add expected files together with tests, follow
> instructions in tests/qtest/bios-tables-test.c: both tests/qtest/bios-
> tables-test-allowed-diff.h and hw/i386/acpi-build.c found
> 
> ERROR: Do not add expected files together with tests, follow
> instructions in tests/qtest/bios-tables-test.c: both tests/qtest/bios-
> tables-test-allowed-diff.h and hw/i386/acpi-build.c found
> 
> total: 4 errors, 0 warnings, 1 lines checked
> 
> Patch 3/3 has style problems, please review.  If any of these errors
> are false positives report them to the maintainer, see
> CHECKPATCH in MAINTAINERS.
> 
> === OUTPUT END ===
> 
> Test command exited with code: 1
> 
> 
> The full log is available at
> http://patchew.org/logs/20200428012810.10877-1-vishal.l.verma@intel.com/testing.checkpatch/?type=message.
> ---
> Email generated automatically by Patchew [https://patchew.org/].
> Please send your feedback to patchew-devel@redhat.com