Message ID | 20180730141134.31153-2-clg@kaod.org |
---|---|
State | New |
Headers | show |
Series | spapr: introduce a fixed IRQ number space and an IRQ controller backend | expand |
On Mon, 30 Jul 2018 16:11:31 +0200 Cédric Le Goater <clg@kaod.org> wrote: > Signed-off-by: Cédric Le Goater <clg@kaod.org> > --- Reviewed-by: Greg Kurz <groug@kaod.org> > include/hw/compat.h | 3 +++ > hw/ppc/spapr.c | 23 +++++++++++++++++++++-- > 2 files changed, 24 insertions(+), 2 deletions(-) > > diff --git a/include/hw/compat.h b/include/hw/compat.h > index c08f4040bb80..6f4d5fc64704 100644 > --- a/include/hw/compat.h > +++ b/include/hw/compat.h > @@ -1,6 +1,9 @@ > #ifndef HW_COMPAT_H > #define HW_COMPAT_H > > +#define HW_COMPAT_3_0 \ > + /* empty */ > + > #define HW_COMPAT_2_12 \ > {\ > .driver = "migration",\ > diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c > index 421b2dd09b51..3c72173c7e0f 100644 > --- a/hw/ppc/spapr.c > +++ b/hw/ppc/spapr.c > @@ -4058,19 +4058,38 @@ static const TypeInfo spapr_machine_info = { > } \ > type_init(spapr_machine_register_##suffix) > > + /* > + * pseries-3.1 > + */ > +static void spapr_machine_3_1_instance_options(MachineState *machine) > +{ > +} > + > +static void spapr_machine_3_1_class_options(MachineClass *mc) > +{ > + /* Defaults for the latest behaviour inherited from the base class */ > +} > + > +DEFINE_SPAPR_MACHINE(3_1, "3.1", true); > + > /* > * pseries-3.0 > */ > +#define SPAPR_COMPAT_3_0 \ > + HW_COMPAT_3_0 > + > static void spapr_machine_3_0_instance_options(MachineState *machine) > { > + spapr_machine_3_1_instance_options(machine); > } > > static void spapr_machine_3_0_class_options(MachineClass *mc) > { > - /* Defaults for the latest behaviour inherited from the base class */ > + spapr_machine_3_1_class_options(mc); > + SET_MACHINE_COMPAT(mc, SPAPR_COMPAT_3_0); > } > > -DEFINE_SPAPR_MACHINE(3_0, "3.0", true); > +DEFINE_SPAPR_MACHINE(3_0, "3.0", false); > > /* > * pseries-2.12
On Mon, Jul 30, 2018 at 04:11:31PM +0200, Cédric Le Goater wrote: > Signed-off-by: Cédric Le Goater <clg@kaod.org> Applied to ppc-for-3.1, thanks. > --- > include/hw/compat.h | 3 +++ > hw/ppc/spapr.c | 23 +++++++++++++++++++++-- > 2 files changed, 24 insertions(+), 2 deletions(-) > > diff --git a/include/hw/compat.h b/include/hw/compat.h > index c08f4040bb80..6f4d5fc64704 100644 > --- a/include/hw/compat.h > +++ b/include/hw/compat.h > @@ -1,6 +1,9 @@ > #ifndef HW_COMPAT_H > #define HW_COMPAT_H > > +#define HW_COMPAT_3_0 \ > + /* empty */ > + > #define HW_COMPAT_2_12 \ > {\ > .driver = "migration",\ > diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c > index 421b2dd09b51..3c72173c7e0f 100644 > --- a/hw/ppc/spapr.c > +++ b/hw/ppc/spapr.c > @@ -4058,19 +4058,38 @@ static const TypeInfo spapr_machine_info = { > } \ > type_init(spapr_machine_register_##suffix) > > + /* > + * pseries-3.1 > + */ > +static void spapr_machine_3_1_instance_options(MachineState *machine) > +{ > +} > + > +static void spapr_machine_3_1_class_options(MachineClass *mc) > +{ > + /* Defaults for the latest behaviour inherited from the base class */ > +} > + > +DEFINE_SPAPR_MACHINE(3_1, "3.1", true); > + > /* > * pseries-3.0 > */ > +#define SPAPR_COMPAT_3_0 \ > + HW_COMPAT_3_0 > + > static void spapr_machine_3_0_instance_options(MachineState *machine) > { > + spapr_machine_3_1_instance_options(machine); > } > > static void spapr_machine_3_0_class_options(MachineClass *mc) > { > - /* Defaults for the latest behaviour inherited from the base class */ > + spapr_machine_3_1_class_options(mc); > + SET_MACHINE_COMPAT(mc, SPAPR_COMPAT_3_0); > } > > -DEFINE_SPAPR_MACHINE(3_0, "3.0", true); > +DEFINE_SPAPR_MACHINE(3_0, "3.0", false); > > /* > * pseries-2.12
diff --git a/include/hw/compat.h b/include/hw/compat.h index c08f4040bb80..6f4d5fc64704 100644 --- a/include/hw/compat.h +++ b/include/hw/compat.h @@ -1,6 +1,9 @@ #ifndef HW_COMPAT_H #define HW_COMPAT_H +#define HW_COMPAT_3_0 \ + /* empty */ + #define HW_COMPAT_2_12 \ {\ .driver = "migration",\ diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index 421b2dd09b51..3c72173c7e0f 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -4058,19 +4058,38 @@ static const TypeInfo spapr_machine_info = { } \ type_init(spapr_machine_register_##suffix) + /* + * pseries-3.1 + */ +static void spapr_machine_3_1_instance_options(MachineState *machine) +{ +} + +static void spapr_machine_3_1_class_options(MachineClass *mc) +{ + /* Defaults for the latest behaviour inherited from the base class */ +} + +DEFINE_SPAPR_MACHINE(3_1, "3.1", true); + /* * pseries-3.0 */ +#define SPAPR_COMPAT_3_0 \ + HW_COMPAT_3_0 + static void spapr_machine_3_0_instance_options(MachineState *machine) { + spapr_machine_3_1_instance_options(machine); } static void spapr_machine_3_0_class_options(MachineClass *mc) { - /* Defaults for the latest behaviour inherited from the base class */ + spapr_machine_3_1_class_options(mc); + SET_MACHINE_COMPAT(mc, SPAPR_COMPAT_3_0); } -DEFINE_SPAPR_MACHINE(3_0, "3.0", true); +DEFINE_SPAPR_MACHINE(3_0, "3.0", false); /* * pseries-2.12
Signed-off-by: Cédric Le Goater <clg@kaod.org> --- include/hw/compat.h | 3 +++ hw/ppc/spapr.c | 23 +++++++++++++++++++++-- 2 files changed, 24 insertions(+), 2 deletions(-)