* [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0
@ 2018-07-09 17:41 Eduardo Habkost
2018-07-09 17:41 ` [Qemu-devel] [PULL 1/2] machine: properly free device_memory Eduardo Habkost
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: Eduardo Habkost @ 2018-07-09 17:41 UTC (permalink / raw)
To: Peter Maydell, qemu-devel
Cc: Marcel Apfelbaum, Eduardo Habkost, Igor Mammedov,
Michael S. Tsirkin
The following changes since commit 43a473993fd9378bf850dcafa68eb6dee8c300f8:
Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging (2018-07-06 18:18:08 +0100)
are available in the Git repository at:
git://github.com/ehabkost/qemu.git tags/machine-next-pull-request
for you to fetch changes up to 7747abf114874537e898c60ff863828a4e82201d:
hw/machine: Remove the Zero check of nb_numa_nodes for numa_complete_configuration() (2018-07-09 14:37:48 -0300)
----------------------------------------------------------------
Machine/NUMA fixes for -rc0
* Properly free device_memory at machine_finalize()
* Fix implicit NUMA initialization regression (for machines with
auto_enable_numa_with_memhp=true)
----------------------------------------------------------------
Queue for Machine Core patches
David Hildenbrand (1):
machine: properly free device_memory
Dou Liyang (1):
hw/machine: Remove the Zero check of nb_numa_nodes for
numa_complete_configuration()
hw/core/machine.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
--
2.18.0.rc1.1.g3f1ff2140
^ permalink raw reply [flat|nested] 5+ messages in thread
* [Qemu-devel] [PULL 1/2] machine: properly free device_memory
2018-07-09 17:41 [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0 Eduardo Habkost
@ 2018-07-09 17:41 ` Eduardo Habkost
2018-07-09 17:41 ` [Qemu-devel] [PULL 2/2] hw/machine: Remove the Zero check of nb_numa_nodes for numa_complete_configuration() Eduardo Habkost
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: Eduardo Habkost @ 2018-07-09 17:41 UTC (permalink / raw)
To: Peter Maydell, qemu-devel
Cc: Marcel Apfelbaum, Eduardo Habkost, Igor Mammedov,
Michael S. Tsirkin, David Hildenbrand
From: David Hildenbrand <david@redhat.com>
Machines might have inititalized device_memory if they support memory
devices, so let's properly free it.
Signed-off-by: David Hildenbrand <david@redhat.com>
Message-Id: <20180702094152.7882-1-david@redhat.com>
Reviewed-by: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
hw/core/machine.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/hw/core/machine.c b/hw/core/machine.c
index 2077328bcc..3fad6f8801 100644
--- a/hw/core/machine.c
+++ b/hw/core/machine.c
@@ -674,6 +674,7 @@ static void machine_finalize(Object *obj)
g_free(ms->dumpdtb);
g_free(ms->dt_compatible);
g_free(ms->firmware);
+ g_free(ms->device_memory);
}
bool machine_usb(MachineState *machine)
--
2.18.0.rc1.1.g3f1ff2140
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [Qemu-devel] [PULL 2/2] hw/machine: Remove the Zero check of nb_numa_nodes for numa_complete_configuration()
2018-07-09 17:41 [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0 Eduardo Habkost
2018-07-09 17:41 ` [Qemu-devel] [PULL 1/2] machine: properly free device_memory Eduardo Habkost
@ 2018-07-09 17:41 ` Eduardo Habkost
2018-07-09 17:48 ` [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0 no-reply
2018-07-09 21:43 ` Peter Maydell
3 siblings, 0 replies; 5+ messages in thread
From: Eduardo Habkost @ 2018-07-09 17:41 UTC (permalink / raw)
To: Peter Maydell, qemu-devel
Cc: Marcel Apfelbaum, Eduardo Habkost, Igor Mammedov,
Michael S. Tsirkin, Dou Liyang
From: Dou Liyang <douly.fnst@cn.fujitsu.com>
Commit 7a3099fc9c5c("numa: postpone options post-processing till machine_run_board_init()")
broke the commit 7b8be49d36fc("NUMA: Enable adding NUMA node implicitly").
The machine_run_board_init() doesn't do NUMA setup if nb_numa_nodes=0,
but the numa_complete_configuration need add a new node if memory hotplug
is enabled (slots > 0) even nb_numa_nodes=0.
So, Remove the check for numa_complete_configuration() to fix this.
Fixes 7a3099fc9c5c("numa: postpone options post-processing till machine_run_board_init()")
Signed-off-by: Dou Liyang <douly.fnst@cn.fujitsu.com>
Message-Id: <20180704132239.6506-1-douly.fnst@cn.fujitsu.com>
Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
hw/core/machine.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/hw/core/machine.c b/hw/core/machine.c
index 3fad6f8801..a9aeb22f03 100644
--- a/hw/core/machine.c
+++ b/hw/core/machine.c
@@ -792,10 +792,9 @@ void machine_run_board_init(MachineState *machine)
{
MachineClass *machine_class = MACHINE_GET_CLASS(machine);
- if (nb_numa_nodes) {
- numa_complete_configuration(machine);
+ numa_complete_configuration(machine);
+ if (nb_numa_nodes)
machine_numa_finish_cpu_init(machine);
- }
/* If the machine supports the valid_cpu_types check and the user
* specified a CPU with -cpu check here that the user CPU is supported.
--
2.18.0.rc1.1.g3f1ff2140
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0
2018-07-09 17:41 [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0 Eduardo Habkost
2018-07-09 17:41 ` [Qemu-devel] [PULL 1/2] machine: properly free device_memory Eduardo Habkost
2018-07-09 17:41 ` [Qemu-devel] [PULL 2/2] hw/machine: Remove the Zero check of nb_numa_nodes for numa_complete_configuration() Eduardo Habkost
@ 2018-07-09 17:48 ` no-reply
2018-07-09 21:43 ` Peter Maydell
3 siblings, 0 replies; 5+ messages in thread
From: no-reply @ 2018-07-09 17:48 UTC (permalink / raw)
To: ehabkost; +Cc: famz, peter.maydell, qemu-devel, imammedo, mst
Hi,
This series seems to have some coding style problems. See output below for
more information:
Type: series
Message-id: 20180709174154.9470-1-ehabkost@redhat.com
Subject: [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0
=== TEST SCRIPT BEGIN ===
#!/bin/bash
BASE=base
n=1
total=$(git log --oneline $BASE.. | wc -l)
failed=0
git config --local diff.renamelimit 0
git config --local diff.renames True
git config --local diff.algorithm histogram
commits="$(git log --format=%H --reverse $BASE..)"
for c in $commits; do
echo "Checking PATCH $n/$total: $(git log -n 1 --format=%s $c)..."
if ! git show $c --format=email | ./scripts/checkpatch.pl --mailback -; then
failed=1
echo
fi
n=$((n+1))
done
exit $failed
=== TEST SCRIPT END ===
Updating 3c8cf5a9c21ff8782164d1def7f44bd888713384
From https://github.com/patchew-project/qemu
* [new tag] patchew/20180709174154.9470-1-ehabkost@redhat.com -> patchew/20180709174154.9470-1-ehabkost@redhat.com
Switched to a new branch 'test'
4956ab47be hw/machine: Remove the Zero check of nb_numa_nodes for numa_complete_configuration()
daaacdfd4b machine: properly free device_memory
=== OUTPUT BEGIN ===
Checking PATCH 1/2: machine: properly free device_memory...
Checking PATCH 2/2: hw/machine: Remove the Zero check of nb_numa_nodes for numa_complete_configuration()...
ERROR: braces {} are necessary for all arms of this statement
#34: FILE: hw/core/machine.c:796:
+ if (nb_numa_nodes)
[...]
total: 1 errors, 0 warnings, 12 lines checked
Your patch 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
---
Email generated automatically by Patchew [http://patchew.org/].
Please send your feedback to patchew-devel@redhat.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0
2018-07-09 17:41 [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0 Eduardo Habkost
` (2 preceding siblings ...)
2018-07-09 17:48 ` [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0 no-reply
@ 2018-07-09 21:43 ` Peter Maydell
3 siblings, 0 replies; 5+ messages in thread
From: Peter Maydell @ 2018-07-09 21:43 UTC (permalink / raw)
To: Eduardo Habkost
Cc: QEMU Developers, Marcel Apfelbaum, Igor Mammedov,
Michael S. Tsirkin
On 9 July 2018 at 18:41, Eduardo Habkost <ehabkost@redhat.com> wrote:
> The following changes since commit 43a473993fd9378bf850dcafa68eb6dee8c300f8:
>
> Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging (2018-07-06 18:18:08 +0100)
>
> are available in the Git repository at:
>
> git://github.com/ehabkost/qemu.git tags/machine-next-pull-request
>
> for you to fetch changes up to 7747abf114874537e898c60ff863828a4e82201d:
>
> hw/machine: Remove the Zero check of nb_numa_nodes for numa_complete_configuration() (2018-07-09 14:37:48 -0300)
>
> ----------------------------------------------------------------
> Machine/NUMA fixes for -rc0
>
> * Properly free device_memory at machine_finalize()
> * Fix implicit NUMA initialization regression (for machines with
> auto_enable_numa_with_memhp=true)
>
> ----------------------------------------------------------------
>
Applied, thanks.
-- PMM
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2018-07-09 21:44 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-07-09 17:41 [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0 Eduardo Habkost
2018-07-09 17:41 ` [Qemu-devel] [PULL 1/2] machine: properly free device_memory Eduardo Habkost
2018-07-09 17:41 ` [Qemu-devel] [PULL 2/2] hw/machine: Remove the Zero check of nb_numa_nodes for numa_complete_configuration() Eduardo Habkost
2018-07-09 17:48 ` [Qemu-devel] [PULL 0/2] Machine/NUMA fixes for -rc0 no-reply
2018-07-09 21:43 ` Peter Maydell
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).