mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-08 02:03:56 -06:00
hw/xen: Rename 'ram_memory' global variable as 'xen_memory'
To avoid a potential global variable shadow in hw/i386/pc_piix.c::pc_init1(), rename Xen's "ram_memory" as "xen_memory". Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: David Woodhouse <dwmw@amazon.co.uk> Message-Id: <20231114143816.71079-11-philmd@linaro.org>
This commit is contained in:
parent
9cd909ac35
commit
b934c3fa21
4 changed files with 12 additions and 12 deletions
|
@ -149,12 +149,12 @@ static void xen_ram_init(PCMachineState *pcms,
|
|||
*/
|
||||
block_len = (4 * GiB) + x86ms->above_4g_mem_size;
|
||||
}
|
||||
memory_region_init_ram(&ram_memory, NULL, "xen.ram", block_len,
|
||||
memory_region_init_ram(&xen_memory, NULL, "xen.ram", block_len,
|
||||
&error_fatal);
|
||||
*ram_memory_p = &ram_memory;
|
||||
*ram_memory_p = &xen_memory;
|
||||
|
||||
memory_region_init_alias(&ram_640k, NULL, "xen.ram.640k",
|
||||
&ram_memory, 0, 0xa0000);
|
||||
&xen_memory, 0, 0xa0000);
|
||||
memory_region_add_subregion(sysmem, 0, &ram_640k);
|
||||
/* Skip of the VGA IO memory space, it will be registered later by the VGA
|
||||
* emulated device.
|
||||
|
@ -163,12 +163,12 @@ static void xen_ram_init(PCMachineState *pcms,
|
|||
* the Options ROM, so it is registered here as RAM.
|
||||
*/
|
||||
memory_region_init_alias(&ram_lo, NULL, "xen.ram.lo",
|
||||
&ram_memory, 0xc0000,
|
||||
&xen_memory, 0xc0000,
|
||||
x86ms->below_4g_mem_size - 0xc0000);
|
||||
memory_region_add_subregion(sysmem, 0xc0000, &ram_lo);
|
||||
if (x86ms->above_4g_mem_size > 0) {
|
||||
memory_region_init_alias(&ram_hi, NULL, "xen.ram.hi",
|
||||
&ram_memory, 0x100000000ULL,
|
||||
&xen_memory, 0x100000000ULL,
|
||||
x86ms->above_4g_mem_size);
|
||||
memory_region_add_subregion(sysmem, 0x100000000ULL, &ram_hi);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue