On 30/5/23 13:38, David Hildenbrand wrote:
Let's intrduce a new helper that we will use to replace existing memory
device setup code during machine initialization. We'll enforce that the
size has to be > 0.
Once all machines were converted, we'll only allocate ms->device_memory
if the size > 0.
Signed-off-by: David Hildenbrand <[email protected]>
---
hw/mem/memory-device.c | 14 ++++++++++++++
include/hw/mem/memory-device.h | 2 ++
2 files changed, 16 insertions(+)
Reviewed-by: Philippe Mathieu-Daudé <[email protected]>