hw/i386/pc: Confine system flash handling to pc_sysfw
commit6f6ad2b24582593d8feb00434ce2396840666227
authorBernhard Beschow <shentey@gmail.com>
Thu, 8 Feb 2024 22:03:46 +0000 (8 23:03 +0100)
committerPhilippe Mathieu-Daudé <philmd@linaro.org>
Thu, 22 Feb 2024 11:47:40 +0000 (22 12:47 +0100)
tree65393bfa2809c1c57a5b694b5cf1eebfe8a741d6
parenta0204a5ed091dfe79aced7ec8f3ce1931fd25816
hw/i386/pc: Confine system flash handling to pc_sysfw

Rather than distributing PC system flash handling across three files, let's
confine it to one. Now, pc_system_firmware_init() creates, configures and cleans
up the system flash which makes the code easier to understand. It also avoids
the extra call to pc_system_flash_cleanup_unused() in the Xen case.

Signed-off-by: Bernhard Beschow <shentey@gmail.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20240208220349.4948-7-shentey@gmail.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
hw/i386/pc.c
hw/i386/pc_piix.c
hw/i386/pc_sysfw.c
include/hw/i386/pc.h