[PATCH 0/3] numa_conf: Deny other memory modes than 'restrictive' if a memnode is 'restrictive'

Michal Privoznik posted 3 patches 10 months, 1 week ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/libvirt tags/patchew/cover.1684749027.git.mprivozn@redhat.com
src/conf/numa_conf.c                          | 26 ++++++++----
src/conf/numa_conf.h                          |  2 +-
...strictive-mode-err-mixed.x86_64-latest.err |  1 +
...une-memnode-restrictive-mode-err-mixed.xml | 41 +++++++++++++++++++
tests/qemuxml2argvtest.c                      |  1 +
5 files changed, 61 insertions(+), 10 deletions(-)
create mode 100644 tests/qemuxml2argvdata/numatune-memnode-restrictive-mode-err-mixed.x86_64-latest.err
create mode 100644 tests/qemuxml2argvdata/numatune-memnode-restrictive-mode-err-mixed.xml
[PATCH 0/3] numa_conf: Deny other memory modes than 'restrictive' if a memnode is 'restrictive'
Posted by Michal Privoznik 10 months, 1 week ago
We already check that there's no <memnode mode='restrictive'/> when
<memory mode='restrictive'/> is set. But we are missing the opposite
check: there's <memory mode='restrictive'/> when there is <memnode
mode='restrictive'/>.

Michal Prívozník (3):
  virDomainNumatuneNodeSpecified: Fix const correctness
  numa_conf: Move memnode mode validation into
    virDomainNumaDefValidate()
  numa_conf: Deny other memory modes than 'restrictive' if a memnode is
    'restrictive'

 src/conf/numa_conf.c                          | 26 ++++++++----
 src/conf/numa_conf.h                          |  2 +-
 ...strictive-mode-err-mixed.x86_64-latest.err |  1 +
 ...une-memnode-restrictive-mode-err-mixed.xml | 41 +++++++++++++++++++
 tests/qemuxml2argvtest.c                      |  1 +
 5 files changed, 61 insertions(+), 10 deletions(-)
 create mode 100644 tests/qemuxml2argvdata/numatune-memnode-restrictive-mode-err-mixed.x86_64-latest.err
 create mode 100644 tests/qemuxml2argvdata/numatune-memnode-restrictive-mode-err-mixed.xml

-- 
2.39.3

Re: [PATCH 0/3] numa_conf: Deny other memory modes than 'restrictive' if a memnode is 'restrictive'
Posted by Martin Kletzander 10 months, 1 week ago
On Mon, May 22, 2023 at 11:53:45AM +0200, Michal Privoznik wrote:
>We already check that there's no <memnode mode='restrictive'/> when
><memory mode='restrictive'/> is set. But we are missing the opposite
>check: there's <memory mode='restrictive'/> when there is <memnode
>mode='restrictive'/>.
>

Even though the logic is inverted in here it is correct both in the
patch and in the commit messages, so for the series:

Reviewed-by: Martin Kletzander <mkletzan@redhat.com>

>Michal Prívozník (3):
>  virDomainNumatuneNodeSpecified: Fix const correctness
>  numa_conf: Move memnode mode validation into
>    virDomainNumaDefValidate()
>  numa_conf: Deny other memory modes than 'restrictive' if a memnode is
>    'restrictive'
>
> src/conf/numa_conf.c                          | 26 ++++++++----
> src/conf/numa_conf.h                          |  2 +-
> ...strictive-mode-err-mixed.x86_64-latest.err |  1 +
> ...une-memnode-restrictive-mode-err-mixed.xml | 41 +++++++++++++++++++
> tests/qemuxml2argvtest.c                      |  1 +
> 5 files changed, 61 insertions(+), 10 deletions(-)
> create mode 100644 tests/qemuxml2argvdata/numatune-memnode-restrictive-mode-err-mixed.x86_64-latest.err
> create mode 100644 tests/qemuxml2argvdata/numatune-memnode-restrictive-mode-err-mixed.xml
>
>-- 
>2.39.3
>