qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH 13/21] hw/nvram/fw_cfg: Remove legacy FW_CFG_ORDER_OVERRIDE


From: Daniel P . Berrangé
Subject: Re: [PATCH 13/21] hw/nvram/fw_cfg: Remove legacy FW_CFG_ORDER_OVERRIDE
Date: Thu, 16 Jan 2025 10:13:00 +0000
User-agent: Mutt/2.2.13 (2024-03-09)

On Thu, Jan 16, 2025 at 12:22:39AM +0100, Philippe Mathieu-Daudé wrote:
> The MachineClass::legacy_fw_cfg_order boolean was only used
> by the pc-q35-2.5 and pc-i440fx-2.5 machines, which got
> removed. Remove it along with:
> 
> - FW_CFG_ORDER_OVERRIDE_* definitions
> - fw_cfg_set_order_override()
> - fw_cfg_reset_order_override()
> - fw_cfg_order[]
> - rom_set_order_override()
> - rom_reset_order_override()
> 
> Simplify CLI and pc_vga_init() / pc_nic_init().
> 
> Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
> ---
>  include/hw/boards.h       |   3 +-
>  include/hw/loader.h       |   2 -
>  include/hw/nvram/fw_cfg.h |  10 ----
>  hw/core/loader.c          |  14 -----
>  hw/i386/pc.c              |   7 +--
>  hw/nvram/fw_cfg.c         | 109 +++-----------------------------------
>  system/vl.c               |   5 --
>  7 files changed, 9 insertions(+), 141 deletions(-)

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>

> 
> diff --git a/include/hw/boards.h b/include/hw/boards.h
> index e9e33c57f27..a231c8cecee 100644
> --- a/include/hw/boards.h
> +++ b/include/hw/boards.h
> @@ -284,8 +284,7 @@ struct MachineClass {
>          no_floppy:1,
>          no_cdrom:1,
>          no_sdcard:1,
> -        pci_allow_0_address:1,
> -        legacy_fw_cfg_order:1;
> +        pci_allow_0_address:1;

Pre-existing separate problem - why do we go to the trouble of using
bitfields here ???? Further down in the struct we lots of simple "bool"
fields.

The number of instances of MachineClass is not large enough that we s
ave a useful amount of memory through bitfields.

SO I'd suggest we just convert these to bools. Not needed for this patch
though.


With regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|




reply via email to

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