[RFC PATCH 1/3] exec/memory: Introduce memory_region_init_rom_device_from_file()

2021-02-25 Thread Philippe Mathieu-Daudé
Introduce memory_region_init_rom_device_from_file() which mmap the backing file of ROM devices. This allows to reduce QEMU memory footprint as the same file can be shared between multiple instances of QEMU. Signed-off-by: Philippe Mathieu-Daudé --- include/exec/memory.h | 85

Re: [RFC PATCH 1/3] exec/memory: Introduce memory_region_init_rom_device_from_file()

2021-03-01 Thread Stefano Garzarella
I don't know this code very well, but I have a couple of comments below :-) On Fri, Feb 26, 2021 at 12:02:36AM +0100, Philippe Mathieu-Daudé wrote: Introduce memory_region_init_rom_device_from_file() which mmap the backing file of ROM devices. This allows to reduce QEMU memory footprint as the

Re: [RFC PATCH 1/3] exec/memory: Introduce memory_region_init_rom_device_from_file()

2021-03-01 Thread Philippe Mathieu-Daudé
On 3/1/21 12:53 PM, Stefano Garzarella wrote: > I don't know this code very well, but I have a couple of comments below :-) > > On Fri, Feb 26, 2021 at 12:02:36AM +0100, Philippe Mathieu-Daudé wrote: >> Introduce memory_region_init_rom_device_from_file() which mmap >> the backing file of ROM devic