From abcbc4eeca50bc4fa2963f8cc6308c3aad51148a Mon Sep 17 00:00:00 2001 From: Philippe Mathieu-Daudé Date: Fri, 7 Feb 2020 17:19:46 +0100 Subject: hw: Do not initialize MachineClass::is_default to 0 The MachineClass is already zeroed on creation. Note: The code setting is_default=0 in hw/i386/pc_piix.c is different (related to compat options). When adding a new versioned machine, we want it to be the new default, so we have to mark the previous one as not default. Signed-off-by: Philippe Mathieu-Daudé Message-Id: <20200207161948.15972-2-philmd@redhat.com> Reviewed-by: Laurent Vivier Signed-off-by: Eduardo Habkost --- hw/lm32/lm32_boards.c | 1 - hw/lm32/milkymist.c | 1 - 2 files changed, 2 deletions(-) (limited to 'hw/lm32') diff --git a/hw/lm32/lm32_boards.c b/hw/lm32/lm32_boards.c index 4e0a98c117..747a175b55 100644 --- a/hw/lm32/lm32_boards.c +++ b/hw/lm32/lm32_boards.c @@ -313,7 +313,6 @@ static void lm32_uclinux_class_init(ObjectClass *oc, void *data) mc->desc = "lm32 platform for uClinux and u-boot by Theobroma Systems"; mc->init = lm32_uclinux_init; - mc->is_default = 0; mc->default_cpu_type = LM32_CPU_TYPE_NAME("lm32-full"); mc->default_ram_size = 64 * MiB; mc->default_ram_id = "lm32_uclinux.sdram"; diff --git a/hw/lm32/milkymist.c b/hw/lm32/milkymist.c index 5c72266e58..85913bb68b 100644 --- a/hw/lm32/milkymist.c +++ b/hw/lm32/milkymist.c @@ -219,7 +219,6 @@ static void milkymist_machine_init(MachineClass *mc) { mc->desc = "Milkymist One"; mc->init = milkymist_init; - mc->is_default = 0; mc->default_cpu_type = LM32_CPU_TYPE_NAME("lm32-full"); mc->default_ram_size = 128 * MiB; mc->default_ram_id = "milkymist.sdram"; -- cgit v1.2.3-55-g7522