qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PULL 15/19] hw/arm/highbank: don't make sysram 'nomigr


From: Michael Clark
Subject: Re: [Qemu-devel] [PULL 15/19] hw/arm/highbank: don't make sysram 'nomigrate'
Date: Fri, 27 Apr 2018 10:03:46 +1200

On Thu, Apr 26, 2018 at 10:47 PM, Peter Maydell <address@hidden>
wrote:

> Currently we use memory_region_init_ram_nomigrate() to create
> the "highbank.sysram" memory region, and we don't manually
> register it with vmstate_register_ram(). This currently
> means that its contents are migrated but as a ram block
> whose name is the empty string; in future it may mean they
> are not migrated at all. Use memory_region_init_ram() instead.
>

It is self evident that memory_region_init_ram() implies normal migration.


> Note that this is a cross-version migration compatibility
> break for the "highbank" and "midway" machines.
>
> Signed-off-by: Peter Maydell <address@hidden>
>

Reviewed-by: Michael Clark <address@hidden>


> Message-id: address@hidden
> ---
>  hw/arm/highbank.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/hw/arm/highbank.c b/hw/arm/highbank.c
> index 1742cf6f6c..88326d1bfd 100644
> --- a/hw/arm/highbank.c
> +++ b/hw/arm/highbank.c
> @@ -291,7 +291,7 @@ static void calxeda_init(MachineState *machine, enum
> cxmachines machine_id)
>      memory_region_add_subregion(sysmem, 0, dram);
>
>      sysram = g_new(MemoryRegion, 1);
> -    memory_region_init_ram_nomigrate(sysram, NULL, "highbank.sysram",
> 0x8000,
> +    memory_region_init_ram(sysram, NULL, "highbank.sysram", 0x8000,
>                             &error_fatal);
>      memory_region_add_subregion(sysmem, 0xfff88000, sysram);
>

magic constants are better as #define or enum but there is a lot of code
that already does this, and that would be a separate change. It's peeking
through in the diff context :-D


>      if (bios_name != NULL) {
> --
> 2.17.0
>
>
>


reply via email to

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