qemu-ppc
[Top][All Lists]
Advanced

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

Re: [Qemu-ppc] [Qemu-devel] [RFC v0 1/2] spapr: Accommadate alignment ga


From: Thomas Huth
Subject: Re: [Qemu-ppc] [Qemu-devel] [RFC v0 1/2] spapr: Accommadate alignment gaps in hotplug memory region
Date: Mon, 5 Oct 2015 17:24:56 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0

On 05/10/15 10:35, Bharata B Rao wrote:
> Size hotplug memory region assuming a 256MB max alignment every slot.
> 
> Signed-off-by: Bharata B Rao <address@hidden>
> ---
>  hw/ppc/spapr.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
> index fc5e7d6..2ec509b 100644
> --- a/hw/ppc/spapr.c
> +++ b/hw/ppc/spapr.c
> @@ -1792,6 +1792,9 @@ static void ppc_spapr_init(MachineState *machine)
>  
>          spapr->hotplug_memory.base = ROUND_UP(machine->ram_size,
>                                                SPAPR_HOTPLUG_MEM_ALIGN);
> +
> +        /* size hotplug region assuming 256M max alignment per slot */
> +        hotplug_mem_size += SPAPR_MEMORY_BLOCK_SIZE * machine->ram_slots;

Could you maybe make the comment here a little bit more verbose? Without
reading the cover letter first, I would not understand this piece of
code ... and I'm afraid that when we look at this code in a couple of
years again, we hit the same problem when the comment is that short.

Thanks,
  Thomas




reply via email to

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