[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-ppc] [RFC 7/9] spapr: Remove versions from mc->desc
From: |
Thomas Huth |
Subject: |
Re: [Qemu-ppc] [RFC 7/9] spapr: Remove versions from mc->desc |
Date: |
Mon, 30 Nov 2015 17:57:11 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 |
On 30/11/15 09:51, David Gibson wrote:
> Currently, the versioned spapr machine types put the machine type version
> into the description string. PC does not do this, using just the name
> itself to distinguish. Doing the same lets us simplify the code slightly.
>
> Signed-off-by: David Gibson <address@hidden>
> ---
> hw/ppc/spapr.c | 6 +-----
> 1 file changed, 1 insertion(+), 5 deletions(-)
>
> diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
> index 5a130ff..1a4fe30 100644
> --- a/hw/ppc/spapr.c
> +++ b/hw/ppc/spapr.c
> @@ -2337,7 +2337,7 @@ static void spapr_machine_2_5_class_compat(MachineClass
> *mc)
> sPAPRMachineClass *smc = SPAPR_MACHINE_CLASS(mc);
>
> smc->dr_lmb_enabled = true;
> - mc->desc = "pSeries Logical Partition (PAPR compliant) v2.5";
> + mc->desc = "pSeries Logical Partition (PAPR compliant)";
> mc->alias = "pseries";
> mc->is_default = 1;
> }
> @@ -2358,7 +2358,6 @@ static void spapr_machine_2_4_class_compat(MachineClass
> *mc)
> mc->alias = NULL;
> mc->is_default = 0;
> smc->dr_lmb_enabled = false;
> - mc->desc = "pSeries Logical Partition (PAPR compliant) v2.4";
> SET_MACHINE_COMPAT(mc, SPAPR_COMPAT_2_4);
> }
>
> @@ -2385,7 +2384,6 @@ static void
> spapr_machine_2_3_instance_compat(MachineState *machine)
> static void spapr_machine_2_3_class_compat(MachineClass *mc)
> {
> spapr_machine_2_4_class_compat(mc);
> - mc->desc = "pSeries Logical Partition (PAPR compliant) v2.3";
> SET_MACHINE_COMPAT(mc, SPAPR_COMPAT_2_3);
> }
> DEFINE_SPAPR_MACHINE(2_3, "2.3", spapr_machine_2_3_instance_compat);
> @@ -2411,7 +2409,6 @@ static void
> spapr_machine_2_2_instance_compat(MachineState *machine)
> static void spapr_machine_2_2_class_compat(MachineClass *mc)
> {
> spapr_machine_2_3_class_compat(mc);
> - mc->desc = "pSeries Logical Partition (PAPR compliant) v2.2";
> SET_MACHINE_COMPAT(mc, SPAPR_COMPAT_2_2);
> }
> DEFINE_SPAPR_MACHINE(2_2, "2.2", spapr_machine_2_2_instance_compat);
> @@ -2431,7 +2428,6 @@ static void
> spapr_machine_2_1_instance_compat(MachineState *machine)
> static void spapr_machine_2_1_class_compat(MachineClass *mc)
> {
> spapr_machine_2_2_class_compat(mc);
> - mc->desc = "pSeries Logical Partition (PAPR compliant) v2.1";
> SET_MACHINE_COMPAT(mc, SPAPR_COMPAT_2_1);
> }
> DEFINE_SPAPR_MACHINE(2_1, "2.1", spapr_machine_2_1_instance_compat);
Sounds reasonable - the user does not get any additional information by
the additional version string when running QEMU with "-M help" since the
version is shown in the machine name already, so this should be fine, I
think.
Reviewed-by: Thomas Huth <address@hidden>
[Qemu-ppc] [RFC 8/9] spapr: Improve setting of default machine version, David Gibson, 2015/11/30
[Qemu-ppc] [RFC 2/9] spapr: Rearrange versioned machine type code, David Gibson, 2015/11/30