qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [RFC PATCH 0/6] qom: introduce TypeInfo name aliases


From: Eduardo Habkost
Subject: Re: [Qemu-devel] [RFC PATCH 0/6] qom: introduce TypeInfo name aliases
Date: Thu, 4 Jan 2018 17:22:03 -0200
User-agent: Mutt/1.9.1 (2017-09-22)

On Thu, Jan 04, 2018 at 11:40:40AM -0300, Philippe Mathieu-Daudé wrote:
> Hi,
> 
> This RFC series is intended to simplify Flattened Device Tree support,
> in particular the 'compatible' FDT entry, when Linux names mismatches
> QEMU ones, but this is the same device modelled.
> 
> Eventually this might help to remove the QDevAlias qdev_alias_table[]
> in qdev-monitor.c.
> 

Didn't look closely at the patches yet, but this sounds like a
nice generic way to replace other alias systems.  We have at
least:

* qdev-monitor.c: qdev_alias_table[] (as mentioned above)
* chardev/char.c: chardev_alias_table[]
* target/alpha/cpu.c: alpha_cpu_aliases[]
* target/ppc/cpu-models.c: ppc_cpu_aliases[]
* include/hw/boards.h: MachineClass::alias

Probably there are others I couldn't find.


> So far this is only a 'proof of concept'.
> To see how the qtests perform, I only modified 3 devices, 2 used by the
> Xilinx Zynq machines (Cadence), and the e1000 (used by the PXE test).
> 
> Regards,
> 
> Phil.
> 
> Philippe Mathieu-Daudé (6):
>   qom: introduce TypeInfo name aliases
>   hw/net/e1000: real device name is 'e1000-82540em', 'e1000' is an alias
>   hw/char/cadence_uart: add FDT aliases
>   arm/xlnx-zynq: use FDT names for the Cadence UART
>   hw/net/cadence_gem: add FDT names as alias
>   hw/arm/xlnx-zynq: use FDT names for the Cadence GEM
> 
>  include/qom/object.h   |  3 +++
>  hw/arm/xilinx_zynq.c   |  2 ++
>  hw/arm/xlnx-zynqmp.c   |  4 ++--
>  hw/char/cadence_uart.c |  7 +++++++
>  hw/net/cadence_gem.c   |  6 ++++++
>  hw/net/e1000.c         |  5 ++++-
>  qom/object.c           | 18 ++++++++++++++++--
>  7 files changed, 40 insertions(+), 5 deletions(-)
> 
> -- 
> 2.15.1
> 

-- 
Eduardo



reply via email to

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