qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH] spapr: Don't create ibm, dynamic-reconfiguratio


From: David Gibson
Subject: Re: [Qemu-devel] [PATCH] spapr: Don't create ibm, dynamic-reconfiguration-memory w/o DR LMBs
Date: Tue, 19 Jan 2016 16:00:25 +1100
User-agent: Mutt/1.5.24 (2015-08-30)

On Tue, Jan 19, 2016 at 10:09:21AM +0530, Bharata B Rao wrote:
> If guest doesn't have any dynamically reconfigurable (DR) logical memory
> blocks (LMB), then we shouldn't create ibm,dynamic-reconfiguration-memory
> device tree node.
> 
> Signed-off-by: Bharata B Rao <address@hidden>
> ---
> This applies against ppc-for-2.6 branch of David Gibson's tree.

Applied to ppc-for-2.6, thanks.

> 
>  hw/ppc/spapr.c | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)
> 
> diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
> index 50e5a26..86e5023 100644
> --- a/hw/ppc/spapr.c
> +++ b/hw/ppc/spapr.c
> @@ -763,6 +763,13 @@ static int 
> spapr_populate_drconf_memory(sPAPRMachineState *spapr, void *fdt)
>      int nr_nodes = nb_numa_nodes ? nb_numa_nodes : 1;
>  
>      /*
> +     * Don't create the node if there are no DR LMBs.
> +     */
> +    if (!nr_lmbs) {
> +        return 0;
> +    }
> +
> +    /*
>       * Allocate enough buffer size to fit in ibm,dynamic-memory
>       * or ibm,associativity-lookup-arrays
>       */
> @@ -868,7 +875,7 @@ int spapr_h_cas_compose_response(sPAPRMachineState *spapr,
>          _FDT((spapr_fixup_cpu_dt(fdt, spapr)));
>      }
>  
> -    /* Generate memory nodes or ibm,dynamic-reconfiguration-memory node */
> +    /* Generate ibm,dynamic-reconfiguration-memory node if required */
>      if (memory_update && smc->dr_lmb_enabled) {
>          _FDT((spapr_populate_drconf_memory(spapr, fdt)));
>      }

-- 
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]