qemu-ppc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 2/4] spapr: Move creation of ibm,architecture-vec-5 property


From: David Gibson
Subject: Re: [PATCH 2/4] spapr: Move creation of ibm,architecture-vec-5 property
Date: Mon, 16 Mar 2020 13:42:31 +1100

On Fri, Mar 13, 2020 at 12:40:03PM +0100, Greg Kurz wrote:
> On Fri, 13 Mar 2020 15:05:37 +1100
> David Gibson <address@hidden> wrote:
> 
> > This is currently called from spapr_dt_cas_updates() which is a hang over
> > from when we created this only as a diff to the DT at CAS time.  Now that
> > we fully rebuild the DT at CAS time, just create it alon with the rest
> 
> s/alon/along

Corrected, thanks.

> 
> > of the properties in /chosen.
> > 
> > Signed-off-by: David Gibson <address@hidden>
> > ---
> >  hw/ppc/spapr.c | 26 +++-----------------------
> >  1 file changed, 3 insertions(+), 23 deletions(-)
> > 
> > diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
> > index 66289ffef5..fc28d9df25 100644
> > --- a/hw/ppc/spapr.c
> > +++ b/hw/ppc/spapr.c
> > @@ -889,22 +889,6 @@ static int spapr_rng_populate_dt(void *fdt)
> >      return ret ? -1 : 0;
> >  }
> >  
> > -static int spapr_dt_cas_updates(SpaprMachineState *spapr, void *fdt,
> > -                                SpaprOptionVector *ov5_updates)
> 
> Heh I should have looked at patch 2 before commenting on patch 1 :)
> 
> Reviewed-by: Greg Kurz <address@hidden>
> 
> > -{
> > -    int offset;
> > -
> > -    offset = fdt_path_offset(fdt, "/chosen");
> > -    if (offset < 0) {
> > -        offset = fdt_add_subnode(fdt, 0, "chosen");
> > -        if (offset < 0) {
> > -            return offset;
> > -        }
> > -    }
> > -    return spapr_ovec_populate_dt(fdt, offset, spapr->ov5_cas,
> > -                                  "ibm,architecture-vec-5");
> > -}
> > -
> >  static void spapr_dt_rtas(SpaprMachineState *spapr, void *fdt)
> >  {
> >      MachineState *ms = MACHINE(spapr);
> > @@ -1115,6 +1099,9 @@ static void spapr_dt_chosen(SpaprMachineState *spapr, 
> > void *fdt)
> >  
> >      spapr_dt_ov5_platform_support(spapr, fdt, chosen);
> >  
> > +    _FDT(spapr_ovec_populate_dt(fdt, offset, spapr->ov5_cas,
> > +                                "ibm,architecture-vec-5"));
> > +
> >      g_free(stdout_path);
> >      g_free(bootlist);
> >  }
> > @@ -1263,13 +1250,6 @@ void *spapr_build_fdt(SpaprMachineState *spapr, bool 
> > reset, size_t space)
> >          }
> >      }
> >  
> > -    /* ibm,client-architecture-support updates */
> > -    ret = spapr_dt_cas_updates(spapr, fdt, spapr->ov5_cas);
> > -    if (ret < 0) {
> > -        error_report("couldn't setup CAS properties fdt");
> > -        exit(1);
> > -    }
> > -
> >      if (smc->dr_phb_enabled) {
> >          ret = spapr_dt_drc(fdt, 0, NULL, SPAPR_DR_CONNECTOR_TYPE_PHB);
> >          if (ret < 0) {
> 

-- 
David Gibson                    | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au  | minimalist, thank you.  NOT _the_ _other_
                                | _way_ _around_!
http://www.ozlabs.org/~dgibson

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]