[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-ppc] [PATCH v7 01/13] machine: Don't allow CPU toplogies with
From: |
Eduardo Habkost |
Subject: |
Re: [Qemu-ppc] [PATCH v7 01/13] machine: Don't allow CPU toplogies with partially filled cores |
Date: |
Thu, 28 Jan 2016 17:04:57 -0200 |
User-agent: |
Mutt/1.5.23 (2014-03-12) |
On Thu, Jan 28, 2016 at 11:19:43AM +0530, Bharata B Rao wrote:
> Prevent guests from booting with CPU topologies that have partially
> filled CPU cores or can result in partially filled CPU cores after
> CPU hotplug like
>
> -smp 15,sockets=1,cores=4,threads=4,maxcpus=16 or
> -smp 15,sockets=1,cores=4,threads=4,maxcpus=17.
>
> This is enforced by introducing MachineClass::validate_smp_config()
> that gets called from generic SMP parsing code. Machine type versions
> that want to enforce this can define this to the generic version
> provided.
>
> Only sPAPR and PC machine types starting from version 2.6 enforce this in
> this patch.
>
> Signed-off-by: Bharata B Rao <address@hidden>
> ---
[...]
> diff --git a/vl.c b/vl.c
> index f043009..9e4da46 100644
> --- a/vl.c
> +++ b/vl.c
> @@ -4126,6 +4126,11 @@ int main(int argc, char **argv, char **envp)
>
> smp_parse(qemu_opts_find(qemu_find_opts("smp-opts"), NULL));
>
> + if (machine_class->validate_smp_config) {
> + machine_class->validate_smp_config(smp_cpus, max_cpus, smp_threads,
> + &error_abort);
Invalid SMP config should make QEMU just exit with an error, not
abort(). Please use &error_fatal instead.
The rest looks good.
--
Eduardo
- [Qemu-ppc] [PATCH v7 00/13] sPAPR CPU hotplug, Bharata B Rao, 2016/01/28
- [Qemu-ppc] [PATCH v7 03/13] exec: Do vmstate unregistration from cpu_exec_exit(), Bharata B Rao, 2016/01/28
- [Qemu-ppc] [PATCH v7 01/13] machine: Don't allow CPU toplogies with partially filled cores, Bharata B Rao, 2016/01/28
- Re: [Qemu-ppc] [PATCH v7 01/13] machine: Don't allow CPU toplogies with partially filled cores,
Eduardo Habkost <=
- Re: [Qemu-ppc] [PATCH v7 01/13] machine: Don't allow CPU toplogies with partially filled cores, David Gibson, 2016/01/28
- Re: [Qemu-ppc] [PATCH v7 01/13] machine: Don't allow CPU toplogies with partially filled cores, Eduardo Habkost, 2016/01/29
- Re: [Qemu-ppc] [PATCH v7 01/13] machine: Don't allow CPU toplogies with partially filled cores, Igor Mammedov, 2016/01/29
- Re: [Qemu-ppc] [PATCH v7 01/13] machine: Don't allow CPU toplogies with partially filled cores, Eduardo Habkost, 2016/01/29
- Re: [Qemu-ppc] [Qemu-devel] [PATCH v7 01/13] machine: Don't allow CPU toplogies with partially filled cores, Igor Mammedov, 2016/01/29
- Re: [Qemu-ppc] [Qemu-devel] [PATCH v7 01/13] machine: Don't allow CPU toplogies with partially filled cores, Eduardo Habkost, 2016/01/29
[Qemu-ppc] [PATCH v7 02/13] exec: Remove cpu from cpus list during cpu_exec_exit(), Bharata B Rao, 2016/01/28
[Qemu-ppc] [PATCH v7 04/13] cpu: Don't realize CPU from cpu_generic_init(), Bharata B Rao, 2016/01/28